TalkPHP
 
 
Account Login
Latest Articles
» The basic usage of PHPTAL, a XML/XHTML template library for PHP
» Vulnerable methods and the areas they are commonly trusted in.
» Simple way to protect a form from bot
» The Basics On: How Session Stealing Works
» How to keep your forms from double posting data
IRC Channel
IRC Speech Bubble Join the friendly bunch on IRC...
(#TalkPHP on Freenode)

...Also available via a web interface.

See this thread for information on the TalkPHP Free Hugs Initiative™. Subject to availability.
Associates
Associates
CSS Tutorials
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 03-06-2010, 04:59 PM   #1 (permalink)
The Contributor
 
Tim Dobson's Avatar
 
Join Date: Feb 2010
Posts: 69
Thanks: 16
Tim Dobson is on a distinguished road
Default show url link if there ip =?

is it possible to show someone a specific url depending on their IP address? just out of curiosity wanted it to show all site admins a specific link without having any kind of login of sort... if anyone knows this could they please give me some code im sure its simple enough..

Thanks
Tim Dobson is offline  
Reply With Quote
Old 03-06-2010, 06:04 PM   #2 (permalink)
Wizard
Top Contributor 
 
Village Idiot's Avatar
 
Join Date: Sep 2007
Posts: 1,299
Thanks: 17
Village Idiot is on a distinguished road
Default

Quote:
Originally Posted by Tim Dobson View Post
is it possible to show someone a specific url depending on their IP address? just out of curiosity wanted it to show all site admins a specific link without having any kind of login of sort... if anyone knows this could they please give me some code im sure its simple enough..

Thanks
Just have PHP find their IP address and use if statements, but it is a really bad idea to do this. IP addresses frequently change (especially for DSL users) and they can be spoofed. There is a reason that no one else does it, and that is because it is really bad security. Don't do it.
__________________

Village Idiot is offline  
Reply With Quote
The Following User Says Thank You to Village Idiot For This Useful Post:
Tim Dobson (03-06-2010)
Old 03-06-2010, 06:32 PM   #3 (permalink)
The Contributor
 
Tim Dobson's Avatar
 
Join Date: Feb 2010
Posts: 69
Thanks: 16
Tim Dobson is on a distinguished road
Default

lol thnks for that but it really wouldent make no difference if anyone else gets to see it because it would only take you to a login page... just wanted it to show me the url to the login page for my news edit page and unless they have the password and login id they cant get in... just saves me havin to type in the the annoying url all the time its not really a security issue in this case.
Tim Dobson is offline  
Reply With Quote
Old 03-06-2010, 07:19 PM   #4 (permalink)
Wizard
Top Contributor 
 
Village Idiot's Avatar
 
Join Date: Sep 2007
Posts: 1,299
Thanks: 17
Village Idiot is on a distinguished road
Default

Quote:
Originally Posted by Tim Dobson View Post
lol thnks for that but it really wouldent make no difference if anyone else gets to see it because it would only take you to a login page... just wanted it to show me the url to the login page for my news edit page and unless they have the password and login id they cant get in... just saves me havin to type in the the annoying url all the time its not really a security issue in this case.
Then its not dangerous, just dysfunctional since your IP changes.
__________________

Village Idiot is offline  
Reply With Quote
Old 03-06-2010, 08:24 PM   #5 (permalink)
is cute and cuddly
 
delayedinsanity's Avatar
 
Join Date: Mar 2008
Location: Vegas, Baby
Posts: 963
Thanks: 31
delayedinsanity is on a distinguished road
Default

Mine doesn't. When I'm connected via SSH and running lynx. Same IP, all the time. :D
delayedinsanity is offline  
Reply With Quote
Old 03-06-2010, 09:24 PM   #6 (permalink)
The Prestige
Advanced Programmer Top Contributor Good Samaritan 
 
sketchMedia's Avatar
 
Join Date: Oct 2007
Location: Manchester, UK
Posts: 854
Thanks: 32
sketchMedia is on a distinguished road
Default

Quote:
Originally Posted by delayedinsanity View Post
Mine doesn't. When I'm connected via SSH and running lynx. Same IP, all the time. :D
Ah lynx rocks! (well its better than Internet Exploder at any rate)

Posted with lynx via ssh
__________________
mysql> SELECT * FROM `users` WHERE `users`.`clue` > 0;
Empty set (0.00 sec)
sketchMedia is offline  
Reply With Quote
Old 03-06-2010, 10:23 PM   #7 (permalink)
Wizard
Top Contributor 
 
Village Idiot's Avatar
 
Join Date: Sep 2007
Posts: 1,299
Thanks: 17
Village Idiot is on a distinguished road
Default

Quote:
Originally Posted by delayedinsanity View Post
Mine doesn't. When I'm connected via SSH and running lynx. Same IP, all the time. :D
What type of connection do you have? Some connections have dedicated IPs.
__________________

Village Idiot is offline  
Reply With Quote
Old 03-06-2010, 11:31 PM   #8 (permalink)
is cute and cuddly
 
delayedinsanity's Avatar
 
Join Date: Mar 2008
Location: Vegas, Baby
Posts: 963
Thanks: 31
delayedinsanity is on a distinguished road
Default

My ISP is dynamic, and very much so as I discovered when I found myself firewalled from my own servers despite having a range defined in iptables. I had to open the range up much wider than I would like due to the large block of IPs that they quite frequently cycle me through.

However when I'm in my shell I can connect via lynx from a dedicated IP. ;)
delayedinsanity is offline  
Reply With Quote
Old 03-07-2010, 02:55 PM   #9 (permalink)
The Contributor
 
Tim Dobson's Avatar
 
Join Date: Feb 2010
Posts: 69
Thanks: 16
Tim Dobson is on a distinguished road
Default

Quote:
Originally Posted by Village Idiot View Post
Then its not dangerous, just dysfunctional since your IP changes.
I put it as a range ip so it should always stay active... some users may see the links but as i said not dangerous thanks for the quick replies.
Tim Dobson is offline  
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to create a gallery class Tanax Advanced PHP Programming 25 02-19-2013 04:25 AM
Match code in link with code with one in file and extract line Peuplarchie General 0 10-23-2009 02:38 PM
adding a php link me code using an image as the link chikooo Absolute Beginners 3 03-02-2009 03:12 PM
Wordpress tags some show some donīt EyeDentify General 0 01-19-2009 08:21 PM
email link validation (need hekp) kororo203 Absolute Beginners 4 04-17-2008 07:48 AM


All times are GMT. The time now is 10:37 AM.

 
     

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Inactive Reminders By Icora Web Design