Hybrid View

  1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    40
    Vote Rating
    0
    jwbworks is on a distinguished road

      0  

    Default Unanswered: iframed page is showing noscript content

    Unanswered: iframed page is showing noscript content


    hello all. to show external urls I am taking a panel and dynamically adding an iframe tag as the html value. However if the child page has a no script tag it is showing the content. How can we show a no script tag content in a JavaScript based app?

    this is a mobile site and a native app using touch 2.0

    thanks

    Jeff

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,632
    Answers
    3452
    Vote Rating
    817
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    I would try to stay away from iframes as certain interactions, most notably scrolling, won't work. If it's plain HTML then you can do an Ajax request and then insert that HTML into a component using the setHtml method.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    40
    Vote Rating
    0
    jwbworks is on a distinguished road

      0  

    Default


    Mitchell,

    Thanks for writing back.we unfortunately have no other option but to use iframes. Out mobile site as well as out native app both have external links to privacy policies and other important information. Since Sencha does not have a means to spawn a native browser to open these links we are forced to use the iframe to show the content and use a toolbar with a back to app that will then destroy the panel with the iframe and return the user to the app. This method was actually suggested by Sencha's support team they explain it is a hack but if we use Sencha to build our app we are pretty much pegged in to this situation.
    \
    As for the no script we did some more testing and found the issue. we are using the new html 5 sandbox attribute for iframe. This covers scripting, forms domain permissions and navigation. normally if you leave the attribute value as empty it applies all permissions. however in this iframe some things were not getting communicated in to the child frame so we needed to spell out all the permissions to turn on such ass allow-scripting.

    So for now we are all set. However I need to find a good way to allow left to right scrolling in the iframe.

    Does anyone have any suggestions?

    Jeff

Thread Participants: 1