Skip to content

inneka.com

Programming Tutorials

  • Blog
  • SEO
  • Programming
    • Python
    • WordPress
    • Javascript
    • React Native
    • ReactJS
    • Golang
    • Vue.js
    • Android
    • C#
    • CSS
    • HTML
    • iOS
    • Java
    • JQuery
    • PHP
    • AJAX
    • Angular JS
    • ASP.NET
    • AWS
    • C++
    • Eclipse
    • Entity Framework
    • IntelliJ IDEA
    • Laravel
    • Objective-C
    • Pandas
    • R
    • Ruby On Rails
    • Scala
    • Spring
    • Swift
    • Twitter Bootstrap
    • VBA
    • Xcode
    • XML
  • Linux
  • Windows
  • Alternatives
    • Inneka Mobile Application Policy
    • Term of Use
  • Locations

Solution 2:

<script> is HTML 5.

<script type='text/javascript'> is HTML 4.x (and XHTML 1.x).

<script language="javascript"> is HTML 3.2.

Is it different for different webservers?

No.

when I did an offline javascript test, i realised that i need the <script type = 'text/javascript'> tag.

That isn't the case. Something else must have been wrong with your test case.

Solution 3:

Douglas Crockford says:

type="text/javascript"

This attribute is optional. Since
Netscape 2, the default programming
language in all browsers has been
JavaScript. In XHTML, this attribute
is required and unnecessary. In HTML,
it is better to leave it out. The
browser knows what to do.

In HTML 4.01 and XHTML 1(.1), the type attribute for <script> elements is required.

Solution 4:

<!-- HTML4 and (x)HTML -->
<script type="text/javascript"></script>


<!-- HTML5 -->
<script></script>

type
attribute identifies the scripting language of code embedded within a script element or referenced via the element’s src attribute. This is specified as a MIME type; examples of supported MIME types include text/javascript, text/ecmascript, application/javascript, and application/ecmascript. If this attribute is absent, the script is treated as JavaScript.

Ref: https://developer.mozilla.org/en/docs/Web/HTML/Element/script

Post navigation

Previous Previous post: How to post an array of complex objects with JSON, jQuery to ASP.NET MVC Controller?
Next Next post: How to have multiple data-bind attributes on one element?

Recent Posts

  • Integration test Controller decorated with [Authorize] attribute
  • Fiddler with WebAPI is acting flaky
  • Login into Asp.net Web application with Finerprint using asp.net C# Javascript
  • Login into Asp.net Web application with Finerprint using asp.net C# Javascript
  • MVC project stops debugging right after opening Chrome pane

Categories

  • AJAX
  • Android
  • Angular JS
  • ASP.NET
  • AWS
  • Blog
  • C#
  • C++
  • CSS
  • Eclipse
  • Entity Framework
  • Golang
  • HTML
  • IntelliJ IDEA
  • iOS
  • Java
  • Javascript
  • JQuery
  • Keras
  • Laravel
  • Linux
  • Locations
  • Machine Learning
  • Objective-C
  • OpenCV
  • Pandas
  • PHP
  • Programming
  • Python
  • R
  • React Native
  • ReactJS
  • Ruby On Rails
  • Scala
  • SEO
  • Spring
  • Swift
  • Tensorflow
  • Twitter Bootstrap
  • Uncategorized
  • VBA
  • Vue.js
  • Windows
  • Wordpress
  • Xcode
  • XML
  • Blog
  • SEO
  • Programming
    • Python
    • WordPress
    • Javascript
    • React Native
    • ReactJS
    • Golang
    • Vue.js
    • Android
    • C#
    • CSS
    • HTML
    • iOS
    • Java
    • JQuery
    • PHP
    • AJAX
    • Angular JS
    • ASP.NET
    • AWS
    • C++
    • Eclipse
    • Entity Framework
    • IntelliJ IDEA
    • Laravel
    • Objective-C
    • Pandas
    • R
    • Ruby On Rails
    • Scala
    • Spring
    • Swift
    • Twitter Bootstrap
    • VBA
    • Xcode
    • XML
  • Linux
  • Windows
  • Alternatives
    • Inneka Mobile Application Policy
    • Term of Use
  • Locations

About Us

This site is in The Inneka Network (also referred to herein as “Inneka” or “Network” or “Inneka.com”) which is a set of related Internet websites and applications. All of our products are focused on providing useful information and knowledge to our reader.

All site design, logo, content belongs to Inneka Network. All rights reserved.

You are PROHIBITED to copy, sell, include, distribute, or commercially exploit any content of Inneka Network websites on to any other websites, applications, youtube.

Links

  • Privacy Policy
  • Cookie Policy
  • Terms of Use

In Our Network

  • https://inneka.com
  • https://oraerr.com
  • https://config9.com
  • https://tuatphukien.com
  • https://ibook.casa
  • https://pes4fun.com
  • https://itool.casa
inneka.com Privacy Policy Proudly powered by Dazzlink theme of Inneka.com