function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

iFrame VF page into a site

I have developed a VF page that I would like to frame into a standard html page on a webserver.  If I am logged into SF in another tab, everything works great.... but if I logout and try to go directly to my page with the iFrame... I get a blank white box with this source:



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" ""> 
var escapedHash = '';
var url = '';
if (window.location.hash) {
   escapedHash = '%23' + window.location.hash.slice(1);
if (window.location.replace){ 
window.location.replace(url + escapedHash);
} else {;
window.location.href = url + escapedHash;


Which makes it look like the login page should be appearing.  Also, if I paste the URL variable into my browser, everything works fine.




















The page you're embedding may assume it's the topmost window. Are there any JavaScript errors that are preventing the login page from loading?


No javascript errors.


IE gives this in the window:

This content cannot be displayed in a frame


To help protect the security of information you enter into this website, the publisher of this content does not allow it to be displayed in a frame.


Here's the basic html:




<iframe src="" frameborder="0" />






Hi, create a site using salesforce sites in your org. Make it public. Once it is made public, give that url to the iframe src in html file you are placing on the server.