PHP Classes

How Can PHP Redirect to Page in Your Site Users to Go to an External Site - PHP Redirect to Page Class package blog

Recommend this page to a friend!
  All package blogs All package blogs   PHP Redirect to Page Class PHP Redirect to Page Class   Blog PHP Redirect to Page Class package blog   RSS 1.0 feed RSS 2.0 feed   Blog How Can PHP Redirect ...  
  Post a comment Post a comment   See comments See comments (0)   Trackbacks (0)  

Author:

Updated on: 2021-02-23

Posted on: 2021-02-23

Viewers: 365 (February 2021 until October 2021)

Last month viewers: 2 (October 2021)

Package: PHP Redirect to Page Class

Redirecting users that access your Web site can be useful keep track of the statistics of users that click on links. It can also be used to show a message the users that click on a link before redirecting to the destination page.

Read this short tutorial article to learn how to achieve this in a simple way to another




Loaded Article

Tracking Clicks on Links to External Sites

For a recent project, one of the design specification requirements was to have all outbound links go through a sub-domain page before the user browser was actually redirected to their final destination.

This sort of semi-transparent redirect is seen all over the Internet. If you use a bulk email newsletter solution, you maybe familiar with this. Links inside of your email are translated into a unique URL, so the clicks on those links can be tracked.

Hiding the URL of Link Origin Pages

In other cases, it can be used to help hiding the actual destination site domain. In the past this was considered to be a more desired possibility because you could not want to let the external sites to discover the actual original URL of pages that were visited before the links were clicked, especially if it was from some internal domain or intranet or Web mail application.

However, nowadays virtually every site are accessed using encryption with HTTPS, the origin URL is already not fully disclosed. In any case, if you are using private domain names that are internal to the company or organization that you work for, this may be a desirable possibility.

How to Implement Controlled Link Clicking using the PHP Redirect to Page Class

In this specific project, we created a sub-domain and a landing page, so if anyone click on  external links, the user browser was redirected first to a page that explains our external link redirection policies.

I have written the PHP Redirect to Page Class to help controlling how to handle clicks on links that lead to external pages.

This class comes with full documentation and example code to help you implement it.

You can use it by either downloading its package files archive, install it with PHP Composer using instructions that you can follow in this page.

If you have questions regarding the use of this package, I am fully available through the support forum to help get you started.




You need to be a registered user or login to post a comment

1,588,068 PHP developers registered to the PHP Classes site.
Be One of Us!

Login Immediately with your account on:

FacebookGmail
HotmailStackOverflow
GitHubYahoo


Comments:

No comments were submitted yet.



  Post a comment Post a comment   See comments See comments (0)   Trackbacks (0)  
  All package blogs All package blogs   PHP Redirect to Page Class PHP Redirect to Page Class   Blog PHP Redirect to Page Class package blog   RSS 1.0 feed RSS 2.0 feed   Blog How Can PHP Redirect ...  
For more information send a message to info at phpclasses dot org.