glot لـ Drupal
أنظمة إدارة المحتوى · موصّل
يتصل glot مباشرةً بـ Drupal: يقرأ محتواك ويترجمه وفق مسرد المصطلحات والفحوصات الخاصة بك، ثم يكتب الترجمات في لغات Drupal.
خطوات المنصة مكتوبة بالإنجليزية، بأسماء القوائم كما تظهر في واجهة Drupal.
ربط Drupal
- In glot, open your project → Integrations → Drupal and fill in the connection form (the credentials and permissions it asks for are listed in the docs).
- Click Test connection, then Sync now: glot pulls your content, translates it with your glossary and validation rules, and writes each language back.
- Later changes sync automatically through the webhook URL shown on the card, or on the next scheduled sync.
بديل: الوسم العام
لترجمة ما لا يغطيه تكامل Drupal داخل المتصفح، أضف الوسم العام بدلًا من ذلك.
- في glot، أنشئ مشروعًا وأضف لغاتك.
- افتح glot Edge ← وسم الموقع وأدخل عنوان موقعك: يترجمه glot ويعرض عليك معاينة. بعد لصق الوسم، تحقق من التثبيت في المكان نفسه ثم فعّل الوسم.
- انسخ وسمك من ذلك التبويب: فهو يتضمن مشروعك ومفتاحه العام (data-key). يوضح الوسم أدناه شكله.
<script src="https://app.glotlang.com/widget/glot.js" data-project="your-project" data-key="pk_…" async></script>- In your custom theme (or a sub-theme), open THEME.libraries.yml.
- Add a library with header: true and the glot script URL under js: with type: external, and its attributes (async: true, data-glot-app: true, data-project, data-server, data-source, data-locales, data-key).
- In THEME.info.yml, list the library under libraries: (for example - THEME/glot) so it loads on every page.
- Clear the Drupal cache and check the page source for the glot script.
الخطط المطلوبة
Drupal is self-hosted open source; no plan limits. You need access to the theme files. Core has no admin field for site-wide head code.
من جهة glot، راجع صفحة الأسعار لمعرفة ما تتضمنه كل خطة. glot Edge (الروابط المترجمة) جزء من خطة Growth، مع تجربة محدودة في Pro.
روابط مترجمة لمحركات البحث
للحصول على صفحات مترجمة تفهرسها محركات البحث دون تشغيل JavaScript، ضع glot Edge على نطاق فرعي من نطاقك (es.example.com) بسجلّي DNS:
es.example.com. CNAME edge.glotlang.com.
_glot.es.example.com. TXT "<token shown in the dashboard>"You control your own domain and DNS, so add the CNAME and TXT at your DNS provider or registrar.
كيف يعمل glot Edgeأسئلة
- هل glot شريك لـ Drupal؟
- لا. glot مستقل، وليس تابعًا لـ Drupal ولا معتمدًا منه. يستخدم هذا الدليل ميزات Drupal القياسية فقط.
- هل يغيّر glot محتواي على Drupal؟
- يبقى محتواك الأصلي كما هو. يكتب glot الترجمات في حقول اللغات في Drupal، حيث يمكنك مراجعتها قبل النشر.
- هل ستفهرس محركات البحث ترجماتي؟
- ليس بالوسم وحده: فهو يترجم في المتصفح، لذا تفهرس محركات البحث لغتك الأصلية في الغالب. تحتاج الصفحات المترجمة ذات الروابط الخاصة إلى glot Edge أو إلى منصة تنشر كل لغة على رابط خاص بها.
- Can I just paste the tag into html.html.twig?
- It can work, but Drupal's documented way is a library in *.libraries.yml attached from *.info.yml. Edit a custom or sub-theme, not a contributed theme, or updates will overwrite it.
- How do I add data- attributes in libraries.yml?
- Under the script's attributes: key. A value of true prints the attribute with no value, which suits data-glot-app.
الوثائق الرسمية لـ Drupal
ترجم موقعك على Drupal
أنشئ مشروعًا واختر لغاتك واتبع الخطوات أعلاه.
تكاملات أخرى: أنظمة إدارة المحتوى
Drupal علامة تجارية لمالكها. glot ليس تابعًا لـ Drupal.