PDA

Veure la Versió Completa: VBET no reescriptura Obert gràfic descripcions



mykkal
19-06-15, 08:22
Hola Martí,

Trobat un altre error per a vostè. Té a veure amb la participació social, mitjançant aquesta versió. Sempre que puc compartir des d'una url traduït el opengraph de dades utilitza el contingut original de la versió en anglès.

Per exemple, aquesta url és en italià, però l'open gràfic etiquetes tirar la descriptyion i compartir la url de la versió en anglès: Truffa Fittizio, Agent modellante Julia Rodi (http://mymodeltalk.com/jobs/it/modeling-nigerian-419-industry-scams/330355-scam-ficticious-modeling-agent-julia-rhodes.html)
Teniu a la vista de la font per veure què vull dir. A continuació és un extracte:


<meta property="og:description" content="Hello my name is Julia Rhodes, and am a freelance modeling agent working for female first magazine in recruiting models.Female first Magazine" /><meta property="og:url" content="http://mymodeltalk.com/jobs/modeling-nigerian-419-industry-scams/330355-scam-ficticious-modeling-agent-julia-rhodes.html" /><meta property="og:type" content="article" /><meta property="og:image" content="http://mymodeltalk.com/file/style/mmt/newslettergraphic.jpg" /><meta property="og:title" content="Scam by Ficticious Modeling Agent Julia Rhodes" />

Tot excepte el "og:imatge contingut" hauria de ser en italià. Fins ara, aquest no aconsegueix traduir o visualitzar la correcta descripció, url d'ubicació,i el títol.

Teniu algun codi que podria utilitzar per solucionar aquest problema? Si un llegeix el fil en la seva llengua nativa estic segur que volen compartir en els social media en la seva llengua materna.

He trobat aquest error a través de google webmaster tools. es va informar duplicat descripcions i títols.

Marcin Kalak
19-06-15, 14:46
Hola,
Veig que esteu afegint obert gràfic etiquetes utilitzant Obert Gràfic Descripció & Title Fixar en Fils/Blog. Vostè ha d'integrar aquest producte amb vBET.
Integrar aquest producte amb la versió completa de vBET:

Edita plugin AdminCP->Connectors & Productes->Plugin Manager->Obre Gràfic Descripció / Mosaic Substituir
Enganxeu aquest codi a l'inici:

require_once(DIR. '/includes/vbenterprisetranslator_functions.php');
require_once(DIR. '/includes/vbenterprisetranslator_functions_utils.php');
global $vbulletin;
$forumLanguage = $vbulletin->options['vbenterprisetranslator_forumlanguage'];
$language = $_REQUEST['language'];
$serie = microtime(true) * 10000;
Cerca:

$og_array['og:description'] = $thread['meta_description'];
$og_array['og:title'] = $thread['title'];
SUBSTITUIR-la amb aquest codi (Per a utf-8 caràcters):

