javascript - change iframe content -
this looks like:
<iframe id="uploads" name="uploads" src="/uploads/sinisa/" frameborder="yes" scrolling="no" onload="settimeout(autoresize('uploads'),10)"> </iframe>
it points directory , retrieves files in list view. need remove/change line "index of /uploads/sinisa" , "parent directory". i've managed read iframe content with:
parent.document.getelementsbyname('uploads')[0].contentwindow.document.getelementsbytagname('body')[0].innerhtml
but don't know next. website talking here.
p.s. wondering how change iframe link's styling
many thanks
you value of ul
element instead of body
element, has content assume after.
parent.document.getelementsbyname('uploads')[0].contentwindow.document.getelementsbytagname('ul')[0].innerhtml
note <li>
elements not parent ul
itself, need create opening , closing <ul></ul>
elements.
Comments
Post a Comment