We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

PHP, € and EE

Development and Programming

pauljessup's avatar
pauljessup
6 posts
17 years ago
pauljessup's avatar pauljessup

I’m getting strange symbols whenever I try and echo the Euro symbol (€) from PHP (in a plugin) it displays as garbage, yet it works fine in EE. Would this have something to do with the default characterset in php.ini, and if so, why doesn’t it effect EE (which I assumed, also uses PHP to render the templates…)

I wrote the plugin myself, and it just uses $r=”€” . $some_variable) and then returns it at the end of the function.

rather, here is a shortened example of what I’m doing:

function for_class() // would be EE tag exp:classname:for_class { $r=$r . ” some stuff to be displayed in the template”; $r=$r . “€” . $this->calculate_something; return $r; }

Note: this is just simplified, and showing a chunk of the actual function I’m using.

       
ExpressionEngineer's avatar
ExpressionEngineer
148 posts
17 years ago
ExpressionEngineer's avatar ExpressionEngineer

Check your character set, perhaps it’s not correctly setup?

       
pauljessup's avatar
pauljessup
6 posts
17 years ago
pauljessup's avatar pauljessup

That’s what I thought, too, but wouldn’t that effect EE as well? I’ll check and change it and see if that works.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.