# حجم الإطار المضمن غير صحيح

**URL:** https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820
**Category:** Support
**Created:** [25 ديسمبر 2022، 1:20ص UTC](https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820 "2022-12-25T01:20:24Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![jacob\_kahn](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jacob_kahn/32/244484_2.png) [@jacob\_kahn](https://meta.discourse.org/u/jacob_kahn)
#### Post date: [25 ديسمبر 2022، 1:20ص UTC](https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820/1 "2022-12-25T01:20:24Z")

</div>

مرحباً بالجميع!

لا يمكنني الحصول على الـ iframe الذي أحاول تضمينه في موضوع بشكل صحيح. انظر كم هو صغير! هل يعرف أحد كيف يمكن إصلاح هذا؟

شكراً مقدماً!

 ![image](https://global.discourse-cdn.com/meta/original/4X/3/8/0/3806c519f77adad41aeb100f7155f19b918322e1.png)

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [25 ديسمبر 2022، 1:51ص UTC](https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820/2 "2022-12-25T01:51:25Z")

</div>

يجب عليك تعيين `width` و `height` الخاصين بعنصر iframe كقيم مطلقة. أيضًا، يجب تعيين العرض والارتفاع كسمات (attributes) لعنصر iframe، وليس في سمة `style` (سيقوم Discourse بإزالة سمة style عند معالجة المنشور).

إليك مثال منسوق من عنصر iframe الخاص بـ Youtube يوضح كيفية القيام بذلك:

```plaintext
<iframe width="560" height="315" src="https://www.youtube.com/embed/r-i6XpcL1Fs" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

```

أعتقد أن الحد الأقصى للعرض الذي يمكنك استخدامه في منشور Discourse هو `600`. يجب أن يكون بخير استخدام كود iframe من لقطة الشاشة الخاصة بك، ولكن فقط أضف `width="600" height="400"` إليه، بعد وسم iframe الافتتاحي. يمكنك تجربة قيم مختلفة للعرض والارتفاع لمعرفة ما يناسبك.

---

<div class="post-metadata">

### Author: ![jacob\_kahn](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jacob_kahn/32/244484_2.png) [@jacob\_kahn](https://meta.discourse.org/u/jacob_kahn)
#### Post date: [25 ديسمبر 2022، 3:03ص UTC](https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820/3 "2022-12-25T03:03:02Z")

</div>

> [@simon](#):
>
> ```plaintext
> 
> <iframe width="560" height="315" src="https://www.youtube.com/embed/r-i6XpcL1Fs" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
> 
> ```

@simon شكراً جزيلاً! لقد نجح الأمر تماماً! عطلة سعيدة!

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [24 يناير 2023، 3:03ص UTC](https://meta.discourse.org/t/iframe-is-not-the-correct-size/249820/4 "2023-01-24T03:03:34Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
