Results 1 to 8 of 8
  1. #1
    Join Date
    Jan 2007
    Location
    Illinois, USA
    Posts
    312
    Plugin Contributions
    0

    help question Frame redirection of a domain to ZC

    using ZC 1.5.7c and I am trying to redirect another domain to a specific EZ page. The domain is showing a blank page when it loads, but if I tell it to load the specific frame, it then displays.

    Heres the html code I am using on the index of automotiveforms.net to redirect. Any thoughts?

    <html>
    <head>
    <title> Automotive Forms </title> <!-- This text will be shown as name of the page -->
    </head>
    <frameset>
    <frame src="https://needtoorder.com/index.php?main_page=page&id=31">
    </frameset>
    <noframes>Your browser does not support frames. Please click <a href="https://needtoorder.com/index.php?main_page=page&id=31"> here </a> to be redirected automatically </noframes> <!-- This tag is required for old browsers. If browser does not support frames, end user will see a message indicated between <noframes>...</noframes> -->
    </html>
    NTO: building a better network thru collaboration
    www.needtoorder.com | www.coffeewitheinstein.com

  2. #2
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,239
    Plugin Contributions
    1

    Default Re: Frame redirection of a domain to ZC

    Quote Originally Posted by Carbonless View Post
    using ZC 1.5.7c and I am trying to redirect another domain to a specific EZ page. The domain is showing a blank page when it loads, but if I tell it to load the specific frame, it then displays.

    Heres the html code I am using on the index of automotiveforms.net to redirect. Any thoughts?

    <html>
    <head>
    <title> Automotive Forms </title> <!-- This text will be shown as name of the page -->
    </head>
    <frameset>
    <frame src="https://needtoorder.com/index.php?main_page=page&id=31">
    </frameset>
    <noframes>Your browser does not support frames. Please click <a href="https://needtoorder.com/index.php?main_page=page&id=31"> here </a> to be redirected automatically </noframes> <!-- This tag is required for old browsers. If browser does not support frames, end user will see a message indicated between <noframes>...</noframes> -->
    </html>
    Guessing a bit here, but perhaps try adding <!DOCTYPE html> to the code and replace frameset with iframe

    Code:
    <!DOCTYPE html>
    <html>
    <head>
    <title> Automotive Forms </title> <!-- This text will be shown as name of the page -->
    </head>
    <iframe src="https://needtoorder.com/index.php?main_page=page&id=31"></iframe>
    <noframes>Your browser does not support frames. Please click <a href="https://needtoorder.com/index.php?main_page=page&id=31"> here </a> to be redirected automatically </noframes> <!-- This tag is required for old browsers. If browser does not support frames, end user will see a message indicated between <noframes>...</noframes> -->
    </html>
    Simon

  3. #3
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Frame redirection of a domain to ZC

    Out-of-the-box and on "relatively" recent browsers, Zen Cart effectively prevents such an action of a Zen Cart site at a different domain name to be displayed within the frame/iframe... Meaning, if the Zen Cart store is at needtoorder, but the site attempting to provide that iframe is *NOT* at needtoorder, then it will not work.

    Why is this being attempted rather than performing a redirect?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #4
    Join Date
    Jan 2007
    Location
    Illinois, USA
    Posts
    312
    Plugin Contributions
    0

    Default Re: Frame redirection of a domain to ZC

    Quote Originally Posted by mc12345678 View Post
    Out-of-the-box and on "relatively" recent browsers, Zen Cart effectively prevents such an action of a Zen Cart site at a different domain name to be displayed within the frame/iframe... Meaning, if the Zen Cart store is at needtoorder, but the site attempting to provide that iframe is *NOT* at needtoorder, then it will not work.

    Why is this being attempted rather than performing a redirect?
    The 2 businesses have merged… more of transition phase, but if possible, preferred method of rebranding.
    NTO: building a better network thru collaboration
    www.needtoorder.com | www.coffeewitheinstein.com

  5. #5
    Join Date
    Jan 2007
    Location
    Illinois, USA
    Posts
    312
    Plugin Contributions
    0

    Default Re: Frame redirection of a domain to ZC

    Will attempt….
    NTO: building a better network thru collaboration
    www.needtoorder.com | www.coffeewitheinstein.com

  6. #6
    Join Date
    Jan 2007
    Location
    Illinois, USA
    Posts
    312
    Plugin Contributions
    0

    Default Re: Frame redirection of a domain to ZC

    Quote Originally Posted by simon1066 View Post
    Guessing a bit here, but perhaps try adding <!DOCTYPE html> to the code and replace frameset with iframe

    Code:
    <!DOCTYPE html>
    <html>
    <head>
    <title> Automotive Forms </title> <!-- This text will be shown as name of the page -->
    </head>
    <iframe src="https://needtoorder.com/index.php?main_page=page&id=31"></iframe>
    <noframes>Your browser does not support frames. Please click <a href="https://needtoorder.com/index.php?main_page=page&id=31"> here </a> to be redirected automatically </noframes> <!-- This tag is required for old browsers. If browser does not support frames, end user will see a message indicated between <noframes>...</noframes> -->
    </html>
    changed the code and I get a browser alert in Firefox .. see attached screenshot
    Click image for larger version. 

Name:	Screen Shot 2021-08-12 at 2.05.36 PM.png 
Views:	13 
Size:	46.1 KB 
ID:	19702
    Click image for larger version. 

Name:	Screen Shot 2021-08-12 at 2.05.52 PM.png 
Views:	16 
Size:	40.8 KB 
ID:	19703

    from safari, this what i get
    Click image for larger version. 

Name:	Screen Shot 2021-08-12 at 2.08.32 PM.png 
Views:	17 
Size:	10.1 KB 
ID:	19704

    working on some code changes.... but nothing working yet.
    NTO: building a better network thru collaboration
    www.needtoorder.com | www.coffeewitheinstein.com

  7. #7
    Join Date
    Jan 2007
    Location
    Illinois, USA
    Posts
    312
    Plugin Contributions
    0

    Default Re: Frame redirection of a domain to ZC

    abandoning this process.... going with a standard redirect
    NTO: building a better network thru collaboration
    www.needtoorder.com | www.coffeewitheinstein.com

  8. #8
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,748
    Plugin Contributions
    0

    Default Re: Frame redirection of a domain to ZC

    line 20 of the common/html_header.php has
    Code:
    header('X-Frame-Options:SAMEORIGIN');
    The X-Frame-Options HTTP response header can be used to indicate whether or not a browser should be allowed to render a page in a <frame>, <iframe>, <embed> or <object>. Sites can use this to avoid click-jacking attacks, by ensuring that their content is not embedded into other sites.

    If you need to maintain PCI compliance you need to have this. The days of easily showing content from one site on another by just showing it in an iframe are over. There are ways to do it that require making adjustement to content security policy where you list those domains that are allowed to show content from the main site.
    Mike
    GeekHost - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

 

 

Similar Threads

  1. domain redirection problem
    By zerohanzo in forum General Questions
    Replies: 1
    Last Post: 20 May 2010, 04:52 AM
  2. Changed domain but still being led back to old domain
    By thorntongoats in forum General Questions
    Replies: 0
    Last Post: 23 Feb 2010, 01:08 AM
  3. Domain redirection questions
    By rooisnor in forum Basic Configuration
    Replies: 30
    Last Post: 9 Dec 2008, 09:47 PM
  4. Help My domain rewrites to http://domain.com instead of www
    By toussi in forum Installing on a Linux/Unix Server
    Replies: 3
    Last Post: 21 Aug 2008, 03:55 AM

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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR