From ca6e72138a20a68200f98f4efe713d39cc2c56af Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Tue, 10 Feb 2009 11:20:34 +0000 Subject: [PATCH] ckp --- planetlab/datepicker/URL | 2 +- planetlab/includes/plc_datepicker.php | 6 +++--- planetlab/includes/plc_details.php | 7 ++++++- planetlab/includes/plc_forms.php | 21 +++++++++++++++++++-- planetlab/includes/plc_functions.php | 6 ++++++ planetlab/minitabs/URL | 3 +++ planetlab/nodes/node.php | 2 +- planetlab/tablesort/URL | 5 ++++- planetlab/tags/tags.php | 4 ++-- 9 files changed, 45 insertions(+), 11 deletions(-) create mode 100644 planetlab/minitabs/URL diff --git a/planetlab/datepicker/URL b/planetlab/datepicker/URL index 6a63884..07944ba 100644 --- a/planetlab/datepicker/URL +++ b/planetlab/datepicker/URL @@ -1 +1 @@ -http://www.frequency-decoder.com/ +http://www.frequency-decoder.com/demo/date-picker-v4/ diff --git a/planetlab/includes/plc_datepicker.php b/planetlab/includes/plc_datepicker.php index 229793b..db1f09d 100644 --- a/planetlab/includes/plc_datepicker.php +++ b/planetlab/includes/plc_datepicker.php @@ -37,11 +37,11 @@ class PlcDatepicker { $html=""; $html .= ""; - $html .= "
form_start_html($url,$values,$method); } + function form_start ($url,$values,$method="POST") { print $this->form_start_html($url,$values,$method); return $this->form; } function form_start_html ($url,$values,$method="POST") { $this->form = new PlcForm ($url,$values,$method); return $this->form->start_html(); @@ -105,6 +105,11 @@ class PlcDetails { return $this->line_html($title,plc_vertical_table($list,"foo")); } + function line_th ($th1,$th2) { print $this->line_th_html ($th1, $th2);} + function line_th_html ($th1, $th2) { + return "$th1$th2"; + } + // 1 item, colspan=2 function single($title,$align=NULL) { print $this->single_html($title,$align);} function single_html($title,$align=NULL) { diff --git a/planetlab/includes/plc_forms.php b/planetlab/includes/plc_forms.php index 7b68f2e..9789bae 100644 --- a/planetlab/includes/plc_forms.php +++ b/planetlab/includes/plc_forms.php @@ -59,8 +59,25 @@ class PlcForm { static function label_html ($name,$display) { return ""; } - static function text_html ($name,$value,$size) { - return ""; + static function radio_html ($id, $name, $value, $checked) { + $html="20); + if ( ! $options) $options=array(); + $options = array_merge($default_options,$options); + $html="$value"; diff --git a/planetlab/includes/plc_functions.php b/planetlab/includes/plc_functions.php index 8ea281d..9a5eff5 100644 --- a/planetlab/includes/plc_functions.php +++ b/planetlab/includes/plc_functions.php @@ -306,6 +306,12 @@ function truncate ($text,$numb,$etc = "...") { } return $text; } +function html_div ($text,$class="") { + $html="$tag['tagname'],"value"=>$tag['tag_type_id']); } $selector=array_map("tag_selector",$all_tags); $table->cell($form->select_html("tag_type_id",$selector,"Choose")); - $table->cell($form->text_html("value","",8)); + $table->cell($form->text_html("value","",array('width'=>8)); $table->cell($form->submit_html("set-tag-on-node","Set Tag"),2,"left"); $table->row_end(); } diff --git a/planetlab/tablesort/URL b/planetlab/tablesort/URL index 6a63884..17669d0 100644 --- a/planetlab/tablesort/URL +++ b/planetlab/tablesort/URL @@ -1 +1,4 @@ -http://www.frequency-decoder.com/ +http://www.frequency-decoder.com/2006/09/16/unobtrusive-table-sort-script-revisited +http://www.frequency-decoder.com/2007/10/19/client-side-table-pagination-script +frequency-decoder also has a search widget but it's per-column; +so our own search/pagesize widgets was rewritten by Thierry Parmentelat (INRIA) diff --git a/planetlab/tags/tags.php b/planetlab/tags/tags.php index 58a0ace..4403f72 100644 --- a/planetlab/tags/tags.php +++ b/planetlab/tags/tags.php @@ -96,9 +96,9 @@ if (plc_is_admin()) { $selectors=array_map("selector_argument",$relevant_roles); $role_input=$form->select_html("min_role_id",$selectors,"Role"); - $table->cell($form->text_html('tagname','','')); + $table->cell($form->text_html('tagname','')); $table->cell($form->textarea_html('description','',$description_width,2)); - $table->cell($form->text_html('category','','')); + $table->cell($form->text_html('category','')); $table->cell($role_input); $table->cell($form->submit_html("add-tag-type","Add Type"),2); $table->row_end(); -- 2.43.0