Visualizzazione dei risultati da 1 a 8 su 8

Discussione: news rss scorrevoli

  1. #1
    Utente di HTML.it L'avatar di serpiko
    Registrato dal
    Feb 2005
    Messaggi
    346

    news rss scorrevoli

    salve a tutti, dovrei realizzare due sistemi di news scorrevoli....uno in orizzonatale ed uno in verticale...

    in entrambi i casi le news devono essere prese da una pagina xml che contiene le news in rss...

    attualmente il mio file statico che estrapola i dati è questo:

    <%
    ' Creo oggetto DOM XML
    Set objXML = Server.CreateObject("msxml2.DOMDocument.3.0")
    objXML.async = false
    objXML.setProperty "ServerHTTPRequest", True

    ' validazione del documento XML
    objXML.validateOnParse =false' true

    ' non conservare spazi
    objXML.preserveWhiteSpace =false

    blnLoaded = objXML.Load("http://www.miosito.it/asptoxml.asp")
    If Not blnLoaded Then
    Response.write "Nessuna news da visualizzare"
    Else
    set objNodeList = objXML.getElementsByTagName("channel")

    For Each objNode In objNodeList
    For Each objNode2 In objNode.childNodes

    Select Case objNode2.nodeName
    Case "title"
    html = html + "<tr><td>"
    html = html + objNode2.firstChild.nodevalue
    html = html + "
    </td></tr>"
    Case "link"
    html = html + "<tr><td><a target=_blank href="+objNode2.firstChild.nodevalue+">"
    html = html + objNode2.firstChild.nodevalue
    html = html + "</a>
    </td></tr>"
    Case "description"
    html = html + "<tr><td>"
    html = html + objNode2.firstChild.nodevalue
    html = html + " [img][/img]"
    html = html + "
    </td></tr>"
    End Select
    Next
    Next

    html = html + "<tr><td><hr></td></tr>"

    Set objNodeList = objXML.getElementsByTagName("item")
    For Each objNode In objNodeList
    For Each objNode2 In objNode.childNodes
    Select Case objNode2.nodeName
    Case "title"
    strTitle = objNode2.firstChild.nodevalue
    Case "link"
    strURL = objNode2.firstChild.nodevalue
    Case "description"
    strDescription = objNode2.firstChild.nodevalue
    End Select
    Next

    html = html+"<tr><td>[img][/img]"+strTitle+"</td></tr><tr><td>"+strDescription+"<hr></td></tr>"
    strTitle = ""
    strURL = ""
    strDescription = ""
    Next

    html = "<table>"+html+"</table>"
    set objNodeList = Nothing
    End if

    Response.write (html)
    %>
    attenta allo sportello quando scendi!!!!

  2. #2

  3. #3
    Utente di HTML.it L'avatar di serpiko
    Registrato dal
    Feb 2005
    Messaggi
    346
    forse vuoi farmi capire che è più una questione di script??? beh! cmq non lo so per questo ho chiesto aiuto... in pratica come faccio a realizzali!
    attenta allo sportello quando scendi!!!!

  4. #4
    Originariamente inviato da serpiko
    forse vuoi farmi capire che è più una questione di script???
    Oppure non ho capito la domanda
    Se ho capito la domanda allora sì, devi chiedere sul forum scripting.

  5. #5
    Utente di HTML.it L'avatar di serpiko
    Registrato dal
    Feb 2005
    Messaggi
    346
    ok ho inserito il post nel forum scripting... ma l'amministratore dovrebbe cancellarlo da qui allora...!... oppure ci sbagliamo entrambi e lo si può risolvere in questa sezione! boh!! non so!
    attenta allo sportello quando scendi!!!!

  6. #6
    Utente di HTML.it L'avatar di serpiko
    Registrato dal
    Feb 2005
    Messaggi
    346
    tu non hai idea di come aiutarmi?
    attenta allo sportello quando scendi!!!!

  7. #7
    Prova a vedere questo script

  8. #8
    Utente di HTML.it L'avatar di serpiko
    Registrato dal
    Feb 2005
    Messaggi
    346
    ottimo problema risolto! e cmq... sbagliavo io!! ehehehehh la distrazione a volte...
    attenta allo sportello quando scendi!!!!

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.