Fixing Issue #11

This commit is contained in:
Jeremy Bush
2010-08-17 15:24:30 -04:00
committed by Justin Hileman
parent 2bd68f59b1
commit 758027bd91
4 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -469,7 +469,7 @@ class Mustache {
* @return string
*/
protected function _renderEscaped($tag_name) {
return htmlentities($this->_getVariable($tag_name), null, $this->_charset);
return htmlentities($this->_getVariable($tag_name), ENT_COMPAT, $this->_charset);
}
/**
+1
View File
@@ -2,6 +2,7 @@
class Simple extends Mustache {
public $name = "Chris";
public $last_name = '"Bob"';
public $value = 10000;
public function taxed_value() {
+1 -1
View File
@@ -1,4 +1,4 @@
Hello {{name}}
Hello {{name}} {{last_name}}
You have just won ${{value}}!
{{#in_ca}}
Well, ${{ taxed_value }}, after taxes.
+1 -1
View File
@@ -1,3 +1,3 @@
Hello Chris
Hello Chris "Bob"
You have just won $10000!
Well, $6000, after taxes.