[Product-Developers] Javascript in plone 3.1

Espen Moe-Nilssen espen at medialog.no
Fri Oct 10 14:21:42 UTC 2008


For example, I made a product out of:

http://plone.org/documentation/tutorial/create-a-2d-image-sorter- 
based-on-folder_contents-sorting-functionality

.... now I know there is an javascript error console:

I get

node.parentNode is unidefined

on
________________________________

dndSlideSorter.getPos = function(node) {
     var children = node.parentNode.childNodes;
     var pos = 0;
     for (var i=0; i<children.length; i++) {
         if (node == children[i])
             return pos;
         if (hasClassName(children[i], "sortable-cell"))
             pos++;
     }
     return null;
}
______________________________________

Will try to figure it out.....



Den 10. okt. 2008 kl. 12.06 skrev Martijn Pieters:

> On Fri, Oct 10, 2008 at 09:40, Espen Moe-Nilssen  
> <espen at medialog.no> wrote:
>> Is there a change in how javascript must be loaded from a template  
>> from
>> plone 3.0 to 3.1.5 (for example, has the slot name it must be  
>> loaded in
>> changed) ?
>> (some of my products has stopped working after upgrading).
>
> Nothing has changed in loading them, but in 3.1 jquery has been
> included and most Plone javascript has been rewritten to make use of
> this library. We tried to retain backwards compatibility, but it may
> be that something broke somewhere anyway.
>
> What products have stopped working? Have you looked at the browser's
> javascript error console?
>
> -- 
> Martijn Pieters

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.plone.org/pipermail/plone-product-developers/attachments/20081010/a7f8fb4b/attachment-0001.html>


More information about the Product-Developers mailing list