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.

cheapest limo Akin .. Lockport Chicago limo O’Hare
In The News:

Tech expert Kurt “CyberGuy" Knutsson says using outdated computers and software leaves them vulnerable to security risks and malware.
Tech expert Kurt “CyberGuy" Knutsson reveals how WalkON enhances walking and jogging with sensors and artificial tendons.
Old-fashioned check fraud is back in style, quintupling over the past year. Here are a few low-tech, practical means of protecting yourself.
Tech expert Kurt “CyberGuy" Knutsson discusses how 600,000-plus records, including checks and property data, were left exposed online by an information service provider.
That weird text from a friend may actually be from a hacker. Kurt “CyberGuy" Knutsson tells you what signs to look out for.
Scammers can wreak havoc on your life just by having your phone number. Kurt "CyberGuy" Knutsson addresses how to avoid becoming a victim.
PongBot is an artificial intelligence-powered tennis robot and a smart training partner available to play 24 hours a day, seven days a week.
Kurt "CyberGuy" Knutsson explains how to update your iPhone to add Apple Intelligence, which he says can transform your interactions with your phone.
University scientists have trained a robotic surgical system to do work with the skill of human doctors, possibly transforming the future of surgeries.
As more companies implement artificial intelligence for daily tasks, some industry leaders are working to push back against certain aspects of the technology.
Tech expert Kurt “CyberGuy" Knutsson says the Batagaika crater in Siberia expands 35 million cubic feet yearly due to thawing.
While fewer than 30% of farmers reportedly use emerging technologies like artificial intelligence, experts believe AI could help producers and farmers make food quicker and more efficiently.
Amazon becomes a prime target of scammers during the holiday shopping season trying to steal Social Security numbers, bank information and Amazon credentials.
Spammers have found a way to target Spotify playlists and podcasts to push pirated software, cheat codes for games and spam links and malware sites.
Sharing information online like your vacation plans and relationship status can make you a target for scammers; here's what to avoid posting to keep yourself safe.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
Kurt "CyberGuy" Knutsson explores six sneaky holiday season gift card tricks, providing tips on how to outsmart scammers trying to rip you off.
Apple Watch's Translate app gives you your own personal interpreter, allowing you to have live two-way conversations in up to 20 different languages.
With kids facing a seemingly increasing amount of threats from creeps on the internet, here's how you can respectfully ask people not to post photos of your children on social media.
Tech expert Kurt “CyberGuy" Knutsson reveals how to regain your Facebook access if you get hacked or locked out.
Kurt “CyberGuy" Knutsson explains how to safeguard retirement accounts from cyber threats with a VPN: encryption, anonymity, secure access.
I’m going to Europe soon, and planning my trip was a breeze. Yes, really! AI did a big chunk of the work for me — and it can help you plan your next getaway, too.
Tech expert Kurt “CyberGuy" Knutsson says North Korean hackers hide malware in macOS apps, bypassing Mac security checks.
Kurt “CyberGuy" Knutsson reveals how iPhone’s new Automatic Mic Mode adjusts settings for optimal call quality automatically.
Jeff Hancock, an expert on AI and misinformation, has been accused of fabricating an expert declaration by citing a study that was allegedly made up by AI.

How To Convert More Sales On Your Website

One of the biggest mistakes that most online retailers make... Read More

I Did It: Six Months to a Successful Website

For years now I've been looking to start my own... Read More

How To Start Your Own Website

I'm one of those people that always wanted a website,... Read More

Disability Discrimination Act (DDA) & Web Accessibility

There's been widespread speculation about the new legislation being introduced... Read More

Credibility - 10 Ways to Build it on Your Website

If you have your own business website and you are... Read More

Create Huge Income From Your Web Site - 10 Easy Ways

The cost of setting up a web site is dirt... Read More

7 Reasons YOU Need a Website

1) A marketing necessityI still hear it said from time... Read More

Are You Being Scammed By Your Web Design Company?

This is a growing concern amongst many business owners. Does... Read More

Improve Conversion Rates ? Effective Content

Your site is fast and getting traffic, but conversion rates... Read More

How to Increase Sales with Automation Improvements

How popular is online shopping? And is there room for... Read More

7 Tips to Make Your Order Page Work Harder

So your prospect, Mary, is sitting at the computer reading... Read More

The Power Is In The Pipes: How To Get Maximum Leverage From Your Website

What is the most important part of your online business?Many... Read More

Making The Business Case For Web Standards

Through the explosive growth of the Web, companies have realized... Read More

PHP Redirect

A PHP Redirect automatically transfers a web user from one... Read More

The Web: Your Window of Opportunity

Thinking about starting up a business? The web is the... Read More

Newsletter Management Using PHP w/o mySQL for Beginners

Let's begin by setting some limits. If you're like me,... Read More

4 Marketing Tips for Resourceful Webmasters!

The internet is a sea of knowledge. Getting your information... Read More

Why Do I Need A Web Site?

Even though the Internet has been around for a long... Read More

Writing Effective ALT Text For Images

Anyone who knows anything about web accessibility knows that images... Read More

Website Content & Usability

Writing for the web is totally different to writing for... Read More

Stop Losing Precious Web Site Traffic to the Dreaded World Wide Web Black Hole

You work hard to build traffic to your web page.... Read More

If Its Done Its Done for: Make Your Website Part of Your Business before You Build

Web sites are an Ongoing Part of Business.All too many... Read More

Why You Really Need Your Own Web Page In-order To Make Online Business!

How many Web Sites did you stumble over telling you... Read More

WYSIWYG Versus Coding: HTML With A Purpose

After years of working with entrepreneurs who developed their first... Read More

Traffic for Webmasters

"If you build it, they will come"; is an age... Read More

Aledo wedding limo ..