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.

maide service in Lincolnshire ..
In The News:

Discover Android's new Sound Notifications feature that alerts you to smoke alarms, doorbells, and baby cries even when wearing headphones.
New SantaStealer malware reportedly threatens holiday shoppers with password theft. This Christmas-themed info-stealer targets browsers and crypto wallets.
The Christmas season brings a surge in Netflix phishing scams targeting shoppers with fake emails. Stacey P received convincing scam but verified account first.
San Francisco Giants invite Jamie Grohsong to throw ceremonial first pitch at Oracle Park after he learned to play baseball with a bionic hand following an injury.
FBI warns cybercriminals are stealing family photos from social media to create fake proof of life images in virtual kidnapping scams targeting victims.
Instagram's new 'Your Algorithm' tool lets you control your Reels feed in real time. The app now gives you power to customize what videos you see.
Major Marquis fintech breach exposes 400,000-plus Americans' data through unpatched SonicWall vulnerability, with Texas hardest hit at 354,000 affected.
Free up iPhone storage fast by clearing large photos and videos from Messages app. Simple steps for iOS users to delete attachments without losing chats.
Scammers are flooding inboxes with fake tracking alerts that mimic real carriers, exploiting the holiday rush to steal logins and personal data.
The Fox News AI Newsletter brings you the latest news on AI technology advancements and the challenges and opportunities AI presents now and for the future.
Texas family reunites with missing 11-year-old cat Grayson after 103 days using Petco Love Lost's AI photo matching technology and community help.
Tired of AI customer service loops? These insider tricks help you escape "frustration AI" and get real human help when you need it most for urgent issues.
Unlock richer audio from your streaming apps with simple tweaks to volume normalization, equalizer settings, and quality preferences for cleaner sound.
Scammers are sending fake Facebook settlement payout emails that mimic legitimate notices from the privacy settlement administrator to deceive users.
Holiday shopping scams surge as fake refund emails target distracted consumers during Black Friday and holiday seasons, costing Americans billions annually.
The AI-powered IRMO M1 exoskeleton features four modes, including turbo, eco, training and rest for hiking, running, cycling and sports with eight-hour battery life.
OpenAI announced upgrades for its ChatGPT Images platform on Tuesday, saying the program can now make more precise edits and produce images more quickly.
Chrome for Android now turns web articles into AI-powered podcast conversations. Get hands-free browsing with Google Gemini's natural audio summaries.
LastPass faces $1.6 million fine from U.K. regulators after 2022 data breach exposed 1.6 million users. Password manager failed proper security controls.
Petco disclosed a data breach exposing customer Social Security numbers, financial account details, and driver's license information due to a software error.
Baseball teams can now analyze complete swing mechanics in normal training environments using Theia's markerless AI system that processes standard high-speed footage.
Smart home hacking fears overblown? Expert reveals real cybersecurity risks and simple protection tips to keep your connected devices safe from hackers.
MIT develops needle-free glucose monitor using light technology. Revolutionary device could replace painful finger pricks for diabetes management.
The ClickFix campaign disguises malware as legitimate Windows updates, using steganography to hide shellcode in PNG files and bypass security detection systems.
Researchers from Osaka Metropolitan University designed a 21-foot dome that combines aquaculture and hydroponics to create a self-sustaining urban food system.

Do Authors Need a Website?

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

Why Is No-one Buying From My Website?

Are you, like many other website owners, frustrated at the... 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

Credibility - 10 Ways to Build it on Your Website

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

Web Measurement: What You Don?t Know Would Make A Great Book

"What's in it for me?" you ask. "Why should I... Read More

Make Your Web Site Stand Out

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

Art, Artists and the Web: Part 4--What to Do After a Website is Designed

What to do if you are an artist after you... Read More

How To Convert More Sales On Your Website

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

The Importance of Website Stats to You

One of the best tools you have as a webmaster... Read More

9 Keys to an Effective Website

Many small companies choose not to invest in a professionally... Read More

The Secret Benefit Of Accessibility: Part 2 - A Higher Search Engine Ranking

An additional benefit of website accessibility is an improved performance... Read More

Maximizing ROI via Web Site Traffic Analysis

We are clearly well past the innocent "golden age" of... 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

Why a CSS Website Layout Will Make You Money

Although CSS layouts have been around for years, they haven't... Read More

Website Globalization

Globalize Your WebsiteThe Internet has unlocked a wide array of... Read More

What is Blogger.com?

In the late 1990's three San Francisco based web developers... Read More

Guide to Internet Business - Design and Content

After deciding what kind of internet business you want to... Read More

Websites: You Get What You Pay For!

So you finally decided to invest in a web presence... Read More

A Web Site for Your Small Business: How to Set Up a Website

Your web site will be your window to the world.... Read More

12 Essential Tips to a Professional Business Website

1. Choose a big enough font size. A size 12... Read More

Planning A Usable Website: A Three-step Guide

A website is like an information flow, with you as... Read More

How Disabled Users Access The Internet

In 1995 a new era of accessibility for disabled people... Read More

Conceptualize, Build and Publish a Web site

Conceptualize, Build and Publish a Web site - What's required... Read More

How to Listen on the Web

When building a relationship, listening is more important than talking.A... Read More

The Problem with Automated Accessibility Testing Tools

An automated accessibility tool is a piece of software which... Read More

cleaning lady near Deerfield ..