Jump to content

Can I Do It This Way?


migroo
 Share

Recommended Posts

Okay I am trying to set the size of some text via a xml document.

document.write('<p class=" '.xmlDoc.getElementsByTagName("size")[0].childNodes[0].nodeValue.' " >');

I have three class set: small, regular, and large. Now I know the xml document is updating properly from my forms and I am just wandering what I am doing wrong with this line of coding?Thank you and any help will be much appreciated.

Edited by migroo
Link to comment
Share on other sites

Okay I got it never mind.I just needed to use a "," instead of a "."

document.write('<p class="',xmlDoc.getElementsByTagName("size")[0].childNodes[0].nodeValue,'">');

Okay thank you all.

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
 Share

×
×
  • Create New...