summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-compat
diff options
context:
space:
mode:
authorMustafa Can Elmacı <mustafacan@elmaci.net>2024-11-17 15:52:45 +0300
committerPaul Donald <newtwen+github@gmail.com>2024-11-22 22:39:46 +0100
commitae8bbb814f16c2dc2a82e88d408bee1812ceda9c (patch)
treeb48de027e4f3d6a366ef60025b980bc83ee5ae90 /modules/luci-compat
parentaa955d6465b4d0f00cc713904e2de7bfb0cbd062 (diff)
treewide: HTML Cleanup
* HTML Cleanup: Meta tags. * Converted charset to shorthand. * Removed meta tags with `Content-Script-Type` attribute. (Invalid in HTML5 spec.) * HTML Cleanup: CSS tags. * Removed `type` attribute with CSS files from link tags. (HTML5 spec recommends omitting it.) * Removed `type` attribute from style tags. (Deprecated in HTML5 spec.) https://html.spec.whatwg.org/#attr-link-type https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style * HTML Cleanup: Convert from XHTML to HTML5 * Removed XML declaration. * Removed XML namespace. * Changed doctype to HTML5. * HTML Cleanup: CDATA tags. * CDATA sections should not be used within HTML they are considered as comments and not displayed. https://developer.mozilla.org/en-US/docs/Web/API/CDATASection * HTML Cleanup: Script tags. * Removed `language` attribute from script tags. (No longer valid in HTML5) * Removed `type` attribute with JavaScript MIME type from script tags. (HTML5 spec recommends omitting it.) https://html.spec.whatwg.org/multipage/scripting.html#attr-script-type https://mimesniff.spec.whatwg.org/#javascript-mime-type Signed-off-by: Mustafa Can Elmacı <mustafacan@elmaci.net>
Diffstat (limited to 'modules/luci-compat')
-rw-r--r--modules/luci-compat/luasrc/view/cbi/delegator.htm2
-rw-r--r--modules/luci-compat/luasrc/view/cbi/footer.htm2
-rw-r--r--modules/luci-compat/luasrc/view/cbi/ipaddr.htm2
-rw-r--r--modules/luci-compat/luasrc/view/cbi/simpleform.htm2
-rw-r--r--modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm6
5 files changed, 7 insertions, 7 deletions
diff --git a/modules/luci-compat/luasrc/view/cbi/delegator.htm b/modules/luci-compat/luasrc/view/cbi/delegator.htm
index 2606e7f6d7..0eb8f291fc 100644
--- a/modules/luci-compat/luasrc/view/cbi/delegator.htm
+++ b/modules/luci-compat/luasrc/view/cbi/delegator.htm
@@ -20,5 +20,5 @@
<input class="btn cbi-button cbi-button-back" type="submit" name="cbi.delg.back" value="<%:« Back%>" />
<% end %>
<% end %>
- <script type="text/javascript">cbi_d_update();</script>
+ <script>cbi_d_update();</script>
</div>
diff --git a/modules/luci-compat/luasrc/view/cbi/footer.htm b/modules/luci-compat/luasrc/view/cbi/footer.htm
index c72102340f..3dc5c9a0ad 100644
--- a/modules/luci-compat/luasrc/view/cbi/footer.htm
+++ b/modules/luci-compat/luasrc/view/cbi/footer.htm
@@ -36,6 +36,6 @@
</form>
-<script type="text/javascript">cbi_init();</script>
+<script>cbi_init();</script>
<%+footer%>
diff --git a/modules/luci-compat/luasrc/view/cbi/ipaddr.htm b/modules/luci-compat/luasrc/view/cbi/ipaddr.htm
index d34d8d9865..b861e19e9b 100644
--- a/modules/luci-compat/luasrc/view/cbi/ipaddr.htm
+++ b/modules/luci-compat/luasrc/view/cbi/ipaddr.htm
@@ -1,5 +1,5 @@
<%+cbi/valueheader%>
- <script type="text/javascript">
+ <script>
function switchToCIDRList(ev) {
var input = ev.target.previousElementSibling,
usecidr = document.getElementById(input.id + '_usecidr');
diff --git a/modules/luci-compat/luasrc/view/cbi/simpleform.htm b/modules/luci-compat/luasrc/view/cbi/simpleform.htm
index 9e1514546e..24c3e2558e 100644
--- a/modules/luci-compat/luasrc/view/cbi/simpleform.htm
+++ b/modules/luci-compat/luasrc/view/cbi/simpleform.htm
@@ -74,4 +74,4 @@
end
%>
-<script type="text/javascript">cbi_init();</script>
+<script>cbi_init();</script>
diff --git a/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm b/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm
index f81ee19614..c4631decec 100644
--- a/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm
+++ b/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm
@@ -1,6 +1,6 @@
<%+cbi/valueheader%>
-<script type="text/javascript">//<![CDATA[
+<script>
var freqlist = <%= luci.http.write_json(self.iwinfo.freqlist) %>;
var hwmodes = <%= luci.http.write_json(self.iwinfo.hwmodelist or {}) %>;
var htmodes = <%= luci.http.write_json(self.iwinfo.htmodelist) %>;
@@ -176,7 +176,7 @@
bwdt.value = <%= luci.http.write_json(self.map:get(section, "htmode")) %>;
chan.value = <%= luci.http.write_json(self.map:get(section, "channel")) %>;
}
-//]]></script>
+</script>
<label style="float:left; margin-right:3px">
<%:Mode%><br />
@@ -196,6 +196,6 @@
</label>
<br style="clear:left" />
-<script type="text/javascript">cbi_init_wifi('<%= cbid %>');</script>
+<script>cbi_init_wifi('<%= cbid %>');</script>
<%+cbi/valuefooter%>