diff options
Diffstat (limited to 'framework/Web/Javascripts')
-rw-r--r-- | framework/Web/Javascripts/TJavaScript.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/framework/Web/Javascripts/TJavaScript.php b/framework/Web/Javascripts/TJavaScript.php index 4a788b95..4066565b 100644 --- a/framework/Web/Javascripts/TJavaScript.php +++ b/framework/Web/Javascripts/TJavaScript.php @@ -125,14 +125,15 @@ class TJavaScript if($toMap)
{
foreach($value as $k=>$v)
- if(is_string($v) && strlen($v) > 0)
+ if($v!=='')
$results[]="'{$k}':".self::encode($v,$toMap);
return '{'.implode(',',$results).'}';
}
else
{
foreach($value as $k=>$v)
- $results[]=self::encode($v,$toMap);
+ if($v!=='')
+ $results[]=self::encode($v,$toMap);
return '['.implode(',',$results).']';
}
}
|