Welcome to WebmasterWorld Guest from

Forum Moderators: httpwebwitch

Message Too Old, No Replies

xml populating pure css menu

is this possble?



3:38 pm on Jan 20, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

Hello all,

as you can see on the title of this post, i want to populate a pure css menu with xml data.
This means that all the options in the menu (horizontal drop down menu, by the way) must load from an xml file.

Is something like this possible? Can it be done with pure xml file and pure html file?
I can do this with php+css+xml.
Can it be done with html+css+xml? (or/and with javascript)

In case this is something that can be done, can you point me to some good examples? Or to a good site to start reading?
Mind you that my javascript knowledge is ery limited, while i can stand my ground with xml/css.


11:22 am on Jan 21, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

change of approach ...

i used ssi o include my menu on all static pages

For anyone interested for the solution (although here may be not the right place)...

Where you want your menu to appear put something like:
<!--#include virtual="/some/path/menu_info.txt" -->

In your htcess file put:
AddHandler server-parsed .htm
Options +Includes

So now your .htm files can include files like .shtml

Problem solved for me... hope this helps you also


12:54 pm on Jan 21, 2009 (gmt 0)

WebmasterWorld Administrator httpwebwitch is a WebmasterWorld Top Contributor of All Time 10+ Year Member

Actually you can accomplish the entire thing using JavaScript. Read in your XML file using XmlHttpRequest object (aka AJAX), parse it and inject those elements into the DOM.

It will take some JS chops to pull it off


Featured Threads

Hot Threads This Week

Hot Threads This Month