Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Extended iFrames

Go to End



Community Member, 224 Posts

17 May 2008 at 3:30pm

Some of my iframes include a script...

How can I add this to the iframes module, or is there another way? Without this ability, I can't use SilverStripe - and so far I really like it. Any help?
Thank you,

<IFRAME title="Search house plans and home plans" id=myFrame frameBorder=0 width=100% height=2000></IFRAME>
function decodeQuery(query)
var params = {}; // prepare the map
if (query.length < 2) // zero characters or single '?' means no parameters
return params;
// cut '?' away:
query = query.slice(1);
var paramList=query.split('&'); // separate parameters
for(var i=0; i<paramList.length; i++) // enumerate them
var pair = paramList.split('=');
return params;

var; // get everything after question mark
var params = decodeQuery(query); // and turn into an indexable structure
var p = ( // checking if 'id' is present
? '&action=more_details&id=' + // if present, then ask for more details
: ''; // otherwise - don't.
var iframe = document.getElementById('myFrame');

iframe.src="" + p;