View Full Version : please help me... pretty please? (drop down menu)

12-10-2006, 01:55 AM
i am very new to javascript... the strange thing is, i'm pretty adept at actionscript... but javascript confuses me... i understand the concepts of javascript (object oriented, functions, values, attributes, booleans... etc)... but when i try to get started i don't really know where to begin...

anyway (probaby more background than you need)...

i'm trying to make a simple drop down menu that accesses an rss feed... i would like there to be three titles (not links) that when clicked, drop down article titles according to what is in the rss xml file... and/or the summaries of the articles... into a div on the page...

i don't need someone to send me a script necessarily... of if you do i need some explanation behind it... i could even use someone helping me with where to start (a drop down menu that doesn't have links) maybe instructions (like how the functions work to do this)... or point me in the direction of a good tutorial for dummies...

i don't know how to access the rss xml file... i have the urls... i just don't know how to access the script so i can walk the dom in it...

if i'm confusing people please let me know... any help would be VERY MUCH APPRECIATED...

12-10-2006, 04:03 AM
That is not an insignificant task you've set for yourself. The first thing you should probably know is (unless someone else knows a trick) that you cannot access the RSS urls directly from javascript. Both iframes and xmlhttp have security models that don't let you load the xml and look at it unless it is from the "same origin" which means exactly the same domain name in most cases.

Two ways around this are to either

1) have a script on your server download the xml file on a set basis (like once a minute) so you have a local copy
2) have a backend that can take a request for the xml document and then get it from the rss url back to the server and eventually back to the web browser

You should probably pick one of those two ways before going on. The first is the easiest in your case I'd think since the xml file likely isn't going to change all that often anyway. I use cron to do it in Linux.


12-10-2006, 03:52 PM
do you think it would make sense for me to start with constructing the drop down menu?

12-11-2006, 06:47 AM
This might be what you are looking for to get the RSS stuff. Then you can just worry about pull down menus.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum