Ian,

Post me your javascript code.

Dave

-----Original Message-----
From: Ian Vaughan [mailto:[EMAIL PROTECTED]
Sent: Monday, July 25, 2005 11:01 AM
To: CF-Talk
Subject: RE: Restricting Access


Dave

I tried your javascript method, but the same outcome!!


Just seeing if I can find the code that will allow me to create this
cookie in perl, then as you said I could pick this cookie up using the
Coldfusion code below

<cfif isDefined("cookie.localip") and cookie.localip EQ cgi.remote_addr
>
  STOP!
  <cfabort>
</cfif> 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: 25 July 2005 15:55
To: CF-Talk
Subject: RE: Restricting Access

Ian,

client variables are a feature of coldfusion and can only be
set/retrieved on the server side. When you're looking at the form,
you're on the client side.  If you use my javascript method in my
previous post, you should be able to access the same cookie on both the
client and server side.  If you don't want to use a regular cookie, then
your only option I can see is to re-write the form processor in cold
fusion.  If you have to use client variables, then that is definitely
your only option.

Dave

-----Original Message-----
From: Ian Vaughan [mailto:[EMAIL PROTECTED]
Sent: Monday, July 25, 2005 10:37 AM
To: CF-Talk
Subject: RE: Restricting Access


This is the problem I am having and it has to be posting to a perl
script!!!,  is it possible to set the client variable when the user
clicks the submit button on the form, perhaps by setting a hidden field
??

I have tried setting the hidden field below

<input type="hidden" name="sent" value="yes">

Then using the code below to set a client variable when the form is
submitted but still no luck!

 <cfif isDefined("form.sent")> 

   <cfset client.localip = #cgi.remote_addr#>

</cfif>

How can I set the client variable to their IP Address when they submit
the form ???





-----Original Message-----
From: Robertson-Ravo, Neil (RX)
[mailto:[EMAIL PROTECTED]
Sent: 25 July 2005 15:10
To: CF-Talk
Subject: RE: Restricting Access

How are you setting this client variable if the calling page is posting
to a perl script?  I am not sure how this is possible?  You would need
to have form posting to cf page which sets the client var.



-----Original Message-----
From: Ian Vaughan [mailto:[EMAIL PROTECTED]
Sent: 25 July 2005 15:15
To: CF-Talk
Subject: RE: Restricting Access

Still not working very frustrating, can you see from the code why the
form keeps displaying instead of the STOP message as I have submitted
the form !

When I run a cfdump var="#client.localip#"> it comes back with an error
' Element LOCALIP is undefined in CLIENT.  '

<cfif isDefined("client.localip") and client.localip EQ
#cgi.remote_addr# >
  STOP!
  <cfabort>
</cfif>


 <cfif isDefined("form.v4")> 
   <cfset client.localip = #cgi.remote_addr#> </cfif>



<form action="cgi-bin/subqs.pl" method="post" target="_top"> <input
type="hidden" name=":SURVEY:" value="Questionnaire2"> <input
type="hidden" name=":EMAIL:" value="[EMAIL PROTECTED]"> <input
type="hidden" name=":USERID:" value="069/001">

<input type="hidden" name="V4" value=""> <input type="hidden" name="V20"
value=""> <input type="hidden" name="V21" value="">

</form>











~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:212751
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to