Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > get the name of the current page

Reply
Thread Tools

get the name of the current page

 
 
JT
Guest
Posts: n/a
 
      01-15-2004
is there a command in asp to get the name of the current page?

furthermore, is there a way to retrieve the name of the current page within
an 'included' file (not the name of the included page, but the name of the
page that is including the file)?

i hope im making sense

thanks for the help


 
Reply With Quote
 
 
 
 
Ray at
Guest
Posts: n/a
 
      01-15-2004
Take a look at the server variables that are available to you:

<%
For each q in Request.ServerVariables
Response.Write q & " = " Request.ServerVariables(q) & "<hr>"
Next
%>

Ray at work

"JT" <> wrote in message
news:...
> is there a command in asp to get the name of the current page?
>
> furthermore, is there a way to retrieve the name of the current page

within
> an 'included' file (not the name of the included page, but the name of the
> page that is including the file)?
>
> i hope im making sense
>
> thanks for the help
>
>



 
Reply With Quote
 
 
 
 
Aaron Bertrand - MVP
Guest
Posts: n/a
 
      01-15-2004
http://www.aspfaq.com/2072

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/




"JT" <> wrote in message
news:...
> is there a command in asp to get the name of the current page?
>
> furthermore, is there a way to retrieve the name of the current page

within
> an 'included' file (not the name of the included page, but the name of the
> page that is including the file)?
>
> i hope im making sense
>
> thanks for the help
>
>



 
Reply With Quote
 
Mikhail Esteves
Guest
Posts: n/a
 
      01-15-2004
Hi,

If you want just the name of the current file:

request.servervariables("PATH_INFO")

If you want the whole URL to the file returned:

xyz = "http://" & request.servervariables("LOCAL_ADDR") & _
request.servervariables("PATH_INFO")

HTH.

JT, on Thu, 15 Jan 2004 09:54:53 -0600, had to say:

> is there a command in asp to get the name of the current page?
>
> furthermore, is there a way to retrieve the name of the current page within
> an 'included' file (not the name of the included page, but the name of the
> page that is including the file)?
>
> i hope im making sense
>
> thanks for the help


 
Reply With Quote
 
 
 
Reply

Thread Tools

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
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
using the current method name within current method Matthew Heidemann Ruby 14 03-22-2011 03:56 AM
how do you get current full aspx page name with querystring? VB Programmer ASP .Net 11 06-21-2010 12:13 PM
How to update the current web page? (delete current web page + rewrite the page) laryten@yahoo.com Javascript 3 10-12-2006 07:33 PM
Get the name of the current page IntraRELY ASP .Net 1 07-30-2003 11:01 PM
Re: Urgent! how to get object name, method name and attribute name based on the strings? ding feng C++ 2 06-25-2003 01:18 PM



Advertisments