unfortunately its an intranet application and i can not post an
example..
i tested if the function exists by using:
alert(document.viewport.getScrollOffsets);
and the function would be alerted as seen in prototype.js and more
confusing is that the getDimensions() method would be called without
any error just a line before getScrollOffsets().
prototype is the first js file that is been loaded:
<script type="text/javascript" src="/scripts/prototype.js"></script>
<script type="text/javascript" src="/scripts/global.js"></script>
<script type="text/javascript" src="/scripts/subwindow.js"></script>
<script type="text/javascript" src="/scripts/actions.js"></script>
and the problem lines are located in subwindow.js
Regards
Daniel
On 16 Jun., 09:58, "T.J. Crowder" <[EMAIL PROTECTED]> wrote:
> > But why does the viewport function not work?
>
> Usually this is because you're trying to use it before Prototype is
> loaded or before the DOM is ready. Can you post a trimmed-down
> example demonstrating the problem?
> --
> T.J. Crowder
> tj / crowder software / com
>
> On Jun 16, 8:49 am, "[EMAIL PROTECTED]"
>
> <[EMAIL PROTECTED]> wrote:
> > thanks for quick response, after extending the element everything
> > works.
>
> > But why does the viewport function not work?
>
> > On 13 Jun., 19:05, kangax <[EMAIL PROTECTED]> wrote:
>
> > > Besides what Fred said, #getElementsBySelector has been deprecated -
> > > use #select instead.
>
> > > $(element).up(1).select('li.menu').invoke('removeClassName',
> > > 'active');
>
> > > - kangax
>
> > > On Jun 13, 10:46 am, "[EMAIL PROTECTED]"
>
> > > <[EMAIL PROTECTED]> wrote:
> > > > i'm currently developing a web application with the goal, that
> > > > everything should work in as many browsers as possible. im using
> > > > prototype and the first barrier is IE (as expected). The problem ist
> > > > the following:
>
> > > > ...
> > > > scroll = document.viewport.getScrollOffsets();
> > > > ...
> > > > throws: "Object does not support this method"
>
> > > > another problem is that:
> > > > ...
> > > > e.up(1).getElementsBySelector('li.menu').each(function(i)
> > > > {i.removeClassName('active');});
> > > > ...
>
> > > > doesn't work, but:
>
> > > > Element.up(e, 1).getElementsBySelector('li.menu').each(function(i)
> > > > {i.removeClassName('active');});
>
> > > > works fine...
>
> > > > As usual everthing works fine in firefox and other "better" browsers.
>
> > > > Can anybody give me a hint?
>
> > > > Regards
> > > > Daniel
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" 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/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---