Re: How do I ban an ip address please!
| From: | Tyler Longren | Date: | Fri, 24 Nov 2000 02:36:26 +0000 |
| Subject: | Re: How do I ban an ip address please! | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-26896@lists.php.net to get a copy of this message | ||
You could put IP's that you want banned into a database and if any of those
ip's in the database, match $REMOTE_ADDR, echo "You've been banned";
That's one way you could do it.
Tyler
On Thu, 23 Nov 2000, Sandeep Hundal wrote:
> Date: Thu, 23 Nov 2000 18:30:05 -0800 (PST)
> To: tyler.longren@midiowa.net
> From: Sandeep Hundal <sandeep_wde@yahoo.com>
> CC: PHP-General <php-general@lists.php.net>
> Subject: Re: [PHP] How do I ban an ip address please!
>
> nice!! how can i have a whole bunch of ip addresses added to that
> list? ;)
>
>
> --- Tyler Longren <tyler.longren@midiowa.net> wrote: > <?
> > if ($REMOTE_ADDR == "ip.to.ba.n") {
> > echo "You've been banned!!!";
> > }
> > else {
> > // continue with code
> > }
> > ?>
> >
> > eh?
> >
> > Tyler
> >
> > On Thu, 23 Nov 2000, Sandeep Hundal wrote:
> > > Date: Thu, 23 Nov 2000 18:23:45 -0800 (PST)
> > > To: php-general@lists.php.net
> > > From: Sandeep Hundal <sandeep_wde@yahoo.com>
> > > Subject: [PHP] How do I ban an ip address please!
> > >
> > > Hi all,
> > >
> > > I'm using Bare Bones bulletin board, and making something akin my
> > own
> > > version of a message board for articles. I'm tracking all IP
> > > addresses in a mysql column, but would now also like to add in
> > the
> > > ability to ban ip address.
> > >
> > > Any pointers, pieces of code, help etc??
> > >
> > > thanks!
> > >
> > >
> > > /sunny
> > >
> > > __________________________________________________
> > > Do You Yahoo!?
> > > Yahoo! Shopping - Thousands of Stores. Millions of Products.
> > > http://shopping.yahoo.com/
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > > For additional commands, e-mail: php-general-help@lists.php.net
> > > To contact the list administrators, e-mail:
> > php-list-admin@lists.php.net
> > >
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Shopping - Thousands of Stores. Millions of Products.
> http://shopping.yahoo.com/
>