Latest Register Log In

+ Advanced Search


Alphabetic Menu
Apr 25, 2007 (Edited Feb 04, 2014)

Suppose you wish to have A to Z links on your pages which lead to a list of listings starting with that letter. You can do this by constructing search links, like this:
<a href = "search.php?action=filter&filled=1&whichtype=links&titlecondition=start&titlesearch=A" >A</a>

For the letter B, just change titlesearch=A">A to titlesearch=B">B. To restrict to the current category, tack on &incatid={CATID}.

Remember that custom templates can be applied to any page, so you can make a special search result template and use it by tacking &custom=yes&TID=specialtemplate onto the search URL.

For an automatic list of all 26 English letters:
$num = ord('A');
for($x=0; $x<26; $x++)
$char = chr($num);
echo '<a href="search.php?action=filter&filled=1&whichtype=links&titlecondition=start&titlesearch='.$char.'">'.$char.'</a><br >';

Did this article fail to fully answer your questions? If so, please ask for clarification.

Your E-mail:
(needed so that you can get your answer!)
Confirm E-mail:
(same as above to prevent typos)

Description Creating A to Z sections of listings.
Views 524 views. Averaging 0 views per day.

Previous Article | Next Article