By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,240 Members | 791 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,240 IT Pros & Developers. It's quick & easy.

escape character doesnt work??

P: n/a
Hello, I hope someone will help me or I will have to dive from 11th floor.
Why this --> test = @"Melanie "Jets" Riggs" doesnt work in asp? I need
something like that and I dont know how to make it work. Please help me!!
answer to da*@syscz.com many thanx
Jul 19 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
You mean this?...........

<%
Response.Write "Melanie " & chr(34) & "Jets" & chr(34) & " Riggs"
%>

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:u6**************@tk2msftngp13.phx.gbl...
Hello, I hope someone will help me or I will have to dive from 11th floor.
Why this --> test = @"Melanie "Jets" Riggs" doesnt work in asp? I need
something like that and I dont know how to make it work. Please help me!!
answer to da*@syscz.com many thanx

Jul 19 '05 #2

P: n/a
nono, I need to have few " in one response write.
actually I want to have something like this q = "<!--include file=" + pageid
+ ".asp"-->"
but how can I make it?

"Steven Burn" <nobody@PVT_it-mate.co.uk> píše v diskusním příspěvku
news:#1**************@tk2msftngp13.phx.gbl...
You mean this?...........

<%
Response.Write "Melanie " & chr(34) & "Jets" & chr(34) & " Riggs"
%>

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:u6**************@tk2msftngp13.phx.gbl...
Hello, I hope someone will help me or I will have to dive from 11th floor. Why this --> test = @"Melanie "Jets" Riggs" doesnt work in asp? I need
something like that and I dont know how to make it work. Please help me!! answer to da*@syscz.com many thanx


Jul 19 '05 #3

P: n/a
Well thats simple enough;

<%
Dim PAGEID
PAGEID = "page1" '// Obviously this will be whatever pageid actually
is

q = "<!--include file=" & chr(34) & PAGEID & ".asp" & chr(34) &
"-->"
Responde.Write q
%>

Using chr(34) allows you to have " whenever you need to "print" them, rather
than have the page interpret them as code.

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:ej**************@TK2MSFTNGP09.phx.gbl...
nono, I need to have few " in one response write.
actually I want to have something like this q = "<!--include file=" + pageid + ".asp"-->"
but how can I make it?

"Steven Burn" <nobody@PVT_it-mate.co.uk> píše v diskusním příspěvku
news:#1**************@tk2msftngp13.phx.gbl...
You mean this?...........

<%
Response.Write "Melanie " & chr(34) & "Jets" & chr(34) & " Riggs"
%>

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:u6**************@tk2msftngp13.phx.gbl...
Hello, I hope someone will help me or I will have to dive from 11th floor. Why this --> test = @"Melanie "Jets" Riggs" doesnt work in asp? I need
something like that and I dont know how to make it work. Please help me!! answer to da*@syscz.com many thanx



Jul 19 '05 #4

P: n/a
ok, I understand, but the code should be interpreted. thats the problem

"Steven Burn" <nobody@PVT_it-mate.co.uk> píše v diskusním příspěvku
news:#K**************@TK2MSFTNGP09.phx.gbl...
Well thats simple enough;

<%
Dim PAGEID
PAGEID = "page1" '// Obviously this will be whatever pageid actually is

q = "<!--include file=" & chr(34) & PAGEID & ".asp" & chr(34) &
"-->"
Responde.Write q
%>

Using chr(34) allows you to have " whenever you need to "print" them, rather than have the page interpret them as code.

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:ej**************@TK2MSFTNGP09.phx.gbl...
nono, I need to have few " in one response write.
actually I want to have something like this q = "<!--include file=" +

pageid
+ ".asp"-->"
but how can I make it?

"Steven Burn" <nobody@PVT_it-mate.co.uk> píše v diskusním příspěvku
news:#1**************@tk2msftngp13.phx.gbl...
You mean this?...........

<%
Response.Write "Melanie " & chr(34) & "Jets" & chr(34) & " Riggs"
%>

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
<ad***********@syscz.com> wrote in message
news:u6**************@tk2msftngp13.phx.gbl...
> Hello, I hope someone will help me or I will have to dive from 11th

floor.
> Why this --> test = @"Melanie "Jets" Riggs" doesnt work in asp? I need > something like that and I dont know how to make it work. Please help

me!!
> answer to da*@syscz.com many thanx
>
>



Jul 19 '05 #5

P: n/a
<ad***********@syscz.com> wrote in message
news:ej****************@TK2MSFTNGP09.phx.gbl...
nono, I need to have few " in one response write.
actually I want to have something like this q = "<!--include file=" + pageid + ".asp"-->"
but how can I make it?


To escape the double quote, double it up.
For example:
q = "He said ""I am here"""
Response.Write "<div>" & q & "</div>"

This will result in:
<div>He said "I am here"</div>

So in your example:
q = "<!--include file=""" & pageid & ".asp""-->"

Note, if you're trying to include a file dynamically, be advised that this
will not work. Include files are processed *BEFORE* ASP.
Try reading this:
http://www.aspfaq.com/show.asp?id=2042

Regards,
Peter Foti

Jul 19 '05 #6

P: n/a
many thanx, but .... shit, everything is wrong. :(
"Peter Foti" <pe***@Idontwantnostinkingemailfromyou.com> píše v diskusním
příspěvku news:10*************@corp.supernews.com...
<ad***********@syscz.com> wrote in message
news:ej****************@TK2MSFTNGP09.phx.gbl...
nono, I need to have few " in one response write.
actually I want to have something like this q = "<!--include file=" +

pageid
+ ".asp"-->"
but how can I make it?


To escape the double quote, double it up.
For example:
q = "He said ""I am here"""
Response.Write "<div>" & q & "</div>"

This will result in:
<div>He said "I am here"</div>

So in your example:
q = "<!--include file=""" & pageid & ".asp""-->"

Note, if you're trying to include a file dynamically, be advised that this
will not work. Include files are processed *BEFORE* ASP.
Try reading this:
http://www.aspfaq.com/show.asp?id=2042

Regards,
Peter Foti

Jul 19 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.