[TYPO3-dev] Creating a realurled request with a GET form

Peter Russ peter.russ at 4many.net
Thu Dec 10 16:59:02 CET 2009


--- Original Nachricht ---
Absender:   Francois Suter
Datum:       10.12.2009 16:46:
> Hi,
> 
>> When I have a GET-Form of course it appends all parameters with ? and &.
>> But I would need my form to send a realurled request because I need the
>> result being cached and requests containing "?" are not cached by
>> nc_staticfilecache.
>>
>> So I guess this has to be done with Javascript somehow. Any best
>> practices, extensions, hints, concerns?
> 
> As mentioned by Steffen, you can't do this with just JavaScript as the 
> cHash has to be saved in RealURL table. This is what we do when we have 
> a simple selector: rather than making it a drop-down to select a value 
> and then submitting the form, we make it like a quick jump menu. All 
> URLs are calculated (server-side, when the form is rendered) and used as 
> values for the drop-down. Then a JavaScript just changes the location to 
> the selected URL.
> 
> Of course this method won't work if you have some free input fields. It 
> can work only with selectors having a predefined set of values. And if 
> you have multiple selectors, you will have to build a set of URLs 
> corresponding to all combinations and select the right one using JS.
> 
> HTH
> 

You can use AJAX to query the action-url before submitting.This works 
pretty fast.

Peter


-- 
loans that change lives http://www.kiva.org

_____________________________
uon GbR
http://www.uon.li
http://www.xing.com/profile/Peter_Russ




More information about the TYPO3-dev mailing list