Hmmm! Actually it seems to be working locally as well. I must be confused about what to expect with the objects returned by $ with IE8. When I am looking at them in the IE8 debugger, I do not see the methods from the prototype Element. However, if I call the method, it finds it. I was really expecting to see the methods listed.
On Sep 28, 9:30 am, "T.J. Crowder" <[email protected]> wrote: > Hi, > > > <script type="text/javascript" src="D:/prototype.js"></script> > > That's likely to be your problem right there. Loading things from file:/// > URLs is usually a problem. I assume you must be testing your page from > a file:/// URL; otherwise, that script tag will fail to load Prototype > at all. > > There's no problem if I use your code with http:// URLs, loading > Prototype from the Google CDN:http://jsbin.com/itovi4 > > As you can see, the returned result is extended (it has Prototype's > `observe` function on it). > > HTH, > -- > T.J. Crowder > Independent Software Engineer > tj / crowder software / com > www / crowder software / com > > On Sep 28, 2:56 pm, Trysta <[email protected]> wrote: > > > > >http://www.pastie.org/1186520 > > > You just need to substitute your location for prototype.js > > > On Sep 28, 4:11 am, "T.J. Crowder" <[email protected]> wrote: > > > > Hi, > > > > Can you put together a minimalist, self-contained example and post it > > > to pastie.org or jsbin.com or jsfiddle.net or somewhere? Just the > > > minimum needed to show the problem. > > > -- > > > T.J. Crowder > > > Independent Software Engineer > > > tj / crowder software / com > > > www / crowder software / com > > > > On Sep 28, 4:03 am, Trysta <[email protected]> wrote: > > > > > I am having trouble with using prototype on DOM elements in IE8. For > > > > example I try to do $(myButton) where myButton is a > > > > DispHTMLButtonElement. I have stepped through the extend function in > > > > the debugger and it goes through the following code: > > > > > if (Prototype.BrowserFeatures.SpecificElementExtensions) { > > > > if (HTMLOBJECTELEMENT_PROTOTYPE_BUGGY) { > > > > return function(element) { > > > > if (element && typeof element._extendedByPrototype == > > > > 'undefined') { > > > > var t = element.tagName; > > > > if (t && (/^(?:object|applet|embed)$/i.test(t))) { > > > > extendElementWith(element, Element.Methods); > > > > extendElementWith(element, Element.Methods.Simulated); > > > > extendElementWith(element, > > > > Element.Methods.ByTag[t.toUpperCase()]); > > > > } > > > > } > > > > return element; > > > > } > > > > } > > > > > It gets a false with (/^(?:object|applet|embed)$/i.test(t))) which is > > > > a line of code I can't decipher. It then simply returns the element > > > > instead of extending it. > > > > > I am in IE8 mode using <meta http-equiv="X-UA-Compatible" > > > > content="IE=8" /> > > > > > Does anyone know what I am doing wrong with this?- Hide quoted text - > > > > - Show quoted text -- Hide quoted text - > > - Show quoted text - -- You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en.
