On Apr 13, 2007, at 4:57 PM, tracy sanchez wrote: > I currently do have some single page forms that I use this code to > capture the IP Address: > > <cfset ipaddress="#cgi.remote_addr#"> > <cfset IPArray = listToArray(IPAddress,".")> > <cfset IPNumber= (IPArray[1] * (256)^3) + (IPArray[2] * (256)^2) + > (IPArray[3] * 256) + IPArray[4]>
Tracy, I'm not sure why you would have separate forms to capture the IP address, since that is available in your CGI variables. Are you using CFHTTP to post to those forms in some way? That would explain the why the value you're getting is the servers IP. On your duplicate values, I would suggest checking your query. It looks like you've got quite a few fields on your INSERT statement. I would suggest looking at that query again and see if you have your list of query params out of order with your field list. Ditto for your SELECT queries where you are retrieving the results. Also, what are you trying to accomplish by converting the IP address into an IP number (with the array)? That's not a slam on you, just trying to get clarification. I assume you're just looking to store the only address as a simple value in your db for tracking purposes, correct? HTH, Jon ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| ColdFusion MX7 and Flex 2 Build sales & marketing dashboard RIAâs for your business. Upgrade now http://www.adobe.com/products/coldfusion/flex2?sdid=RVJT Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:275183 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

