WordPress.org

Support

Support » How-To and Troubleshooting » Redirect my site

Redirect my site

  • symple1

    @symple1

    I have a sub-site I manage, I need to figure out how to allow access from only one wordpress page and not direct or from any other site. Can someone please assist, I have been trying this for a few weeks and I’m not getting good results.

    I want to allow access from www,site1.com/login to http://www.site2.com but from nowhere else.

    Again assistance would be very much appreciated.

    Rodney Smith

Viewing 1 replies (of 1 total)
  • I don’t know very well your problem.

    If you want block direct access to theme php files. You can put this code in the initiation of your php theme file:

    if( ! defined( 'ABSPATH' ) ) die( 'Forbidden for direct access.' );

    If you want block visit outside of your domain, you can treat the $_SERVER['HTTP_REFERER'].

Viewing 1 replies (of 1 total)
  • The topic ‘Redirect my site’ is closed to new replies.
Skip to toolbar