sruupl / batflat

Lightweight, fast and easy CMS for free. Bootstrap ready. https://batflat.org
MIT License
134 stars 54 forks source link

Can't Post US Currency In Pages / Posts -- Templates.php Tries To Process Them #44

Closed volomike closed 4 years ago

volomike commented 5 years ago

In your Templates.php file, in replaceVariable(), your Regular Expression is interpreting something like...

$9.99 $9.99/mo

...as some sort of variable like $bat.path; (and others) and is changing this to:

$9['99'] $9['99']/mo

You'll want to improve your Regular Expression to handle purely numerical conditions.

michu2k commented 5 years ago

Hey I don't know if my answer will satisfy you, but you can disable parsing e.g. {noparse} $9.99 {/noparse}