Is it possible to process Request vars stored in the db?

R

Rick

Hi,

1) HelloWorld.aspx?productID=abc123

2) HelloWorld.cs calls the database and gets a block of HTML code:

string dbReturned = "<body>Hello World, <a
href=http://localhost/?productID={NEED TO GET FROM THE CURRENT REQUEST QUERY
STRING}>click me</body>"

displayDBHTML = dbReturned;

3) HelloWorld.aspx
<asp:Label id="displayDBHTML" runat="server"></asp:Label>

Question: How can the link in the db html code have it's productID set to
Request.QueryString.Get("productID") at run time. I would like to avoid
parsing the block with a find and replace. Ideally asp.net would fill it in
as if I had hard coded it with inline code.

The view source code in the browser to look like this:
<body>Hello World, <a href=http://localhost/?productID=abc123">click
me</body>

Ideas?

Rick
 
N

Natty Gur

Hi,

What you are looking for might be possible if something will happened
with X# eventually. Meanwhile I think you need to handle the string in
order to embed query string value.

Natty Gur[MVP]

blog : http://weblogs.asp.net/ngur
Mobile: +972-(0)58-888377
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top