function _l10n_client_dom_strings in Localization client 6
Same name and namespace in other branches
- 5 l10n_client.module \_l10n_client_dom_strings()
- 6.2 l10n_client.module \_l10n_client_dom_strings()
- 7 l10n_client.module \_l10n_client_dom_strings()
Helper function for the string list DOM tree
1 call to _l10n_client_dom_strings()
- l10n_client_footer in ./
l10n_client.module - Implementation of hook_footer().
File
- ./
l10n_client.module, line 316 - Localization client. Provides on-page translation editing.
Code
function _l10n_client_dom_strings($strings) {
$output = '';
foreach ($strings as $values) {
$source = $values[0] === TRUE ? '' : htmlspecialchars($values[0], ENT_NOQUOTES, 'UTF-8');
$target = $values[1] === TRUE ? '' : htmlspecialchars($values[1], ENT_NOQUOTES, 'UTF-8');
$textgroup = $values[2];
$output .= "<div><span class='source'>{$source}</span><span class='target'>{$target}</span><span class='textgroup'>{$textgroup}</span></div>";
}
return "<div id='l10n-client-data'>{$output}</div>";
}