Advanced Search

Results 1 to 3 of 3

Thread: http/ https problem

  1. #1
    Join Date
    Feb 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default http/ https problem

    Recently, I've got a problem in building up a website.
    I have to migrate my website from http one to https.
    But there is a problem.

    in http:
    after database processing, it redirects the internal page by using func header("Location: xxx.php");.
    It works properly.

    However:
    in https:
    func header("Location: xxx.php"); doesn't work anymore, it states in its own URL only.

    Should I make some changes in my server setting?
    Or it is always to have this problem?

    I can't find any solution from google or sth.
    Please help me if anyone get idea. T.T
    Thanks

  2. #2
    Join Date
    Sep 2005
    Location
    India
    Posts
    1,626
    Thanks
    6
    Thanked 107 Times in 107 Posts

    Default

    Try the following method

    PHP Code:
    <?php
        $redirUrl 
    "Location: https://www.example.com/page.php";
        
    header($redirUrl);
    ?>
    Use your domain name and page name in the above mentioned URL

  3. #3
    Join Date
    Feb 2008
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by codeexploiter View Post
    Try the following method

    PHP Code:
    <?php
        $redirUrl 
    "Location: https://www.example.com/page.php";
        
    header($redirUrl);
    ?>
    Use your domain name and page name in the above mentioned URL
    Thanks your reply.
    I tried it b4.
    it doesn't work 2.
    Is there any difference between "Location: https://www.example.com/page.php"; and "Location: page.php";?

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •