tabs are not being displayed
| Project: | Tabs-Auto |
| Version: | 5.x-2.x-dev |
| Component: | Code |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Hi, thanks for the module!
I think I have some JS-level problem with tabsauto...
On my Drupal installation, Tabsauto seems to be working, but there is a single (major) issue: instead of being displayed as tabs, items (e.g. I have headings "First" and "Second") are just displayed as UL items, with hrefs to anchors within the text. Full node text is visible, and clicking "first" or "second" only jumps within the page to the beginning of the appropriate text chunk.
After examining page source, I do see the following files being included:
<style type="text/css" media="all">@import "/sites/all/modules/tabsauto/tabsauto.css";</style>
<script type="text/javascript" src="/misc/jquery.js"></script>
<script type="text/javascript" src="/sites/all/modules/jquery_update/compat.js"></script>
<script type="text/javascript" src="/sites/all/modules/jquery_ui/jquery.ui/ui/minified/ui.core.min.js"></script>
<script type="text/javascript" src="/sites/all/modules/jquery_ui/jquery.ui/ui/minified/ui.tabs.min.js"></script>This code structure is correctly generated for the node content:
<div class="flora" id="tabsauto">
<ul><li><a href="#first">first</a></li><li><a href="#Second">Second</a></li></ul>
<div id="first"><p>Some content.</p> </div>
<div id="Second"><p>More content.</p> </div>
</div>Firebug displays a single JS error: "$ is not defined", pointing at the tabsauto-script line:
$(document).ready(function(){ $("#tabsauto > ul").tabs(); });I am not quite good with JS, so I'll appreciate any pointers/help to resolve the issue I have.
I'll keep digging (as I need this functionality urgently), and will post updates if anything comes out of my efforts.

#1
same problem here, using IE7 exact same javascript error. will look into it but don't have a lot of time to do so. if anyone else can help, please do. this module is exactly what i need for one of my projects.
#2
This is happening because the module injects some javascript into the head section of the page, before jquery is loaded. It uses drupal_set_html_head to do this. I dont' know how to make it add it's javascript later in the head section. Anyone?
#3
Ah I just reversed these two bits in my page.tpl.php
<?phpprint $head;
?>
<?phpprint $scripts;
?>
It eliminated the Javascript error, but didn't change how my tabs (don't) look...