php-windows Digest 9 Jul 2006 17:14:13 -0000 Issue 3008
Topics (messages 27064 through 27065):
Re: Dynamic HTML table sort with PHP
27064 by: Leif Gregory
how to enable objects?
27065 by: Bill Angus
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[email protected]
----------------------------------------------------------------------
--- Begin Message ---
Hello Ken,
Friday, July 7, 2006, 10:26:57 AM, you wrote:
> If I have a table header that contains a link that when clicked
> resubmits the page to itself with the proper sort query variables
> (e.g. index.php?sortBy=ORDER_ID&sortOrder=ASC), I want PHP to
> rewrite the sortOrder query string to be "sortOrder=DESC" and then
> "sortOrder=ASC" the next time column heading is clicked. This way,
> the column will sort like windows columns and users will feel
> "at-home" with the process.
Check the query_string on submission and change the GET link on the
column header to the opposite value.
i.e.
echo '<a href="index.php?sortBy=ORDER_ID&sortOrder=';
echo $_GET['sortOrder'] == 'ASC' ? 'DESC">' : 'ASC">';
echo 'ORDER ID</a>';
This will flip your link between ASC and DESC when clicked. Tested and
working.
--
TBUDL/BETA/DEV/TECH Lists Moderator / PGP 0x5D167202
__ ____ ____ ____ Geocaching: http://gps.PCWize.com
( ) ( ___)(_ _)( ___) TBUDP Wiki Site: http://www.PCWize.com/thebat/tbudp
)(__ )__) _)(_ )__) Roguemoticons & Smileys: http://PCWize.com/thebat
(____)(____)(____)(__) PHP Tutorials and snippets: http://www.DevTek.org
What would happen if an unstoppable object collided with an unmovable one???
--- End Message ---
--- Begin Message ---
The following code doesn't seem to do anything in the standard php distribution
that I have set up. I encountered some information in the manual that suggests
php works with this object-style of coding. But is there something I have to do
to enable php to deal with objects?
Is there a module or something that I have to install?
If so, how do I go about locating and installing it?
code example:
=================
$chapter_array->rewind();
$iterator=$chapter_array->getIterator();
echo $iterator->current();
echo $iterator->key();
Thanks in adfvance for any information.
--- End Message ---