There is url length limitation:
When the url was constructed and email to outlook, it tends to be truncated if length exceeded 2048.
In addition, different browser also will put limitation on the url length.
Is there any existing method in appgini, something like a POST method?
I explore this https://blogs.sap.com/2014/04/17/url-le ... -explorer/, but not sure whether it can be implemented in appgini.
URL length limitation to filter records
Re: URL length limitation to filter records
Hi,
please explain what you are trying to do. Maybe this way we can find a solution.
The document describes a workaround. Probably you could send come cryptic data using GET and do some stuff according to your cryptic data ... but that's poking in the dark, so: What are you trying to do?
Olaf
please explain what you are trying to do. Maybe this way we can find a solution.
The document describes a workaround. Probably you could send come cryptic data using GET and do some stuff according to your cryptic data ... but that's poking in the dark, so: What are you trying to do?
Olaf
Some postings I was involved, you might find useful:
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
Re: URL length limitation to filter records
For example, I have constructed a url for a filtered records, as follows:
http://localhost.com/abc_view.php?SortF ... lue[18]=57
This url will be hyperlink and automatically send to the user via email so that the recipient can check on the filter records page directly by click on the link. Some email client such as outlook will truncate the url link because it is too long and hence make it broken. Different browser do also have variable limitation on url length.
I am looking for a persistent solution. Do you have any better approach to let user access to a readily custom filtered page?
http://localhost.com/abc_view.php?SortF ... lue[18]=57
This url will be hyperlink and automatically send to the user via email so that the recipient can check on the filter records page directly by click on the link. Some email client such as outlook will truncate the url link because it is too long and hence make it broken. Different browser do also have variable limitation on url length.
I am looking for a persistent solution. Do you have any better approach to let user access to a readily custom filtered page?
- D Oliveira
- AppGini Super Hero
- Posts: 347
- Joined: 2018-03-04 09:30
- Location: David
Re: URL length limitation to filter records
save query string on a temporary file and request string on load with sessionStorage or localStorage
Re: URL length limitation to filter records
Hi, Oliveira.
Can you elaborate more or give example/ any external reference?
save query string on a temporary file - if it is temporary, that means it will not be persistent and access in future?
request string on load with sessionStorage or localStorage - request strings is GET to the temporary file?
Can you elaborate more or give example/ any external reference?
save query string on a temporary file - if it is temporary, that means it will not be persistent and access in future?
request string on load with sessionStorage or localStorage - request strings is GET to the temporary file?
Re: URL length limitation to filter records
Hi,
just an idea: You could also build yourself an URL shortener into you application. A simple table that connects a short string with the full URL. Then, check if a shorturl is given and return the long.
Olaf
just an idea: You could also build yourself an URL shortener into you application. A simple table that connects a short string with the full URL. Then, check if a shorturl is given and return the long.
Olaf
Some postings I was involved, you might find useful:
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
Re: URL length limitation to filter records
That should avoid the link send via email being truncated. A proxy link (shorter) to return the actual link (long). But, the long link will still limited by the browser url's length.
I check on the https://youtu.be/7gMWoVh62wU?t=145. In appgini old version, it actually generate the POST form. May this method will work to replace the GET method if the url string is too long.
I have not try it and not sure whether it will works or not.
I check on the https://youtu.be/7gMWoVh62wU?t=145. In appgini old version, it actually generate the POST form. May this method will work to replace the GET method if the url string is too long.
I have not try it and not sure whether it will works or not.
Re: URL length limitation to filter records
Hi,
POST can be used from a from in direct exchange with the server. GET can be used to create bookmarks and links that can be exchanged. For your purpose, sending someone a link you are forced to use GET .... but ... you can make AG transform this and handle it yourself:
a) create a short link and save the connection to your desired "what should happen" in some internal table
b) in the /hooks/tablename.php -> _init function, you grab the GET, and make AG filter/show only the records that should be shown according to the "long" link in a)
Somehow complicated, but it should work.
You will always have limitations on URL length as it a standardized value which you as a "simple" developer should take as is and not fiddle around with (just a tip from experience - you will create yourself a lot of extra work).
Olaf
POST can be used from a from in direct exchange with the server. GET can be used to create bookmarks and links that can be exchanged. For your purpose, sending someone a link you are forced to use GET .... but ... you can make AG transform this and handle it yourself:
a) create a short link and save the connection to your desired "what should happen" in some internal table
b) in the /hooks/tablename.php -> _init function, you grab the GET, and make AG filter/show only the records that should be shown according to the "long" link in a)
Somehow complicated, but it should work.
You will always have limitations on URL length as it a standardized value which you as a "simple" developer should take as is and not fiddle around with (just a tip from experience - you will create yourself a lot of extra work).
Olaf
Some postings I was involved, you might find useful:
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
SingleEdit - Prevent concurrent edits on records; Field Permissions; Column-Value-Based-Permissions; Custom (error) message; Audit Log; Backup your database; Two Factor Authentication; Block brute force (failed) logins; Add 2nd SAVE CHANGES button; Place a search on details view
Re: URL length limitation to filter records
Thank you for your kind suggestion.
- D Oliveira
- AppGini Super Hero
- Posts: 347
- Joined: 2018-03-04 09:30
- Location: David
Re: URL length limitation to filter records
what I meant was to get the string in a temporary file so you can retrieve it and apply the filters like this:
Code: Select all
function tablename_init(&$options, $memberInfo, &$args){
/* get data you saved, split it, and insert below accordingly */
addFilter(1, 'and', 1, 'equal-to', 'data');
return TRUE;
}