خصائص draggable في HTML

تعريف الاستخدام

draggable خصائص تحديد ما إذا كان العنصر قابل للسحب.

النص: رابط الصور والفيديوهات قابل للسحب بشكل افتراضي.

Tip:draggable Attributes are commonly used in drag-and-drop operations. Learn more in our drag-and-drop tutorial.

See also:

HTML tutorial:HTML ɗanɗi

HTML tutorial:HTML5 ɗanɗi

JavaScript reference manual:ondrag ɗanɗi

Example

A draggable paragraph:

<p draggable="true">This is a draggable paragraph.</p>

Try it yourself

Syntax

<element draggable="true|false|auto">

Attribute value

Value Description
true Specifies that the element is draggable.
false Specifies that the element is not draggable.
auto Use the default behavior of the browser.

Browser support

The numbers in the table indicate the first browser version to fully support this attribute.

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
4.0 9.0 3.5 6.0 12.0