#1711 - Country Specific Banners
| Identifier | #1711 |
|---|---|
| Issue type | Feature request or suggestion |
| Title | Country Specific Banners |
| Status | Closed (rejected) |
| Handling member | Chris Graham |
| Addon | banners |
| Description | As a feature suggestion, I was thinking about allowing the possibility of banner adverts being optionally displayed only to users of a certain country (which would be selected in their profiles, or perhaps detected by a cookie for guests). I saw this idea implemented in Social Engine, and as Composr has social aspects by default I think this might be a useful option as some banner adverts which may be present in the system, which are suitable for a US member, may have no relevance to a UK member. It's not something I particularly require personally, but as there is support for multiple languages I think this would be a useful part of internationalisation. |
| Steps to reproduce | |
| Funded? | No |
The system will post a comment when this issue is modified (e.g., status changes). To be notified of this, click "Enable comment notifications".


Comments
Untested code...
{$BANNER,{$?,{$AND,{$EQ,{$GEOLOCATE},US,GB},{$GT,{$RAND},16000}},banner_{$GEOLOCATE},banner_regular}}
Code says...
If geolocates to either US or UK and 50% of the time (*), then show a banner of type banner_<countrycode>, otherwise show a banner of type banner_regular.
* A random number between 0 and 32000 is over 16000.
Anyway, this is not something I personally need as I said, but I thought as some people will be using Composr for multilingual sites, that this would tie in nicely with the internationalization aspects of Composr.
$GEOLOCATE returns 'GB', 'US', etc - the ISO country codes. I built that into the banner type names outputted by my Tempcode above.