The iframe size in the editor is different from the iframe size in the preview

Griffin BrownGriffin Brown Member
edited June 25 in Problems
For a template w/ HTML, I wrote:

<iframe src="https://app.webpt.com/patientChart.php?ID={{WebPT_ID__c}}";  width="100%" height="1000"> </iframe>

The dimensions work in the builder but not in the preview. Any suggestions?
image

image






Comments

  • Pat VachonPat Vachon Member 💎💎💎
    edited June 25
    Not sure why, but the dimensions stayed the same when I used you're template.

    image

    image

  • Rob HatchRob Hatch Skuad, Sonar ✭✭
    edited September 2016
    If you inspect the elements in the rendered page you will probably see that the iframe is broken after the ID is merged.  This is because the ID is getting put in with all its rendering code (including a bunch of HTML).   You need to merge the data in that iFrame with {{{Triple Braces}}}.   That will merge the ID Data alone,  no rendering will be attempted. 

    That shoudl fix your problem. 
  • Griffin BrownGriffin Brown Member
    edited December 2014
    That was super fast!

    One day I'll have you explain to me why that works, but for now I'll accept it dogmatically. :-)
  • Griffin BrownGriffin Brown Member
    edited December 2014
    It worked by the way
  • Griffin BrownGriffin Brown Member
    edited December 2014
    And Pat - you're lightning fast with your responses. Do you work for Skuid or are you just a do-gooder?
  • Pat VachonPat Vachon Member 💎💎💎
    edited June 25
    hehehe ... just really really really diggin it right now. The answer to all my salesforce dreams! So I've kinda been neck deep since starting to use it this month. :Pat
  • Rob HatchRob Hatch Skuad, Sonar ✭✭
    edited September 2016
    You guys are too much.  We love our raving fans!  We especially love the fact they are willing to help each other out!  Keep up the good work. 


  • RobinRobin Member
    edited May 2018
    Hi fellow Skuids,

    I'm struggling to implement even the most basic iframe in a template component. We're talking <iframe width="99%" height="600" src="http://www.google.com.au" /> here as a test. 
    I can't get any content to display in the iframe, however "invalid" data for the "src=" parameter produces Salesforce's "URL no longer exists" error message.

    Would this have to do with my Org's security settings, or where would I start troubleshooting it? The inspect element code of the rendered page is <div class="nx-template"><iframe width="99%" height="600" src="http://www.google.com.au"></iframe></div>.

    I might be missing something very obvious here! "Allow HTML" and "do not run template on each row" are selected. The model I picked for the template is the "User" model, which is loaded on page load and has data in it, but I also tried other models with the same result.

    Page include components which reference other Skuid pages render without issue.

    Any help is greatly appreciated!

    Thank you,

    Robin
  • Griffin BrownGriffin Brown Member
    edited December 2014
    Hey Robin,


    It's most likely the case that Google blocks the use of iframes for it's site for security reasons. Many of the big sites will do that. Try a smaller, less common site and it will likely work.


    -G
  • RobinRobin Member
    edited May 2018
    Hi Griffin!

    Thanks for helping out. I just tried different domains including our company site, still no joy unfortunately. Great thinking though, didn't consider that possibility.

    Forgot to mention (and hope this is the problem!): I am running the Superbank release, are iFrames still disabled in the beta?

    Much appreciated, 

    Robin
  • Rob HatchRob Hatch Skuad, Sonar ✭✭
    edited September 2016
    Robin,  iFrames are not disabled in the Superbank beta.  (at least I've been able to use them in Beta Orgs).  I'm guessing somthing else is afoot. 
  • Moshe KarmelMoshe Karmel Member
    edited December 2014
    Robin, you're probably having an issue with the iframe because you're loading a HTTP URL into a HTTPS page. Try loading in a salesforce page from your org.
  • Griffin BrownGriffin Brown Member
    edited December 2014
    Hey - Is it possible to get in on the Superbank release now?
  • Rob HatchRob Hatch Skuad, Sonar ✭✭
    edited September 2016
    Patience.  We plan to have a Release Candidate out on Friday. 
  • RobinRobin Member
    edited May 2018
    Moshe, it was as simple as using an https url! Thank you so much, I knew it was something really basic. Appreciate your contribution as well as everybody else's suggestions!!!

    Robin
Sign In or Register to comment.