[colug-432] virtual hosts based on ip
Angelo McComis
angelo at mccomis.com
Wed Oct 14 14:05:24 EDT 2015
On Wed, Oct 14, 2015 at 1:39 PM, R P Herrold <herrold at owlriver.com> wrote:
> is there a purpose to unsolicited advice and prediction of
> gloom? The matter is trivially done with the REMOTE_ADDR
> variable and a header() command in PHP, and any mature CGI
> environment
>
> I'll poke at a proof of concept backed (by a database so that
> it is readily altered as to the redirect page by a site
> administrator). Static coding is even easier (load an array
> with IP's to go to the execption page, test if the REMOTE_ADDR
> is in_array(), and alternatively fall to a different header()
>
> Here is real code to that effect. Problem is that it mixes
> data (the IP / URL pairs, and code, which is not usually a
> very scalable approach, along with otehr reasons
>
Russ,
I didn't see any harm or foul for providing some experience-driven
insight. Look at it this way: Keith may not always be the owner of this,
and if he hands this off down the road, it may not be to someone as
skilled/capable.
I certainly don't mean to offend Keith for his question or direction, I
just wanted to provide a slight twist that might be a better choice that's
more easily maintained down the road.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.colug.net/pipermail/colug-432/attachments/20151014/74269b8e/attachment.html
More information about the colug-432
mailing list