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.

spotless home service Morton Grove ...
In The News:

Jeremiah Fowler discovered an unsecured database of nearly 2 billion login credential records, some holding passwords and browser session tokens.
Cleverbridge says hackers copied card numbers, expiration dates and CVV codes in a data breach, and it offers credit monitoring to affected cardholders.
Theia3D uses markerless motion capture to study how walking changes with age, tracking joint movement in older adults wearing everyday clothes.
Citi's updated banking agreement warns that actions by third-party AI agents may be treated as authorized by you, even after a hack leaks your credentials.
Uber Kids lets children as young as 10 ride alone in a pilot across Austin, Nashville and Madison, with live video, PIN verification and RideCheck alerts.
Kurt "CyberGuy" Knutsson explains why stolen data can resurface years after a breach, plus tips on free credit freezes and password managers.
Sean Duffy flew a $148,000 Jetson One solo over NASA's Kennedy Space Center. Two days later, five eVTOLs flew in formation at a public airshow.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
An AI bionic eye trained on a blind man's brain responses helped UC Santa Barbara researchers produce more predictable phosphenes with less current.
A researcher claims Google Gemini pulled private Gmail billing details into chats, and Google confirms some connected-app data may face human review.
Housefishing scams use AI real estate photos to fool buyers. Google Lens reverse image search and live video walkthroughs can help expose the fakes.
Data brokers may expose your name, home address and phone number to scammers sending fake USPS delivery texts ahead of the Black Friday shopping rush.
Remus Stealer malware developers claim Gmail access survives a password change, but Google says the attack targets infected devices, not a Gmail flaw.
Palmer Luckey says SLAB, his floating industrial city, would last 1,000 years, hosting metal processing and oil refining beyond California rules.
United Airlines is blocking unauthorized AI travel agents from its booking systems, warning that automated purchases could put MileagePlus miles at risk.
Apple's macOS 27.3 beta 2 adds new Mac security controls for AI agents, letting you pick specific protected folders instead of granting Full Disk Access.
Google's AI used smartwatch sensors to spot hypertension without a blood pressure cuff, but the Nature study found it missed about 1 in 3 cases.
The FBI warns the ARTEX AI hacking tool can give criminals privileged access in under three hours, targeting Microsoft 365 and financial firms.
The FDA-authorized Virtuoso Endoscopy System uses needle-sized robotic arms to remove bladder tumors intact, helping pathologists assess detrusor muscle.
Identity theft restoration involves credit freezes, fraud alerts and disputing fraudulent records. Here's how the recovery process works, step by step.
Genesis AI raised $500 million to expand its general-purpose robot Eno, which learns physical skills from workers wearing special electronic gloves.
JPMorgan Chase says hackers accessed marketing data at third-party vendors as an extortion group leaks records tied to Visa and Mastercard customers.
Uber Parking launches in 15 U.S. cities after the SpotHero deal, offering upfront prices, Uber One credits, and a future role for robotaxis in garages.
The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
Microsoft Outlook flaw CVE-2026-124194 lets a malicious .msg file expose NTLMv2 authentication data, and Microsoft confirms hackers already exploited it.

Should You Design Your Own Website?

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

Why A Simple Counter is Never Enough for Your Website

A simple website stats counter is not enough if you... Read More

1 Simple Solution to All Internet Marketers about Their Website Design Needs

It is an undeniable fact that not everybody is keen... Read More

Traffic for Webmasters

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

Making Your Website Shine! Attract and Keep Visitors at Your Site!

When you consider the billions of individuals and companies on... Read More

Is Your Website Innovative? Increase Your Business Over Night!

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

Make Your Web Site Stand Out

When visitors add your web site to their Favorites or... Read More

Tell me what your website does!

You know exactly what your organisation does and what your... 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

Lead Generation How to -- 10 Tips On Generating More Internet Sales Leads

Many millions of dollars are being wasted on promoting and... Read More

Tips for Building a Great Business Website

A website is lifeline of internet home business. In order... Read More

HTML Editors 101 - Smaller Is Better

SiteSpinnerSiteSpinner is a user-friendly web site development tool that includes... Read More

Increase Your Affiliate Earnings with a Smart Webmaster Plan

Affiliate programs are a great way to earn an income... Read More

Streamline your Business Website with a Content Management System

I talk with so many people who have small businesses... Read More

Business Website Building Do?s and Don?ts

First, using a lot of web graphics, flash, banners and... Read More

Making the Most of Your Website: Start with the Basics

One of my most salient memories from when I sold... Read More

How To Start Your Own Website

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

The Evolution Of Search

There have been many significant changes to the face of... Read More

New Years Resolutions: Is Improving Your Website One of Them?

With the New Year upon us yet again, it's time... Read More

Do You Need a Web Database?

Does My Web Site Require A Web Database?If your web... Read More

Top 5 Reasons to Track Your Website Traffic

#5 User Satisfaction: Learn what your visitors and site users... Read More

Server Side Includes (SSI) with ASP

Server Side Includes (SSI) with ASP People often... Read More

Do You Really Need A Website To Succeed

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

Developing A Login System With PHP And MySQL

Most interactive websites nowadays would require a user to log... Read More

Do Authors Need a Website?

"I am a writer, not a business-person. I don't want... Read More

one time home cleaning Park Ridge ...