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 6 of 6

Thread: Weather feed

  1. #1
    New to the CF scene
    Join Date
    May 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Weather feed

    This is my first post here and I am embarrassed to ask something on my first post but I could not find a way to make this work. I want to show weather degrees on my website receiving information from yahoo weather services. And I have codes below for this. The problem is these codes get all the information from the website but I need only one very very little portion of it; today’s weather degrees.

    Code:
    <%
    	Dim objXML, objRoot, objItems
    	Set objXML = Server.CreateObject("Microsoft.XMLDOM")
    	objXML.Async = False
    	objXML.SetProperty "ServerHTTPRequest", True
    	objXML.ResolveExternals = True
    	objXML.ValidateOnParse = True
    	objXML.Load("http://weather.yahooapis.com/forecastrss?p=94089")
    		If (objXML.parseError.errorCode = 0) Then
    			Set objRoot = objXML.documentElement
    				If IsObject(objRoot) = False Then
    					response.write "Bağlantı Hatası!"
    				End If
    				Set objItems = objRoot.getElementsByTagName("item")
    					If IsObject(objItems) = True Then
    							Dim objItem
    							For Each objItem in objItems
    								response.write objItem.selectSingleNode("title").Text & "<b><a href='" & objItem.selectSingleNode("link").Text & "'>" & objItem.selectSingleNode("description").Text & "</a></b><br /><br />" & vblf
    							Next
    						else
    							response.write "Bağlantı Hatası!"
    												
    					End If
    				Set objItems = Nothing
    			Set objRoot = Nothing
    	End If
    	Set objXML = Nothing
    %>

  • #2
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,459
    Thanks
    1
    Thanked 23 Times in 21 Posts
    What language is that written in? ASP?
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #3
    New to the CF scene
    Join Date
    May 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I am sorry I forgot to mention that. Asp.

  • #4
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,459
    Thanks
    1
    Thanked 23 Times in 21 Posts
    Considering you already have the XML from the site, and you sound like you're near completion, this thread may belong in the ASP forum instead of here.

    If no one else replies, I'll move this thread over to ASP later today.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #5
    New to the CF scene
    Join Date
    May 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Alex please transfer this post to asp section. I hope I will find my answer there.

  • #6
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,459
    Thanks
    1
    Thanked 23 Times in 21 Posts
    Done.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog


  •  

    Posting Permissions

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