It isn't working.
I'm getting this error:
TypeError: 'null' is not an object (evaluating '$('#slidebox_trigger').offset().top')
line 14 slidebox.js
tried both the 1.x version and 2.x version, same error
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | slidebox-jquery_offset-1619956-8.patch | 1.59 KB | Anonymous (not verified) |
| #6 | slidebox-jquery_offset-1619956-6.patch | 585 bytes | Anonymous (not verified) |
Comments
Comment #1
Enes commentedSlidebox panels work well. Panels using the Node template. Why is this?
Comment #2
tchopshop commentedI don't understand your question. Does this have something to do with Panels?
Comment #3
Anonymous (not verified) commentedSorry for the delay in response - for some strange reason the block in the dashboard didn't show a new open issue. :/
So far, I have not been able to reproduce this issue myself. Can you please provide more details, such as the specific browser and version of that browser that you are using?
Comment #4
julien.reulos commentedI can't understand what is happening on my website. Some nodes are showing the slidebox, some others are not... Worst, I have 2 identical nodes from the same content type, and the first one is showing the slidebox, the other one not.
Debug with Firebug for Chrome:
Uncaught TypeError: Cannot read property 'top' of null slidebox.js:14And with Firebug for Firefox:
Same with 7.x-2.x or 7.x-1.5.
Comment #5
Anonymous (not verified) commentedOkay, so that means that for some reason .offset() is returning null in some cases. I'll have to look into it more as I haven't run into that issue.
I've got a couple of hard deadlines I'm trying to meet on some projects and a sister's wedding coming up, so I'm not exactly sure at the moment when I'll be able to spend some real time on this issue, but it's likely that it won't be until after the first of July.
Patches are welcome, by the way. :)
Comment #6
Anonymous (not verified) commentedI'm still not sure what's causing the issue, as I can't reproduce it. I've even stepped through it with Firebug and Chrome Developer Tools to see what was actually going on during the loading, and I couldn't find a time where it would return null. However, this is with a clean install of Drupal.
I can try and offer this patch that wraps the heights in parseInt and let you see if that happens to fix it, but I'm really not sure at all about what is going on here.
Comment #7
tchopshop commentedI applied the patch to 1.x version... it still gives me the same error. Do you want a URL to see? Go to http://myspiltmilk.com/eastern-sea-thinks-big (for example).
Comment #8
Anonymous (not verified) commentedOkay. I think I see what's happening there. I'm still loading the Javascript even if the content type is disabled in Slidebox's configuration. So while the HTML for the slidebox is not being loaded on those pages whose content type is not enabled for Slidebox, the Javascript still is and is basically saying "hey, I can't find this div you told me about".
Here's a patch to try and let me know if it works in your case. It should no longer be trying to load the JS or CSS on any node where the node type is not selected in Slidebox configuration settings.
Comment #9
tchopshop commentedBrian, thanks, but the content type is enabled in the slide box configuration -- it has always been. I've set it to using the article content type in the example above. So even though I added the patch in #8, I'm still getting the error (in Safari's Web Developer tools).
Elena
Comment #10
Anonymous (not verified) commentedIt looks like you're using Display Suite based on some of the classes on wrappers, am I correct? I have not tested this with DS.
I understood when taking over this module that it didn't work with Panels at the time, and I'm sure that's probably the same reason it doesn't seem to work with DS and is something that I plan to address with #1372260: Let's make this more of an API.
Comment #11
tchopshop commentedAhhh... that makes sense! I'll follow that issue then...
Comment #12
julien.reulos commentedBrian, that's correct, I disabled Display Suite and Slidebox suddenly works ! Sorry I didn't see it myself before...
Comment #13
Anonymous (not verified) commentedNot a problem. Another issue was identified and fixed during the process, so its a net positive.