Web Hosting Deals Holiday Logo Design Webcam Chat Website Header Templates Register domain Search Engine Optimisation Web Hosting
Go Back   Talk Mania Forum > Programming / Scripting / Coding

Programming / Scripting / Coding Got a question about : PHP / Perl / Java / JavaScript / CGI Scripts / JavaScript coding. Ask here! We'll get you the answers !

 Image
Buy Sell Downloads

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-04-2007, 01:27 AM
Junior Member
 
Join Date: Feb 2007
Posts: 20
-=sIN=- is on a distinguished road
[PHP] Show IP

Simply add this code into any existing php document:

PHP Code:
<? 
  
echo "Your IP: $REMOTE_ADDR"
?>

Reply With Quote
  #2 (permalink)  
Old 02-04-2007, 03:25 PM
Junior Member
 
Join Date: Feb 2007
Posts: 10
matt_canning is on a distinguished road
simple and effective thanks
Reply With Quote
  #3 (permalink)  
Old 02-04-2007, 06:08 PM
Junior Member
 
Join Date: Feb 2007
Posts: 9
tutorialstation is on a distinguished road
That's if you have register_globals set to on.

But due to security concern i always set my register_globals to off.

And i use this to detect visitors IP.

PHP Code:
$_SERVER['REMOTE_ADDR'
Reply With Quote
  #4 (permalink)  
Old 02-05-2007, 02:06 PM
Junior Member
 
Join Date: Feb 2007
Posts: 25
JimBob45506 is on a distinguished road
Most hosts are turning register_globals off for safety. Thanks for the share.
__________________
Web-Rx Consulting - Honest, Friendly Solutions
http://web-rx.biz
Reply With Quote
  #5 (permalink)  
Old 02-06-2007, 06:24 AM
Junior Member
 
Join Date: Feb 2007
Posts: 11
lazycoder is on a distinguished road
Quote:
Originally Posted by tutorialstation View Post
That's if you have register_globals set to on.

But due to security concern i always set my register_globals to off.

And i use this to detect visitors IP.

PHP Code:
$_SERVER['REMOTE_ADDR'
That would be the 'correct' way
Reply With Quote
  #6 (permalink)  
Old 02-08-2007, 03:24 AM
Junior Member
 
Join Date: Feb 2007
Posts: 19
bronis is on a distinguished road
i think it`s very simple and nice ip script
Reply With Quote
  #7 (permalink)  
Old 02-11-2007, 06:48 PM
Junior Member
 
Join Date: Feb 2007
Posts: 11
lazycoder is on a distinguished road
Quote:
Originally Posted by bronis View Post
i think it`s very simple and nice ip script
One line of code can hardly be called a script through
Reply With Quote
  #8 (permalink)  
Old 02-26-2007, 08:16 PM
Junior Member
 
Join Date: Feb 2007
Posts: 10
thy gamer is on a distinguished road
Quote:
Originally Posted by lazycoder View Post
One line of code can hardly be called a script through
Then what is it?
Reply With Quote
  #9 (permalink)  
Old 02-27-2007, 09:06 PM
Junior Member
 
Join Date: Feb 2007
Posts: 11
Nosf is on a distinguished road
Quote:
Originally Posted by thy gamer View Post
Then what is it?
regular exspression
Reply With Quote
  #10 (permalink)  
Old 02-27-2007, 09:09 PM
Member
 
Join Date: Sep 2006
Location: Cyber Space, Uk.
Posts: 91
Nick is on a distinguished road
Send a message via AIM to Nick Send a message via MSN to Nick Send a message via Yahoo to Nick Send a message via Skype™ to Nick
it's definately not regex. It's just a tip

__________________
Nick - Coder/Designer
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
Forum Jump


All times are GMT +2. The time now is 02:36 AM.


Fake ID

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC8
Forums Copyright © Talk-Mania.com