views:

266

answers:

1

Is there a way to add an iframe to a facebook page without having to do the onClick functionality?

Right now I am using this code and it works fine except you have to click the link to make it show the iframe?

<!-- Start iframe CODE -->
        Like me to show the iFrame link!

        <fb:visible-to-connection>
            <a onClick="outside_location.setInnerFBML(link_1);" style="cursor: pointer;">Click here to show the iFrame!</a>
        </fb:visible-to-connection> 
        <div id="outside_location"></div>
        <fb:js-string var="link_1">
        <fb:iframe height="500" allowTransparency="true" frameborder="0" scrolling="no" style="width:100%; height: 1400px; border:none"     src="http://apps.ignitesocialmedia.com/php/facebook/sandbox/tabs/iframe.php"&gt;&lt;/fb:iframe&gt;
        </fb:js-string>
        <script type="text/javascript" charset="utf-8">
        var outside_location = document.getElementById('outside_location');
        </script>

        <!-- End iframe CODE -->

It seems as though this has been done in a couple places but I cannot figure it out.

related questions