Browse Source

Fixing typos

Julio Montoya 14 years ago
parent
commit
f06519579a
2 changed files with 10 additions and 10 deletions
  1. 6 6
      main/inc/lib/display.lib.php
  2. 4 4
      main/inc/lib/sortabletable.class.php

+ 6 - 6
main/inc/lib/display.lib.php

@@ -237,12 +237,12 @@ class Display {
 	 * 					'hide_navigation' =  true to hide the navigation
 	 * @param array $query_vars Additional variables to add in the query-string
 	 * @param array $form actions Additional variables to add in the query-string
-	 * @param mixed An array with bool values to know which columns show. i.e: $vibility_options= array(true, false) we will only show the first column
+	 * @param mixed An array with bool values to know which columns show. i.e: $visibility_options= array(true, false) we will only show the first column
 	 * 				Can be also only a bool value. TRUE: show all columns, FALSE: show nothing
 	 */
 
-	public static function display_sortable_grid($name, $header, $content, $paging_options = array(), $query_vars = null, $form_actions = array(), $vibility_options = true, $sort_data = true) {
-	    echo self::return_sortable_grid($name, $header, $content, $paging_options, $query_vars, $form_actions, $vibility_options, $sort_data);		
+	public static function display_sortable_grid($name, $header, $content, $paging_options = array(), $query_vars = null, $form_actions = array(), $visibility_options = true, $sort_data = true) {
+	    echo self::return_sortable_grid($name, $header, $content, $paging_options, $query_vars, $form_actions, $visibility_options, $sort_data);		
 	}	
 
 	/**
@@ -258,12 +258,12 @@ class Display {
 	 * 					'hide_navigation' =  true to hide the navigation
 	 * @param array $query_vars Additional variables to add in the query-string
 	 * @param array $form actions Additional variables to add in the query-string
-	 * @param mixed An array with bool values to know which columns show. i.e: $vibility_options= array(true, false) we will only show the first column
+	 * @param mixed An array with bool values to know which columns show. i.e: $visibility_options= array(true, false) we will only show the first column
 	 * 				Can be also only a bool value. TRUE: show all columns, FALSE: show nothing
 	 * @param bool  true for sorting data or false otherwise
 	 * @return 	string   html grid
 	 */
-	public static function return_sortable_grid($name, $header, $content, $paging_options = array(), $query_vars = null, $form_actions = array(), $vibility_options = true, $sort_data = true) {
+	public static function return_sortable_grid($name, $header, $content, $paging_options = array(), $query_vars = null, $form_actions = array(), $visibility_options = true, $sort_data = true) {
 		if (!class_exists('SortableTable')) {
 			require_once 'sortabletable.class.php';
 		}
@@ -275,7 +275,7 @@ class Display {
 		if (is_array($query_vars)) {
 			$table->set_additional_parameters($query_vars);
 		}
-		return $table->display_simple_grid($vibility_options, $paging_options['hide_navigation'], $paging_options['per_page'], $sort_data);
+		return $table->display_simple_grid($visibility_options, $paging_options['hide_navigation'], $paging_options['per_page'], $sort_data);
 	}
 
 	/**

+ 4 - 4
main/inc/lib/sortabletable.class.php

@@ -411,7 +411,7 @@ class SortableTable extends HTML_Table {
 	 * @param bool	 	sort data optionally
 	 * @return string	grid html
 	 */
-	public function display_simple_grid($vibility_options, $hide_navigation = true, $per_page = 0, $sort_data = true) {
+	public function display_simple_grid($visibility_options, $hide_navigation = true, $per_page = 0, $sort_data = true) {
 
 		$empty_table = false;
 		if ($this->get_total_number_of_items() == 0) {
@@ -470,10 +470,10 @@ class SortableTable extends HTML_Table {
 		// i.e: .whoisonline_table_grid_container instead of  .grid_container
 		// where whoisonline is the table's name like drupal's template engine
 
-		if (is_array($vibility_options)) {
+		if (is_array($visibility_options)) {
 			$filter = false; // The 2nd condition of the if will be loaded
 		} else {
-			$filter = $vibility_options !== false;
+			$filter = $visibility_options !== false;
 		}
 
 		$html .= '<div class="'.$this->table_name.'_grid_container">';
@@ -482,7 +482,7 @@ class SortableTable extends HTML_Table {
 				$html .= '<div class="'.$this->table_name.'_grid_item">';
 				$i = 0;
 				foreach ($row as & $element) {
-					if ($filter || $vibility_options[$i]) {
+					if ($filter || $visibility_options[$i]) {
 						$html.='<div class="'.$this->table_name.'_grid_element_'.$i.'">'.$element.'</div>';
 					}
 					$i++;