Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Dec 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy please help me... pretty please? (drop down menu)

    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...

  • #2
    Senior Coder
    Join Date
    Nov 2006
    Posts
    1,000
    Thanks
    0
    Thanked 0 Times in 0 Posts
    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.

    david_kw

  • #3
    New to the CF scene
    Join Date
    Dec 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    do you think it would make sense for me to start with constructing the drop down menu?

  • #4
    Senior Coder
    Join Date
    Nov 2006
    Posts
    1,000
    Thanks
    0
    Thanked 0 Times in 0 Posts
    This might be what you are looking for to get the RSS stuff. Then you can just worry about pull down menus.

    http://www.javascriptkit.com/dhtmltu...er/index.shtml

    david_kw


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •