July 30, 200421 yr I have a simple form which queries a database with thousands of records. The form takes twenty inputs, too much for using GET (the URL is about 500 characters long). POST works great. I want to show 50 records at a time and jump from group to group. The search part works fine. I use the 'Link Next' and 'Link Previous' commands on the search results page. When I click them, I get zero records. How do I get the page to remember the found set but advance the $skip setting when POST is used? (It worked great with GET before the URL got too long.) I have explored every resource I can find, but aside from Chris Hansen's FXExamples.php (which is not a form), I cannot find an actual example which parallels my situation or even uses these Link commands. Does anyone have the code of an (ANY!) example of this that you could include in a response? I can't wait to get my hands on VisualFX for Dreamweaver so I can see how this code is supposed to work! With appreciation, Dave
July 31, 200421 yr You can use the CURL functions to POST from PHP. For example: <?php $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "http://localhost:1154/FMPro"); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, "-db=combotest.fp5&-format=-fmp_xml&-findall"); curl_exec($ch); curl_close($ch); ?> Hope this is of interest. Garry p.s. I've just realised that you want to do the POST from the page. You may have to build a Form with [FMP-CurrentFind] and some Javascript.
August 7, 200421 yr Author Garry, Thanks, as always, for your reply. I was on vacation. Sorry for delay in getting back. I made use of your idea in the P.S. I built forms for linkNext and linkPrevious which submit the last stored POST query with an updated (calc) skip entry. Buttons instead of links. Works great. I always learn something from your responses. Thanks for the push! Dave
Create an account or sign in to comment