PHP Redirect

A PHP Redirect automatically transfers a web user from one URL to another. For example, typing foo.com in the browser automatically transfers the user to another URL bar.com.

The PHP Redirect command:

Replace [some-url] with the URL where you want the redirection to take place.

For example,

header("location: ./version2/index.html"); =>redirect to "index.html" page in subfolder called "version2"

header("location: http://www.yahoo.com"); =>redirect to a website called yahoo.com

If PHP is not available, it's also possible to use other redirects:

* HTTP Redirects

Replace [time] with seconds. This will pause the browser for the specified number of seconds. Replace [some-url] with the target URL you want to redirect.

For example,

The above HTTP based redirect needs to be in the region of the HTML code.

* JavaScript Redirects

setTimeout("location.href='[some-url]'", [time]);

Replace [time] with milliseconds. This will pause the browser for the specified number of seconds. Replace [some-url] with the target URL you want to redirect.

For example, setTimeout("location.href='http://www.yahoo.com'", 5000);

The above JavaScript based redirect can be either in the or region of the HTML code.

Usually a PHP redirect is much more reliable than other form of redirects like HTTP redirect or JavaScript based redirects. For example a JavaScript redirect may not work if a user's browser settings has JavaScript turned off.

The reason why PHP redirects will work no matter what settings users have on their browser is because PHP is server side script. It will not depend on browser settings that may affect JavaScript which is parsed on the client-side/user-side.

About the Author
Sanjib Ahmad, Freelance Writer and Product Consultant for http://www.marc8.com.

You are free to use this article in its entirety as long as you leave all links in place, do not modify the content, and include the resource box listed above.

Lincolnshire shuttle from Midway .. Lockport Chicago limo O’Hare
In The News:

An automotive maker in China has developed a flying car that is setting the stage for a new era in how we think about commuting and connectivity in cities.
Most cameras allow you to instantly transfer images from a camera to a smartphone via Bluetooth, and you can print photos directly from your phone.
Security researchers have found a fake app pretending to be a version of the messaging app Telegram, and hackers are using the app to spread malware.
Meta recently announced it will cease working with third-party fact-checking organizations to flag misleading posts on Instagram, Facebook and Threads.
Scientists have developed a floating solar still device that is capable of harnessing the sun's energy to purify seawater and withstanding harsh maritime conditions.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
Tech expert Kurt “CyberGuy" Knutsson says business email compromise scams are a serious threat, as shown by Teresa W.'s near loss of thousands of dollars.
Big tech coming in 2025 includes solar umbrellas, AI TVs, smart earbuds and crazy robots. Tech expert Kurt “CyberGuy" Knutsson gives his take on the wonders revealed at CES 2025.
Tech expert Kurt “CyberGuy" Knutsson provides two methods to restore your contacts for iPhone and Android devices.
FBI warns that criminals are using generative AI to exploit individuals with deceptive tactics. Kurt “CyberGuy" Knutsson explains their tactics and how to protect yourself from them.
Tech expert Kurt “CyberGuy" Knutsson says hackers are embedding dangerous code in Chrome extensions to steal your data.
Google Maps Location Sharing is now built into Android settings; no need for Maps settings. Tech expert Kurt “CyberGuy" Knutsson discusses the welcome improvement for Android users.
Not all apps out there offer legit virtual private networks, according to Kurt the CyberGuy. He explains how to keep your information safe.
Apple's Image Playground transforms text prompts into images or animations in seconds, brining a world of creativity to the palm of your hand.
NASA's Ingenuity helicopter, which flew on Mars in April 2021, became the first aircraft to achieve powered, controlled flight on a planet other than Earth.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
Thieves who have iPhones can usually detect a hidden AirTag in vehicles they are attempting to steal, and an RFID wallet may not help you.
Genmoji, the latest addition to Apple's Apple Intelligence suite, uses artificial intelligence to generate customized emoji based on text descriptions.
It's easy to find yourself swamped in unread emails. Here are a few simple steps to archiving them and clearing out some of your digital clutter.
Keep your retirement plan safe from data brokers selling your personal information. Kurt the CyberGuy explains how to protect yourself and your retirement.
Turo faces scrutiny after tragic incidents involving rented vehicles, raising questions about security measures and regulatory frameworks.
A Chinese company has developed a spherical, 276-pound law enforcement robot that has been chasing down criminals at impressive speeds.
Here are some powerful online sleuthing tricks you can use to check the credibility of a website, see old pictures of places you've lived and even learn more about your neighbors.
Beware scam calls: Avoid unknown numbers and protect your personal information. Tech expert Kurt “CyberGuy" Knutsson talks about the increasingly common scam.
Tech expert Kurt “CyberGuy" Knutsson helps you crush your New Year's goals with these 12 apps to help you stay on track and succeed.

Why You Need A Web Site

"I have a small business with just a couple of... Read More

10 Simple Steps: Its Magic If You can E-Mail You can Update Your Web Page Dynamically

Dynamically Update Your Web Pages Via E-MailIf you can Send... Read More

Live Support from Your Website? Can You Do It for Free?

I'm a freelance programmer and somehow I managed to get... Read More

Learn to Build a Better Online Business Website Using Keywords and Content

Are you aware that 90% of the websites on the... Read More

Guidelines for Web Page Optimization

Below, I have listed 8 simple steps that you can... Read More

How to Handle Web Surfers Who Disabled JavaScript

There are hundreds of millions of Web surfers today. Each... Read More

Direct Sales and Your Corporate Website - A Creative Marketing Plan that Works!

Creatively marketing your corporate site takes time in the set... Read More

Adding Word Rich Content to Your Website

You have permission to publish this article electronically, in print,... Read More

You May Be Losing Valuable Traffic - And Not Even Know It!

Here's something you may never have thought of before:If I... Read More

In Business? 10 Reasons Why You Need a Website -- Now!

1) Word of Mouth The single most powerful form of... Read More

Free Isnt Always Good - 5 Reasons Why You Need Your Own Website

Often time I've browsed sites and seen the same thing... Read More

5 Sure Fire Ways To Send Visitors Away For Good

So your traffic is going through the roof yeah? It's... Read More

Do You Really Need A Website To Succeed

Rosalind wants to share her inspirational poetry with a wider... Read More

Your Content for Nothing and Your Clicks for Free

The first thing my business consultant (read brother-in-law) asked me,... Read More

Is Your Website Innovative? Increase Your Business Over Night!

While studying online for IT investment opportunities, I found that... Read More

Beautiful Web Sites Seldom Make More Sales

Designing an E-commerce Web site is not as simple as... Read More

Having a Domain Name And Web Site Gives Your Business The Key To The Door

Just like all things in life, the ways to run... Read More

Website Survival Guide

In the big, wide online world there are millions of... Read More

Do You And Your Website Have Credibility?

I recently received an unsolicited e-mail from some company offering... Read More

Should You Design Your Own Website?

If you're anything like most small business owners, you probably... Read More

Content Management ? The New Standard in Web Design

The evolution of web development parallels the model of technology... Read More

Using Psychology Easily on Your Website to Make More Sales!

Psychology is a long word which everyone thinks, "no, that's... Read More

Email Addresses in Web Pages

You want to give your site's visitors a way to... Read More

Beware the Software Siren

I've heard several prominent web marketers mention in their classes... Read More

Maximizing ROI via Web Site Traffic Analysis

We are clearly well past the innocent "golden age" of... Read More

Algonquin limo Chicago ..