Internet Explorer - how to stop an annoying little window

Discussion in 'PHP' started by tableman, Sep 20, 2006.

  1. #1
    I have a page in a secure subdirectory with a form.

    When the form is submitted, "action=" sends the entries to a separate php file in the same subdirectory, which, using mail(), emails the entries to me and, using header (location), opens a confirmation page which can not be in a secure subdirectory.

    This is not a problem to Netscape, Mozilla, Opera, and I expect most other browsers.

    However, Internet Explorer opens a window warning that "You are about to be redirected to a connection that is not secure. The information you are sending to the current site might be retransmitted to a non-secure site... "

    I don't want any visitor to be confronted by this window. I am hoping there is something I can put in the php file to prevent it from appearing.

    Does anyone know of a way to stop IE doing this without changing the basic setup I have described?
     
    tableman, Sep 20, 2006 IP
  2. wmtips

    wmtips Well-Known Member

    Messages:
    601
    Likes Received:
    70
    Best Answers:
    1
    Trophy Points:
    150
    #2
    wmtips, Sep 21, 2006 IP
  3. tableman

    tableman Peon

    Messages:
    36
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    There is one way to get IE to stop opening this useless message.

    Instead of using header(location), use print:

    
    print "<meta http-equiv=\"refresh\" content=\"0;URL=http://absolute_url.com/confirmation_page.php\">";
    
    PHP:
    However, I need .$_SERVER['QUERY_STRING'] to be appended to the URL and however I try, I can not get it to work with print.

    Does anyone know how to properly append .$_SERVER['QUERY_STRING'] with print?
     
    tableman, Sep 21, 2006 IP
  4. wmtips

    wmtips Well-Known Member

    Messages:
    601
    Likes Received:
    70
    Best Answers:
    1
    Trophy Points:
    150
    #4
    print '<meta http-equiv="refresh" content="0;URL=http://absolute_url.com/confirmation_page.php?'. $_SERVER['QUERY_STRING']. '">';
    PHP:
     
    wmtips, Sep 21, 2006 IP
  5. tableman

    tableman Peon

    Messages:
    36
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Thank you, wmtips.

    That works. What a relief.

    The punctuation for this is tricky, but you obviously know your php.

    I am so pleased you responded to my post.

    That was the last problem to be solved in this project.

    Now the whole process works from page to page in all browsers with no unnecessary pages popping up and no doofus security warnings.

    Resolved!
     
    tableman, Sep 21, 2006 IP
  6. MLDesigners

    MLDesigners Peon

    Messages:
    34
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Yet another success from digitalpoint posters

    Good job guys
     
    MLDesigners, Sep 22, 2006 IP