HTML အကိုးအကား

အက္ခရာဖြင့် HTML HTML အမျိုးအစားအလိုက် HTML Browser ပံ့ပိုးမှု HTML အရည်အချင်းများ HTML ကမ္ဘာလုံးဆိုင်ရာ အရည်အချင်းများ HTML ပွဲများ HTML အရောင်များ HTML Canvas HTML အသံ/ဗီဒီယို HTML အက္ခရာအစုံများ HTML Doctypes HTML URL ကုဒ် HTML ဘာသာစကားကုဒ်များ HTML နိုင်ငံကုဒ်များ HTTP မက်ဆေ့ခ်ျများ HTTP နည်းလမ်းများ PX မှ EM Converter ကီးဘုတ်ဖြတ်လမ်းများ


HTML <script> Attribute လို့ ရိုက် ထည့်ပါ။

❮ HTML <script> တဂ်

ဥပမာ

သတ်မှတ်ထားသော အမျိုးအစား ရည်ညွှန်းချက်ပါသော script တစ်ခု-

<script type="application/javascript">
document.getElementById("demo").innerHTML = "Hello JavaScript!";
</script>

အဓိပ္ပါယ်နှင့် အသုံးပြုမှု

attribute သည် script အမျိုးအစား ကို typeသတ်မှတ်သည်။

ရည်ညွှန်းချက်သည် tag နှင့် tag typeကြား အကြောင်းအရာကို ခွဲခြားသတ်မှတ်သည် ။ <script></script>


Browser ပံ့ပိုးမှု

Attribute
type Yes Yes Yes Yes Yes

အထားအသို

<script type="scripttype">

ရည်ညွှန်းတန်ဖိုးများ

Value Description
scripttype Specifies the type of the script.

Some common values:
  • A JavaScript MIME type like: application/javascript (default) or application/ecmascript
  • module:
  • Another MIME type. src attribute will be ignored

Look at IANA Media Types for a complete list of standard media types.


❮ HTML <script> တဂ်