...

View Full Version : Interactive category picker/selector?



Emkay
09-13-2011, 11:02 AM
I would appreciate if anyone could guide my point by point on how one could create a category picker just like gumtree (preferably in jquery):

http://www.gumtree.com/add_posting.html?location_id=uk

Specifically the points


How clicking on a category opens another to the right
How clicking on a category appends a variable like "#cat-10201" into the url (and vice versa)
How css lists are used instead of form select menus (making it easily styled)
How clicking on a deep subcategory automatically preselects all parent categories


I'm not looking for anyone to actually code it for me (that would be outrageous :p) but tips on how it's actually structured and steps on how it can be coded would be highly appreciated. I can do PHP and I know CSS also. I don't know plain javascript but I'm sure I can do most of it in jQuery

rnd me
09-13-2011, 06:14 PM
use <a href="section"> tags to change the url.

use a nested ul. use css to make it look like the example, but "stuck" on one section, just for testing. then make it look like the example when there is nothing selected.

onclick, hide all kids, then unhide the one you clicked on, it's kids, and it's parents.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum