Re: [PHP-DB] Row order
Stefan, Depending on your load, you could save the results in a database table, make the table name a session variable, and just have the sorting column names be fields in the saved table. CREATE TABLE Q1234 AS SELECT ...; You can also put all the variables in a variable then put the new variable in the a tags like this: $query_vars = field1=afield2=bfield3=c...; a href=file.php??=$query_vars?sort=field4Field 4/a Hope this helps. Dan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] Row order
Hello! I have this little problem sorting a search result by different fieldnames. I do my search, get a quite impressive amount of variables that I use in my MySQL-query, and by default use ORDER BY name. But I want to be able to klick on different headers to sort like ORDER BY $order. The problem that I encounter is that I lose all the variables from the search when I refresh the document. Is it possible to resend all variables without inserting them in the A-tag ? (like A href=find.php?var1=$var1..) Hopefully someone has a smart solution.. =) regards - Stefan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Row order
Cookie or session? A little extreme, but if you don't want it in the url then that's the only other way I can think of to remember a variable when the page is refreshed.. Tom At 13:09 11/07/2001 +0200, you wrote: Hello! I have this little problem sorting a search result by different fieldnames. I do my search, get a quite impressive amount of variables that I use in my MySQL-query, and by default use ORDER BY name. But I want to be able to klick on different headers to sort like ORDER BY $order. The problem that I encounter is that I lose all the variables from the search when I refresh the document. Is it possible to resend all variables without inserting them in the A-tag ? (like A href=find.php?var1=$var1..) Hopefully someone has a smart solution.. =) regards - Stefan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]