OS Property support center

Translate OS Map Search module

  • MartinD
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 8 months ago #67902 by MartinD
Translate OS Map Search module was created by MartinD
Hello,

I would like to translate the OS Map Search module in the OSP Real Homes template.
If I go to OS Property -> Translations, I can select 4 elements but not the OS Map Search.
However I can see the default language file in languages\en-GB\en-GB.mod_osmapsearch.ini.
Is there a way I can translate the file using the Admin back end site?


Thanks and regards
Martin

Please Log in or Create an account to join the conversation.

More
9 years 8 months ago #67903 by Mr. Dam
Replied by Mr. Dam on topic Translate OS Map Search module
Hi Martin,
To translate the Map search module, please follow these steps.
1. Open file: administrator > components > com_osproperty > classes > translation.php
2. Find
Code:
if(JFolder::exists(JPATH_ROOT.'/modules/mod_osquicksearch')){ $options[] = JHtml::_('select.option','mod_osquicksearch','Module OS Quick Search'); }

and add this code below:
Code:
if(JFolder::exists(JPATH_ROOT.'/modules/mod_osmapsearch')){ $options[] = JHtml::_('select.option','mod_osmapsearch','Module Map Search of Real Homes'); }

Good luck
Dam

Please Log in or Create an account to join the conversation.

  • MartinD
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 8 months ago #67912 by MartinD
Replied by MartinD on topic Translate OS Map Search module
Hi Dam,

That worked like a charm ! Thanks!

I found a little bug in the radius property of default.php in mod_osmapsearch

Radius = 50 but I think It should be 500.

I hard coded the zoomlevel property but maybe could be a nice to have parameter to customize the map search.

Thanks !

Martin

myShape = jQuery('#map_canvas_mapsearch').gmap('addShape', 'Circle', {
'strokeWeight': 0,
'fillColor': "#008595",
'fillOpacity': 0.25,
'center': clientPosition,
'radius': 50,
'clickable': false

Please Log in or Create an account to join the conversation.

More
9 years 8 months ago #67913 by Mr. Dam
Replied by Mr. Dam on topic Translate OS Map Search module
Hi Martin,
Sorry, the code of "Locator search" works properly. It should be 50 not 500.
Thanks
Dam

Please Log in or Create an account to join the conversation.

Moderators: Mr. DamNguyen Phu Quan