Forum Moderators: open

Message Too Old, No Replies

Issue with IE6 and the object tag

         

dstanley

11:06 am on Jul 13, 2005 (gmt 0)

10+ Year Member



I am experiencing a problem using the <object> tag intigrating an asp page into a html page.

It displays fine in mozilla but internet explorer only displays an empty frame.

Similar as described here: [webmasterworld.com...]


I'm having an issue that I've done a lot of searching to find an answer for and simply haven’t had any luck, so I’m praying that someone here can help me.

I have a web based app that I wrote that uses an inline scrollable area to display a bunch of information from a remote document. Originally I used an iframe to do this and it worked great. Then, my users were on ie 5.5 The app is written for ie, so I don’t care about cross browser support in this situation and it’s not indexed to SE issues don’t matter. Anyway, after upgrading my network to XP and ie 6, I have an issue where the contents of the inline frame disappear or become dead (unclickable). If you scroll the section , then scroll back, the part of the document that went out of view disappears. Now, oddly enough, if you resize the ie window or minimize and maximize it, the iframe works again. Thinking this might be an issue specifically with iframe, I tried using <object> to display the inline content. The result is the exact same behavior. Please note that with either method, this odd behavior doesn’t happen all the time, but about every 4th or 5th time. Anyone have any idea what this could be? It’s really making it a pain for my users and I’ve exhausted myself ripping my hair out. Thanks a lot. :)

encyclo

3:50 pm on Jul 13, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld [webmasterworld.com] dstanley!

Using

object
can be a problematic in IE - an
iframe
is almost always better. What markup are you using to insert your ASP page?

dstanley

4:30 pm on Jul 13, 2005 (gmt 0)

10+ Year Member



Hi

Thanks for your reply. I've tried various combinations of code.

<object data="http://ticker.asp" type="text/asp" height="100" width="170"> 
<param name="ticker" value="http://ticker.asp" />
</object>

and

<object data="http://ticker.asp" type="text/html" height="100" width="170"> 
<param name="ticker" value="http://ticker.asp" />
</object>

and

<object data="http://ticker.asp" type="text/html" height="100" width="170"> </object> 

All of which work in mozilla fine. I'm building an xhtml 1.1 valid site.

encyclo

5:08 pm on Jul 13, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The biggest problem (of many) with
object
in IE is that it is actually always treated as an Active-X object, even when in fact you're not using Active-X at all. This can often explain why an object doesn't appear - it is because the default security settings in IE block a lot of Active-X, for example from a local source or if unsigned (and you can't sign it because it's not actually Active-X!)

Secondly it is given a border, scrollbars and padding which cannot be removed using the

border
or
padding
attributes despite what you'd think.

There is only one realistic possibility at the moment, and that is to use

iframe
instead:

<iframe src="http://ticker.asp" height="100" width="170" frameborder="0" scrolling="no"> </iframe>

Using

iframe
will not validate as XHTML 1.0 Strict, so you are forced to use Transitional.

cuce

8:15 pm on Jul 13, 2005 (gmt 0)

10+ Year Member



I don't know exactly what you are doing but you *might be able to solve the problem by embedding all of this into a chunk of flash and mark it up like this...
<object data="#*$!/xxx/xxx.swf" type="application/x-shockwave-flash" width="400" height="81">
<param name="movie" value="xxx/xxx/xxx.swf" />
<div id="noflash">
<p><a href="http://www.macromedia.com">download flash</a></p>

</div>
</object>

that way your code will validate..but it kind of feels like cheating to me. lousy ie.

dstanley

9:40 pm on Jul 13, 2005 (gmt 0)

10+ Year Member



Are there issues with iframe and other browsers or do they all support it?

Or maybe theres a way to do <object> (for all browsers that IE) using <iframe> with the <!--[ifIE]