Website Direction...


Posted on 16th Feb 2014 07:03 pm by admin

I recently used this code to try and make it so the page loads as http://www.domain.com/ when you type in http://domain.com
I thought this code would make sense and be a solution, but just loops.
Could anyone explain please.
Thanks in advance..
Did you know?Explore Trending and Topic pages for more stories like this.

Code: <?php
$server = $_SERVER['HTTP_REFERER'];
if ($server == "http://www.domain.com/") {
echo "Hello World";
} else {
header("Location: http://www.domain.com/");
}
?>
No comments posted yet

Your Answer:

Login to answer
245 Like 37 Dislike
Previous forums Next forums
Other forums

Members Only
Hi all, for my website i have a members area only which on members can veiw, but at the moment anyon

Calculating n! using vector
#include
#include
#include

using

Unable to display contents in Second Drop Down Box
Hi All,

What I am trying to do is 2 dependent drop down boxes and when user selects su

I need some help with the IF command...
I have a large number of images in one section of my website with the .jpg format. I'm adding a bun

Syntax Help
Code:


im having trouble with that code snipped
Parse error: syntax error, unexpec

Passing variables with pagination - iterating through unique id per link
Hi everyone,
I have seen a few topics like this one. Still cant find the specific thing, so I am

php mysql script to find record
Hi,

Currently I have a simple table with 4 columns. A, B, C, D

If I want to find all

Transform value 0 in no and 1 in yes help needed
Hello,
I have this in the table: "value" type int 0 to represent false and 1 to represe

Validation
Hello

I know this is a really vag question.

I need to have a input field on a form th

Word filter problem
Hello,

im trying to make a filter for words inputted in to my website but i want to store the

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash