Jump to content

Embedding a XML file into an existing html page


Guest aisoku

Recommended Posts

What would be the best way to embed a XML file into an existing html page? using php include? or is there a better way? i also want to format it in a similar style to the rest of the page, and i understand XSLT would be the best way to do it? but with the xml file being embeded in another html page, is this the right way to go aobut doing it?

Link to comment
Share on other sites

Depends. What does your XML file contain? I have some XML files that just contain the text for my site. And I just pull the text from the XML page for which ever page requests it. The reason I keep all my text in an XML file is if I want to change the language of my site I just use a different XML file with that diff language. Check out my post titled 'Accessing Other Elements' or something like that. It kind of explains what I'm doing and it contains the javascript I used to parse my XML.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...