Support Offline : Mon - Fri / 10am - 6pm (GMT +6)

Your Time: Our Time:

SP Booking translation

Featured Lock Resolved Bug
Hi there,
i don't can translate your static placeholder in files like "modules/mod_spbooking_search/tmpl/default.php". Other modules got the same problems. Can you send me a snipped for fix it?

Code:
<div class="toggle-person-info"><?php echo $rooms . ' ' . SpbookingHelper::pluralize($rooms, 'Room', 'Rooms') . ', ' . $adult . ' ' . SpbookingHelper::pluralize($adult, 'Adult', 'Adults') . ', ' . $child . ' ' . SpbookingHelper::pluralize($child, 'child', 'children'); ?></div>

Code:
<button class="btn btn-danger btn-xs btn-minus" ><span class="fa fa-minus"></span></button>
<span class="value value-holder is-room" data-min="1" data-val='<?php echo $rooms; ?>' data-singular="Room" data-plural="Rooms" data-info="<?php echo $rooms . ' ' . SpbookingHelper::pluralize($rooms, 'Room', 'Rooms'); ?>"><?php echo $rooms; ?></span>

Code:
<span class="value value-holder is-adult" data-min="1" data-val='<?php echo $adult; ?>' data-singular="Adult" data-plural="Adults" data-info="<?php echo $adult . ' ' . SpbookingHelper::pluralize($adult, 'Adult', 'Adults'); ?>">

Code:
<span class="value value-holder is-child" data-min="0" data-val='<?php echo $child; ?>' data-singular="Child" data-plural="Children" data-info="<?php echo $child . ' ' . SpbookingHelper::pluralize($child, 'Child', 'Children'); ?>">

thx for feedback.
Regards

6 Answers

Paul Frankowski - Staff

More than a month ago #Permalink
Hi,
sorry & thanks, noticed added to bug/wishlist.

Temporary you can create your own language tags

Michael von Kannen

More than a month ago #Permalink
Hi,
sorry & thanks, noticed added to bug/wishlist.

Temporary you can create your own language tags


Hi,
thx but how can i insert my own language tags? Can you give me an example for my bold marked words please?

<div class="toggle-person-info"><?php echo $rooms . ' ' . SpbookingHelper::pluralize($rooms, 'Zimmer','Zimmer') . ', ' . $adult . ' ' . SpbookingHelper::pluralize($adult, 'Erwachsener', 'Erwachsene') . ', ' . $child . ' ' . SpbookingHelper::pluralize($child, 'Kind', 'Kinder'); ?></div>


<span class="value value-holder is-room" data-min="1" data-val='<?php echo $rooms; ?>' data-singular='<?php echo JText::_('MOD_SPBOOKING_SEARCH_ROOM'); ?>' data-plural='<?php echo JText::_('MOD_SPBOOKING_SEARCH_ROOMS'); ?>' data-info="<?php echo $rooms . ' ' . SpbookingHelper::pluralize($rooms, 'Zimmer', 'Zimmer'); ?>"><?php echo $rooms; ?></span>

Rob

More than a month ago #Permalink
Don't break the code
Joomla offers a fine language tool
See extensions menu/languages/overrides from your administrator menu
Create a new override. For example:
Language constant: MOD_SPBOOKING_SEARCH_ROOMS
Text: Room searching
Hit save and repeat this for all the words you want in your own language.

If the language settings in Joomla have been set properly than Joomla will show the override text.
In some cases the cache first need to been deleded to show the new text.

The benefit is that your language is saved as an override so updating Joomla or other parts, will not do harm to your override, and Joomla keeps functioning when you wish to create a bilingual website.

Michael von Kannen

More than a month ago #Permalink
Hi Rob, i know what's language overrides are but sorry, i think you don't understand the problem. There are no language tags in your source code.

<div class="toggle-person-info"><?php echo $rooms . ' ' . SpbookingHelper::pluralize($rooms, 'Room', 'Rooms') . ', ' . $adult . ' ' . SpbookingHelper::pluralize($adult, 'Adult', 'Adults') . ', ' . $child . ' ' . SpbookingHelper::pluralize($child, 'child', 'children'); ?></div>

If you would like to use language overrides in your scripts, you need first add language tags like "MOD_SPBOOKING_SEARCH_ROOMS" or stuff like that? Do you know what i mean? It's not a script for multilanguage website.

If you have a solution let me know.

Thanks

Paul Frankowski - Staff

More than a month ago #Permalink
Nope, I don't have. Really sorry.

Michael von Kannen

More than a month ago #Permalink
ok.

1. move to directory "modules/mod_spbooking_search/tmpl"
2. open "default.php"
3. scroll to line "66"
4. search for " $child, 'child', 'children' "

you'll see, that there is no dynamic language tag like "MOD_SPBOOKING_SEARCH_CHILD" or "MOD_SPBOOKING_SEARCH_CHILDREN"

Same problem on line 75, line 86 or 97 ....


There are no replies made for this post yet.
Be one of the first to reply to this post!

Leaderboard (30 days)

Paul Frankowski

Paul Frankowski

Total Accepted Answers: 116
Toufiq

Toufiq

Total Accepted Answers: 72
Mehtaz Afsana Borsha

Mehtaz Afsana Borsha

Total Accepted Answers: 25
Ofi Khan

Ofi Khan

Total Accepted Answers: 14
Rashida Rahman

Rashida Rahman

Total Accepted Answers: 9

120

Templates

310857

Community Users

Newsletter

Don’t miss any updates of our new templates and extensions and all the astonishing offers we bring for you.
We never spam

Joomla! ® name is used under a limited license from Open Source Matters in the United States and other countries. JoomShaper.com is not affiliated with or endorsed by Open Source Matters or the Joomla! Project.

Connect Us