Displaying just the currency symbol or 3-letter currency code in Views
codenamerhubarb - February 5, 2009 - 04:51
| Project: | CCK Currency |
| Version: | 5.x-1.0 |
| Component: | Code |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
| Issue tags: | CCK, currency, field, symbol, views |
Jump to:
Description
Hi, This module works great, however I would love to be able to add a field into my views to only show the currency symbol. Is this possible?
At the moment the only thing you can show is the entire value, e.g. British Pound (GBP). What I would like is to show '£'.

#1
I too would love to know how to do this...
#2
It's an old issue that's been bugging me but I just revisited this today and I discovered this handy little bit of php which will trim down something like "British Pound (GBP)" to just "GBP".
<?php print substr($field_currency_select_currency, -4, 3); // where 'field_currency_select' is the name of my currency field. ?>This would go in your themed views tpl.php file. I'm not too sure on how to get the currency symbol though.