List Info

Thread: Debugging behaviour.js




Debugging behaviour.js
country flaguser name
United States
2007-05-22 11:09:41
I am developing a google map app that's attempting to use
behaviour to
recenter the map. The webpage is at
home.csumb.edu/g/greenemichael/
world/broken.htm . On the right side of the page, I've got a
list of
bulidings on campus. The idea is a click on a building in
the list
will recenter the map on that building. I use behaviour to
fire off a
function that invokes the redrawing code.

The code works fine in firefox but fails in Explorer, Safari
and
Opera. Explorer throws an error on the behaviour.apply call.
If I
remove the behaviour call, Of course I don't get the desired
results
other than getting Explorer to shut up.

I've looked at the code and I'm damned if I can see anything
wrong.
Perhaps another pair of eyes might see something obvious
that I
missed? The javascript code is in

home.csumb.edu/g/greenemichael/world/jsc/behaviour.js (the
current
distribution)
home.csumb.edu/g/greenemichael/world/jsc/style.js ( my mod
to the
rules structure)

The div that I'm hanging the function call off of is defined
by
 <style type="text/css">
   #sma{position: absolute;left:50px}
</style> and lives in the larger div, BldgList. Both
are defined at
the bottom of the webpage.


 The div works properly in Firefox and safari by formating
the
building # and building name into two adjacent columns but
fails in
Explorer.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Behaviour Javascript Library"
group.
To post to this group, send email to behaviourgooglegroups.com
To unsubscribe from this group, send email to
behaviour-unsubscribegooglegroups.com
For more options, visit this group at http:/
/groups.google.com/group/behaviour?hl=en
-~----------~----~----~----~------~----~------~--~---


Re: Debugging behaviour.js
country flaguser name
United States
2007-05-22 14:20:57
I found the error - style.js needs to be pruned from the
example code
to provide rules only for those elements that actually exist
in the
DOM. I had modified myrules to fire my code but left the
other rules
intact. Firefox didn't mind but Explorer and Opera do.

On May 22, 9:09 am, michael_greene <michael_gre...csumb.edu> wrote:
> I am developing a google map app that's attempting to
use behaviour to
> recenter the map. The webpage is at
home.csumb.edu/g/greenemichael/
> world/broken.htm . On the right side of the page, I've
got a list of
> bulidings on campus. The idea is a click on a building
in the list
> will recenter the map on that building. I use behaviour
to fire off a
> function that invokes the redrawing code.
>
> The code works fine in firefox but fails in Explorer,
Safari and
> Opera. Explorer throws an error on the behaviour.apply
call. If I
> remove the behaviour call, Of course I don't get the
desired results
> other than getting Explorer to shut up.
>
> I've looked at the code and I'm damned if I can see
anything wrong.
> Perhaps another pair of eyes might see something
obvious that I
> missed? The javascript code is in
>
> home.csumb.edu/g/greenemichael/world/jsc/behaviour.js
(the current
> distribution)
> home.csumb.edu/g/greenemichael/world/jsc/style.js ( my
mod to the
> rules structure)
>
> The div that I'm hanging the function call off of is
defined by
>  <style type="text/css">
>    #sma{position: absolute;left:50px}
> </style> and lives in the larger div, BldgList.
Both are defined at
> the bottom of the webpage.
>
>  The div works properly in Firefox and safari by
formating the
> building # and building name into two adjacent columns
but fails in
> Explorer.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Behaviour Javascript Library"
group.
To post to this group, send email to behaviourgooglegroups.com
To unsubscribe from this group, send email to
behaviour-unsubscribegooglegroups.com
For more options, visit this group at http:/
/groups.google.com/group/behaviour?hl=en
-~----------~----~----~----~------~----~------~--~---


[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )