سمات AdSense
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
يعرض الجدول أدناه السمات التي يمكن ضبطها باستخدام الطريقتَين
googletag.PubAdsService.set(key, value)
أو googletag.Slot.set(key, value)
. يتم ضبط سمات AdSense هذه عادةً عند إنشاء خانات إعلانية أو تعديلها في "مدير إعلانات Google". وتسمح هذه الطرق للناشر بإلغاء هذه الإعدادات من جهة الخادم
لكل طلب على حدة.
سمة جديدة |
السمة القديمة |
مثال |
القيم المسموح بها |
adsense_channel_ids
|
google_ad_channel
|
271828183+314159265
|
معرّفات قنوات AdSense الصالحة، مفصولة بالعلامة "+"
|
adsense_ad_types
|
google_ad_type
|
text_image
|
text, image, text_image
|
adsense_ad_format
|
google_ad_format
|
250x250_as
|
468x60_as, 234x60_as, 125x125_as, 120x600_as, 160x600_as, 180x150_as, 120x240_as, 200x200_as, 250x250_as, 300x250_as, 336x280_as, 728x90_as
|
adsense_background_color
|
google_color_bg
|
#000000
|
ألوان سداسية عشرية
|
adsense_border_color
|
google_color_border
|
#000000
|
ألوان سداسية عشرية
|
adsense_link_color
|
google_color_link
|
#000000
|
ألوان سداسية عشرية
|
adsense_test_mode
|
N/A
|
on
|
on
يمكنك ضبط on للإشارة إلى أنّ العلامة تُستخدَم للاختبار ويجب عدم تضمينها في عملية الاحتساب أو الفوترة. احذف هذا الإعداد لزيارات الإنتاج وغير التجريبية.
|
adsense_text_color
|
google_color_text
|
#000000
|
ألوان سداسية عشرية
|
adsense_url_color
|
google_color_url
|
#000000
|
ألوان سداسية عشرية
|
adsense_ui_features
|
google_ui_features
|
rc:10
|
rc:10 للزوايا المستديرة جدًا، وrc:6 للزوايا المستديرة قليلاً، وrc:0 للزوايا المربّعة (الإعداد التلقائي)
|
document_language
|
N/A
|
en
|
يجب إدخال رمز لغة صالح وفقًا لمعيار ISO 639-1.
|
page_url
|
N/A
|
www.mysite.com
|
عناوين URL الصالحة
|
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-07-25 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-07-25 (حسب التوقيت العالمي المتفَّق عليه)"],[[["\u003cp\u003eThe table outlines AdSense attributes that can be modified using \u003ccode\u003egoogletag.PubAdsService.set\u003c/code\u003e or \u003ccode\u003egoogletag.Slot.set\u003c/code\u003e methods, enabling publishers to override server-side settings.\u003c/p\u003e\n"],["\u003cp\u003eThese attributes, typically managed in Google Ad Manager, include options for specifying ad channels, types, formats, colors, and test mode.\u003c/p\u003e\n"],["\u003cp\u003ePublishers can customize the appearance of ads with attributes controlling background, border, link, text, and URL colors, along with UI features like rounded corners.\u003c/p\u003e\n"],["\u003cp\u003eAdditional attributes allow setting the document language and page URL for more context and control.\u003c/p\u003e\n"],["\u003cp\u003eThe table provides examples of allowed values and links to relevant documentation for each attribute.\u003c/p\u003e\n"]]],["Publishers can use `googletag.PubAdsService.set` or `googletag.Slot.set` to override server-side AdSense settings. Attributes include `adsense_channel_ids` (valid channel IDs), `adsense_ad_types` (text, image, text_image), and `adsense_ad_format` (various sizes). Color customization is possible via `adsense_background_color`, `adsense_border_color`, `adsense_link_color`, `adsense_text_color`, and `adsense_url_color` (hexadecimal). `adsense_test_mode` enables testing, and `document_language` sets language, `page_url` sets the page url.\n"],null,["# AdSense Attributes\n\nThe table below lists the attributes that can be set with the\n`\n`[googletag.PubAdsService.set(key, value)](/publisher-tag/reference#googletag.PubAdsService_set)\nor\n[googletag.Slot.set(key, value)](/publisher-tag/reference#googletag.Slot_set)\nmethods. These AdSense attributes are typically set when creating or editing ad slots in\nGoogle Ad Manager. These methods allow the publisher to override these server-side settings\non a per-request basis.\n\n| **New attribute** | **Legacy attribute** | **Example** | **Allowed values** |\n|----------------------------|-----------------------|-----------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `adsense_channel_ids` | `google_ad_channel` | `271828183+314159265` | Valid AdSense channel IDs, separated by '+' |\n| `adsense_ad_types` | `google_ad_type` | `text_image` | `text, image, text_image` |\n| `adsense_ad_format` | `google_ad_format` | `250x250_as` | `468x60_as, 234x60_as, 125x125_as, 120x600_as, 160x600_as, 180x150_as, 120x240_as, 200x200_as, 250x250_as, 300x250_as, 336x280_as, 728x90_as` |\n| `adsense_background_color` | `google_color_bg` | `#000000` | hexadecimal colors |\n| `adsense_border_color` | `google_color_border` | `#000000` | Hexadecimal colors |\n| `adsense_link_color` | `google_color_link` | `#000000` | Hexadecimal colors |\n| `adsense_test_mode` | `N/A` | `on` | `on` Set `on` to indicate the tag is used for testing and should not be included in counting or billing. Omit this setting for production, non-test traffic. |\n| `adsense_text_color` | `google_color_text` | `#000000` | Hexadecimal colors |\n| `adsense_url_color` | `google_color_url` | `#000000` | Hexadecimal colors |\n| `adsense_ui_features` | `google_ui_features` | `rc:10` | `rc:10` for very rounded corners, `rc:6` for slightly rounded corners, `rc:0` for square corners (default) |\n| `document_language` | `N/A` | `en` | A valid [ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes). |\n| `page_url` | `N/A` | `www.mysite.com` | Valid URLs |"]]