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

i need help with php header and footer
I have designed a header and footer for my site and they seem to be ok when they are running individ

Bit manipulation program with binary operations
My homework is to create a program to scan in and add binary numbers and print them like so

Weird Problem with curl while sending data
I am facing a weird problem with sending data to a site via curl.

If i send the value by this

iterating through an array and escape each value independently.
I have a set up where the variable being escaped is an array and it needs to be iterated and escaped

Opening Multiple Files/Links in Order.
I want to open links in order/one-by-one and check each for a specific string.

Example:
I

URL Rewrite issue
Im created a series of Rewrites and on page checks to make sure the correct url is being called. But

UL and LI Add Form
The idea I want here is when the user click on a character name from the drop down select bar at the

mails going in spam??
The mails I sent to folks in my database using mail(function) are going in spam??

Any idea ho

Rounding a number queried from a database
I know that to display a rounded number you just do echo "round($number)";. But how would

socket communication between c++/java and sending image
hi,

i have a class in c++ called win32_sockserver which creates socket to java. i am trying

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