Jquery Tools UI

Component ID

1214382

Component name

Jquery Tools UI

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Component created

Component changed

Component body

A project designed to bring Jquery Tools 1.2.x to Drupal 7, providing a simple way to add the library to other modules and themes.

Theming UI Widgets

Also provides theme functions to automatically add content using the Jquery Tools tab widgets. A similar theme function has been developed for the scrollable widget.

Theming Scrollable

To automatically create markup using the scrollable interface, you could use something similar to the following snippet within your phptemplate theme file:

<?php
$scrollable_output['element_id']="portfolio_screenshots";
$scrollable_output['width']='380';
$scrollable_output['height']='360';
$scrollable_output['content']= array (
  '<img src="image1.png" />', 
  '<img src="image2.png" />', 
  '<img src="image3.png" />', 
  '<img src="image4.png" />', 
  '<img src="image5.png" />', 
  '<img src="image6.png" />');

print theme('scrollable_output', $scrollable_output);
?>

Theming Tabs

To automatically create markup using the tabs interface, you could use something similar to the following snippet within your phptemplate theme file:

<?php
$tab_output["element_id"] = "my_tabs",
$tab_output["title"] = array( 
    "First Title", 
    "Second Title" ),
$tab_output["content"] = array ( 
    $node->body['und'][0]['value'], 
    "<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec nisl elit, hendrerit sed dapibus ut, imperdiet vel sapien. Etiam augue nulla, semper vel ullamcorper nec, blandit ut odio. Fusce ut congue elit. Curabitur placerat enim at arcu dictum sagittis. Sed volutpat vestibulum ante quis mattis. In vehicula porttitor lobortis. Suspendisse potenti. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nunc molestie, sem vel facilisis lobortis, nisi nisl sagittis libero, porttitor dapibus enim mauris in neque. Proin et felis eros, nec varius nunc.</p>" );

print theme('tab_output',$tab_output); 
?>

All Jquery code and libraries are added automatically. Default CSS is applied to the resulting markup, which can obviously be overridden as necessary.