URL重定向,打开浏览器作为表值 [英] URL Redirection ,Open Browser as Table Value
问题描述
我问一个问题,请告诉我
我的任务是我拥有一个像这样的网址http://example.com
我正在通过网址传递一个参数alog,如
http://example.com/Tagid=12345
我想在数据库表值(EX:www.asp.net)中显示SiteName(ColumnName)对应的Tagid号
我想最终结果是
IActual URL为:"http://example.com/Tagid=12345"
我想显示:"http://example.com/?Tagid=12345\www.asp.net"
"www.asp.net"此值来自数据库表
表信息
Tagid SiteName
12345 http://www.asp.net
43215 http://www.microsoft.com
54666 http://www.c#corner.com
请帮助我,我是这个概念的新手.
如果需要重定向到新的URL,可以这样做.
httpcontext cont = httpcontext.current;
当前网址=连续当前网址;
字符串appendurl ="www.asp.net";
response.redirect(url + appendurl);
请给出完整的简单源代码示例,
www.asp.net来自于TagId列VALUE的数据库表中的值,
Hi,
I am asking one question plz tell me
My task is I have one url like this http://example.com
I am passing one parameter alog with url like
http://example.com/Tagid=12345
I want to display SiteName(ColumnName)in database table value(EX:www.asp.net) correspondind Tagid number
I want to Final Result is
IActual URL is:"http://example.com/Tagid=12345"
I want to display:"http://example.com/?Tagid=12345\www.asp.net"
"www.asp.net" This value comming from DATABASE TABLE
Table Information
Tagid SiteName
12345 http://www.asp.net
43215 http://www.microsoft.com
54666 http://www.c#corner.com
Plz help me I am new this concept.
do you want to re-write your url or your want to redirect to new url?
if required to redirect to new url it can be done like.
httpcontext cont = httpcontext.current;
current url = cont.currenturl;
string appendurl ="www.asp.net";
response.redirect(url + appendurl);
Pls give complete simple Example of the source code,
www.asp.net Value comming From database table basing on the TagId column VALUE,
这篇关于URL重定向,打开浏览器作为表值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!