Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
rappelec #1
Question about url variables
Does anyone know of a way to grab a complete url, save it in a variable and transfer it to another page.
Thanks,
Robert
rappelec Guest
-
Variables question
I have a musql database on a personal web server which correctly displays the variable I want in flash. However I wish to change my variables now... -
local variables question...
Ok I'm reading the docs in order. It's saying that "variables"... (ex: variables.whatever) must be specified for local variables, but there's no... -
server variables question
I have a little snippet of code that looks like this: strServer = Request.ServerVariables ("server_name") If strServer = "localhost" then ... -
Newbie question about variables in URL
I'd be grateful for any help with this... I'm a PHP newbie using Apache and PHP offline for testing site pages (I'll get an online remote server... -
getenv variables question
I am trying to write a PHP action into my custom 404 error page that will email me when someone tries to access a bad link. I can get it to work... -
MikerRoo #2
Re: Question about url variables
Are you trying to get the user's REQUESTED page?
If so, this will do it:
<CFSET sRequestPage = "http://" & CGI.SERVER_NAME & CGI.SCRIPT_NAME & "?" &
CGI.QUERY_STRING>
If you need to, you can also test for (CGI.HTTPS IS "On").
Cheers,
-- MikeR
MikerRoo Guest
-
rappelec #3
Re: Question about url variables
I'm not sure if I understand what you mean by user's REQUESTED page. What I
have is a page with an article on it and a link to a "email this article" form.
The is used for sending someone the url of the page that contains the article.
I tried using <CFSET sRequestPage = "http://" & CGI.SERVER_NAME &
CGI.SCRIPT_NAME & "?" & CGI.QUERY_STRING> but I still just get the path
[url]http://www.company.com/newsandpubs/pr/[/url]
Maybe I'm emplimenting this wrong. I have <CFSET sRequestPage = "http://" &
CGI.SERVER_NAME & CGI.SCRIPT_NAME & "?" & CGI.QUERY_STRING> at the top of the
article page and <cfparam name="sRequestPage" default=""> at the top of the
email form page. Then I include #sRequestPage# between the cfmail tags.
rappelec Guest
-
MikerRoo #4
Re: Question about url variables
So you are displaying a page and it has a button like "Email this page" which
posts to your email page, and you want to send the full original URL?
If that is what you are asking then Add this tag inside the form that has your
email button:
<input type="hidden" name="sRequestPage" value="#sRequestPage#" />
In your email page, you would have:
<cfparam name="FORM.sRequestPage" default="">
and
#FORM.sRequestPage# between the cfmail tags.
--MikeR
MikerRoo Guest



Reply With Quote

