Jump to content

using quotes in html in vbscript


Recommended Posts

does anyone know if there is a way to use quotation marks for html attributes when you're doing them in vb. the main way i'm wondering is how to use vb subs for stuff like the onclick event that you are making with the document.write ("...") line.

Link to post
Share on other sites

I'm having the same problem as this guy but with Javascript.I thought you could use double quotes to indicate speechmarks within a string e.g. '' or "" but I can't get it to work.In my case though, it would be easier if anyone can tell me how to add a custom attribute to a control as this would get round the problem.

Link to post
Share on other sites

You have to propery nest the quotes or use the backslash.puting single quotes inside double quotesEscaping special characters<script>document.write("<a href='http://www.google.com'>google</a><br />");document.write("<a href=\"http://www.google.com\">google</a>");</script>http://www.w3schools.com/js/js_special_characters.asp

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...