From d78c207f76c8ae57744300611519f4c85c2c34c4 Mon Sep 17 00:00:00 2001 From: Paul 'flowerysong' Arthur Date: Sun, 14 Mar 2010 06:10:27 +0000 Subject: Cosmetics: use tabs for indentation, tweak some indentation/coding style. --- lib/class/ajax.class.php | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'lib/class/ajax.class.php') diff --git a/lib/class/ajax.class.php b/lib/class/ajax.class.php index 254bc6bf..5381f529 100644 --- a/lib/class/ajax.class.php +++ b/lib/class/ajax.class.php @@ -45,23 +45,23 @@ class Ajax { */ public static function observe($source,$method,$action,$post='') { - $non_quoted = array('document','window'); + $non_quoted = array('document','window'); - if (in_array($source,$non_quoted)) { - $source_txt = $source; - } - else { - $source_txt = "'$source'"; - } + if (in_array($source,$non_quoted)) { + $source_txt = $source; + } + else { + $source_txt = "'$source'"; + } // If it's a post then we need to stop events if ($post) { $action = 'Event.stop(e); ' . $action; } - $observe = ""; + $observe = ""; return $observe; @@ -76,15 +76,15 @@ class Ajax { $url = Config::get('ajax_url') . $action; - $non_quoted = array('document','window'); + $non_quoted = array('document','window'); + + if (in_array($source,$non_quoted)) { + $source_txt = $source; + } + else { + $source_txt = "'$source'"; + } - if (in_array($source,$non_quoted)) { - $source_txt = $source; - } - else { - $source_txt = "'$source'"; - } - if ($post) { $ajax_string = "ajaxPost('$url','$post',$source_txt)"; } @@ -106,7 +106,7 @@ class Ajax { // Get the correct action $ajax_string = self::action($action,$source,$post); - // If they passed a span class + // If they passed a span class if ($class) { $class_txt = ' class="' . $class . '"'; } @@ -114,7 +114,7 @@ class Ajax { $string = get_user_icon($icon,$alt); - // Generate a so that it's more compliant with older browsers + // Generate a so that it's more compliant with older browsers // (ie :hover actions) and also to unify linkbuttons (w/o ajax) display $string = "".$string."\n"; @@ -140,7 +140,7 @@ class Ajax { } // If we pass a source put it in the ID - $string = "$text\n"; + $string = "$text\n"; $string .= self::observe($source,'click',$ajax_string); -- cgit