From c089f94fa8b7753a3f4f186ae372db1cd0d28af9 Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Sun, 15 Feb 2009 15:29:43 +0000 Subject: [PATCH] several instances supported (no globals) --- planetlab/includes/plc_minitabs.php | 27 ++- planetlab/minitabs/minitabs.css | 10 +- planetlab/minitabs/minitabs.js | 346 +++++++++++++++------------- 3 files changed, 203 insertions(+), 180 deletions(-) diff --git a/planetlab/includes/plc_minitabs.php b/planetlab/includes/plc_minitabs.php index e681477..db8301d 100644 --- a/planetlab/includes/plc_minitabs.php +++ b/planetlab/includes/plc_minitabs.php @@ -2,6 +2,7 @@ // $Id$ drupal_set_html_head(' + '); @@ -25,9 +26,10 @@ drupal_set_html_head(' // (*) 'id' : assign given id to the
  • element // NOTE -// values can also be set in the URL, e.g. ?var=value&foo=bar, even for POST'ing +// (*) values can also be set in the URL, e.g. ?var=value&foo=bar, even for POST'ing +// (*) several instances can appear on the same page but you need to give them different id's -// examples +// EXAMPLES // function my_tab () { return array('label'=>'Go to google','url'=>'http://google.com'); } // $tabs=array(); // $tabs[] = my_tab(); @@ -41,10 +43,10 @@ drupal_set_html_head(' // (the form gets submitted whatever the confirmation....) // (*) you need to tune the image size, which is wrong, as the image should rather be bottom-aligned -function plc_tabs ($array) { - print '
    '; - print '