$og_array['og:description'] = vbet_translateText($thread['meta_description'], $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText($thread['title'], $forumLanguage, $language, $serie);
SUBSTITUIR-la amb aquest codi (Per no utf-8 caràcters):

$og_array['og:description'] = vbet_translateText(vbet_encodeToSafeUTF8($thread['meta_description']), $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText(vbet_encodeToSafeUTF8($thread['title']), $forumLanguage, $language, $serie);
Cerca:

$og_array['og:description'] = $ogdesc;
$og_array['og:title'] = $bloginfo['title'] . ' ' . $vbphrase['posted_by'] . ' ' . $bloginfo['username'];
SUBSTITUIR-la amb aquest codi (Per a utf-8 caràcters):

$og_array['og:description'] = vbet_translateText($ogdesc, $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText($bloginfo['title'], $forumLanguage, $language, $serie);
SUBSTITUIR-la amb aquest codi (Per no utf-8 caràcters):

$og_array['og:description'] = vbet_translateText(vbet_encodeToSafeUTF8($ogdesc), $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText(vbet_encodeToSafeUTF8($bloginfo['title']), $forumLanguage, $language, $serie) . ' ' . $vbphrase['posted_by'] . ' ' . $bloginfo['username'];;
Guardar el canvi.


Integrar aquest producte amb la versió gratuïta de vBET:

Edita plugin AdminCP->Connectors & Productes->Plugin Manager->Obre Gràfic Descripció / Mosaic Substituir
Enganxeu aquest codi a l'inici:

require_once(DIR. '/includes/vbenterprisetranslator_functions.php');
$language = $_REQUEST['language'];
$serie = microtime(true) * 10000;
Cerca:

$og_array['og:description'] = $thread['meta_description'];
$og_array['og:title'] = $thread['title'];
SUBSTITUIR-la amb aquest codi (Per a utf-8 caràcters):

$og_array['og:description'] = vbet_translateText($thread['meta_description'], $language, $serie);
$og_array['og:title'] = vbet_translateText($thread['title'], $language, $serie);
SUBSTITUIR-la amb aquest codi (Per no utf-8 caràcters):

$og_array['og:description'] = vbet_translateText(vbet_encodeToSafeUTF8($thread['meta_description']), $language, $serie);
$og_array['og:title'] = vbet_translateText(vbet_encodeToSafeUTF8($thread['title']), $language, $serie);
Cerca:

$og_array['og:description'] = $ogdesc;
$og_array['og:title'] = $bloginfo['title'] . ' ' . $vbphrase['posted_by'] . ' ' . $bloginfo['username'];
SUBSTITUIR-la amb aquest codi (Per a utf-8 caràcters):

$og_array['og:description'] = vbet_translateText($ogdesc, $language, $serie);
$og_array['og:title'] = vbet_translateText($bloginfo['title'], $language, $serie);
SUBSTITUIR-la amb aquest codi (Per no utf-8 caràcters):

$og_array['og:description'] = vbet_translateText(vbet_encodeToSafeUTF8($ogdesc), $language, $serie);
$og_array['og:title'] = vbet_translateText(vbet_encodeToSafeUTF8($bloginfo['title']), $language, $serie) . ' ' . $vbphrase['posted_by'] . ' ' . $bloginfo['username'];;
Guardar el canvi.

mykkal
19-06-15, 18:13
Home ets awesome... Gràcies un grapat.

Fabiano
20-06-15, 20:24
Marcin, tindran aquest reajustament a la propera versió de PRO de vBET?

Marcin Kalak
22-06-15, 09:38
Aquesta integració no requereix canvi de codi en vBET. Aquestes funcions de canvis del codi de plugin a vBET tradueix tags afegit per ell.

Vetall
03-02-17, 10:36
Bon dia!

vBET Traductor 4.7.2
vBulletin 4.2.3

Obert Gràfic Descripció & Title Fixar en Fils/Blog 1.2.0


Obert Gràfic Descripció / Mosaic Substituir fb_opengraph_array:

if (THIS_SCRIPT == 'showthread') //For Threads
{
global $thread;
$og_array['og:description'] = $thread['meta_description'];
$og_array['og:title'] = $thread['title'];
}

if (THIS_SCRIPT == 'entry') //For Blog Entries
{
global $vbphrase, $bloginfo;
$ogdesc = strip_bbcode($bloginfo['pagetext'], true, false, false, true);
$ogdesc = htmlspecialchars ($ogdesc);
$ogdesc = preg_replace('!\s+!', ' ', $ogdesc);
$ogdesc = (strlen($ogdesc) > 303) ? substr($ogdesc,0,300).'...' : $ogdesc;
$og_array['og:description'] = $ogdesc;
$og_array['og:title'] = $bloginfo['title'] . ' ' . $vbphrase['posted_by'] . ' ' . $bloginfo['username'];
}


Després de la integració de canvis:


require_once(DIR. '/includes/vbenterprisetranslator_functions.php');
require_once(DIR. '/includes/vbenterprisetranslator_functions_utils.php');
global $vbulletin;
$forumLanguage = $vbulletin->options['vbenterprisetranslator_forumlanguage'];
$language = $_REQUEST['language'];
$serie = microtime(true) * 10000;

if (THIS_SCRIPT == 'showthread') //For Threads
{
global $thread;
$og_array['og:description'] = vbet_translateText($thread['meta_description'], $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText($thread['title'], $forumLanguage, $language, $serie);
}

if (THIS_SCRIPT == 'entry') //For Blog Entries
{
global $vbphrase, $bloginfo;
$ogdesc = strip_bbcode($bloginfo['pagetext'], true, false, false, true);
$ogdesc = htmlspecialchars ($ogdesc);
$ogdesc = preg_replace('!\s+!', ' ', $ogdesc);
$ogdesc = (strlen($ogdesc) > 303) ? substr($ogdesc,0,300).'...' : $ogdesc;
$og_array['og:description'] = vbet_translateText($ogdesc, $forumLanguage, $language, $serie);
$og_array['og:title'] = vbet_translateText($bloginfo['title'], $forumLanguage, $language, $serie);
}


-- l'error:



Base de dades d'error en vBulletin 4.2.3:

No vàlid SQL:
SELECCIONEU la memòria cau.originaltext com originaltext, la memòria cau.traduït traduït DEL vbenterprisetranslator_cache_ ajuda, vbenterprisetranslator_cache_ cau a l'ajuda.originaltext='******************************************' I la memòria cau.sèrie=ajuda.sèrie;

MySQL Error : Taula 'vbenterprisetranslator_cache_" no existeix
Nombre d'error: 1146

Marcin Kalak
03-02-17, 20:31
Proveu d'afegir després de:

$language = $_REQUEST['language'];
codi següent:

if(!$language) {
$language = $forumLanguage;
}

Vetall
06-02-17, 08:07
Gràcies per la resposta.


Mòdul codi Open "Gràfic Descripció / Mosaic a Substituir":



require_once(DIR. '/includes/vbenterprisetranslator_functions.php'); require_once(DIR. '/includes/vbenterprisetranslator_functions_utils.php'); global $vbulletin; $forumLanguage = $vbulletin->options['vbenterprisetranslator_forumlanguage']; $language = $_REQUEST['language']; if(!$language) { $language = $forumLanguage; } $serie = microtime(true) * 10000;
if (THIS_SCRIPT == 'showthread') //For Threads{ global $thread; $og_array['og:description'] = vbet_translateText($thread['meta_description'], $forumLanguage, $language, $serie); $og_array['og:title'] = vbet_translateText($thread['title'], $forumLanguage, $language, $serie);}
if (THIS_SCRIPT == 'entry') //For Blog Entries{ global $vbphrase, $bloginfo; $ogdesc = strip_bbcode($bloginfo['pagetext'], true, false, false, true); $ogdesc = htmlspecialchars ($ogdesc); $ogdesc = preg_replace('!\s+!', ' ', $ogdesc); $ogdesc = (strlen($ogdesc) > 303) ? substr($ogdesc,0,300).'...' : $ogdesc; $og_array['og:description'] = vbet_translateText($ogdesc, $forumLanguage, $language, $serie); $og_array['og:title'] = vbet_translateText($bloginfo['title'], $forumLanguage, $language, $serie);


MySQL errors -- no!
-- traducció no og:descripció no
<meta property="og:description" content="*******

Marcin Kalak
06-02-17, 21:42
Si us plau enviar-me uns detalls d'accés del PM a Admin CP i FTP. Comprovaré què està anant en allà :)

Vetall
16-02-17, 07:31
Marcin Kalak, прошу прощения, все прекрасно работает****** :o

Marcin Kalak
16-02-17, 16:52
Gràcies molt per la informació.

Automatic Translations (Powered by Google, Microsoft®, Yandex, SDL Language Cloud, IBM Watson and Apertium):
AfrikaansAlbanianArabicBelarusianBulgarianCatalanChineseCroatianCzechDanishDutchEnglishEstonianFilipinoFinnishFrenchGalicianGermanGreekHaitian CreoleHebrewHindiHungarianIcelandicIndonesianIrishItalianJapaneseKoreanLatvianLithuanianMacedonianMalayMalteseNorwegianPersianPolishPortugueseRomanianRussianSerbianSlovakSlovenianSpanishSwahiliSwedishTaiwaneseThaiTurkishUkrainianVietnameseWelshYiddish
Languages translations supported by vBET 4.10.1