Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-15-2003, 08:08 PM   PM User | #1
scroots
Senior Coder

 
Join Date: Jun 2002
Location: UK
Posts: 1,137
Thanks: 0
Thanked 0 Times in 0 Posts
scroots is an unknown quantity at this point
problem with "

i have the following code
document.f.output.value+="<table border="1">"

the above code doesn`t work due to the "" around the 1 ("1"). How can i replace these in my code but when it is added to the textbox it shows up as "?

scroots
__________________
Spammers next time you spam me consider the implications:
(1) that you will be persuaded by me(in a legitimate mannor)
(2)It is worthless to you, when i have finished
scroots is offline   Reply With Quote
Old 01-15-2003, 08:20 PM   PM User | #2
Tails
Regular Coder

 
Join Date: Nov 2002
Posts: 672
Thanks: 1
Thanked 1 Time in 1 Post
Tails is an unknown quantity at this point
You cannot use the same type of quotation marks. Use single quotes to surround the tag. Otherwise you'll get a string termination error since it thinks the next quote is the ending one.
Tails is offline   Reply With Quote
Old 01-15-2003, 08:21 PM   PM User | #3
kansel
Regular Coder

 
Join Date: Jul 2002
Location: Kansas, USA
Posts: 465
Thanks: 0
Thanked 45 Times in 44 Posts
kansel is on a distinguished road
You can also use \" to put an actual " into the text field if you don't want to use single quote marks.

document.f.output.value+="<table border=\"1\">"
kansel is offline   Reply With Quote
Old 01-15-2003, 08:23 PM   PM User | #4
scroots
Senior Coder

 
Join Date: Jun 2002
Location: UK
Posts: 1,137
Thanks: 0
Thanked 0 Times in 0 Posts
scroots is an unknown quantity at this point
thank you both, i know have learnt from your posts how to do it properly
cheers
scroots
__________________
Spammers next time you spam me consider the implications:
(1) that you will be persuaded by me(in a legitimate mannor)
(2)It is worthless to you, when i have finished
scroots is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 05:18 PM.


Advertisement
Log in to turn off these ads.