Important: This page is using cookies (cookies). Using this website without turning off cookies in browser, means that you agree for using it.
Buy Now! Features Downloads

Earn with us!

If you would like to start earning money with vBET join to Affiliate Program.
Page 3 of 3 FirstFirst 123
Results 21 to 24 of 24

Thread: vBET 4.2.1 does not translate vBSEO Javascript messages

  1. #21
    vBulletin Enterprise Translator (vBET) Staff
    Join Date
    May 2010
    Posts
    1,000

    Default

    I will check it

  2. #22

    Default

    any news ?

  3. #23
    vBulletin Enterprise Translator (vBET) Staff
    Join Date
    May 2010
    Posts
    1,000

    Default

    you are right - this is not included in this version - I need to find why.

  4. #24
    MichaƂ Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Indeed the bug came back, but we found solution - it will be included in next release.

    For quicke fix please:
    1. Open file /includes/vbenterprisetranslator_functions
    2. Find function vbet_addScriptToTable:
    Code:
    function vbet_addScriptToTable($what) {
    global $vbulletin;
    if ($vbulletin->options['vbenterprisetranslator_vbseo_message'] && strpos($what[1], 'vbseo_jshtml[0]')) {
    $scriptIndex = 0;
    $position = 0;
    $prevPosition = 0;
    $scriptBuffer = '';
    $script = $what[1];
    $forumLanguage = $vbulletin->options['vbenterprisetranslator_forumlanguage'];
    global $vbet_serie;
    while (true) {
    $position = strpos($script, 'vbseo_jshtml['.$scriptIndex.']', $prevPosition);
    if (!$position) {
    break;
    }
    $position = strpos($script, '<table', $position);
    $end = strpos($script, '</table>', $position);
    $toTranslate = substr($script, $position, $end + strlen('</table>') - $position);
    $scriptBuffer .= substr($script, $prevPosition, $position).vbet_translateHTMLFromTo($toTranslate, $forumLanguage, $_REQUEST['language'], $vbet_serie);	
    ++$scriptIndex;
    $prevPosition = $end + strlen('</table>');
    }	
    $what[1] = $scriptBuffer.substr($script, $prevPosition);
    } else {
    $what[1] = vbet_getReEncoded($what[1]);
    }			
    return vbet_addToReplacementsBuffer($what);
    }
    3. Replace it by:
    Code:
    function vbet_addScriptToTable($what) {
    global $vbulletin;
    if ($vbulletin->options['vbenterprisetranslator_vbseo_message'] && strpos($what[1], 'vbseo_jshtml[0]')) {
    $scriptIndex = 0;
    $position = 0;
    $prevPosition = 0;
    $scriptBuffer = '';
    $script = $what[1];
    $forumLanguage = $vbulletin->options['vbenterprisetranslator_forumlanguage'];
    global $vbet_serie;
    while (true) {
    $position = strpos($script, 'vbseo_jshtml['.$scriptIndex.']', $prevPosition);
    if (!$position) {
    break;
    }
    $position = strpos($script, '<ol>', $position);
    $end = strpos($script, '</ol>', $position);
    $toTranslate = substr($script, $position, $end + strlen('</ol>') - $position);
    $scriptBuffer .= substr($script, $prevPosition, $position).vbet_translateHTMLFromTo($toTranslate, $forumLanguage, $_REQUEST['language'], $vbet_serie);
    ++$scriptIndex;
    $prevPosition = $end + strlen('</ol>');
    }
    $what[1] = $scriptBuffer.substr($script, $prevPosition);
    } else {
    $what[1] = vbet_getReEncoded($what[1]);
    }
    return vbet_addToReplacementsBufferNoReencode($what);
    }
    function vbet_addToReplacementsBufferNoReencode($what) {
    global $vbet_replacementsBuffer;
    $vbet_replacementsBuffer[] = $what[1];
    return '<vbet'.(count($vbet_replacementsBuffer)-1).'/>';
    }
    Last edited by vBET; 24-05-11 at 16:35.

Page 3 of 3 FirstFirst 123

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •