关于表单标签中的脚本标签 [英] about script tags inside form tags

查看:24
本文介绍了关于表单标签中的脚本标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在动态创建选项的选择标签旁边添加了一个脚本标签.该函数工作正常,但 W3C 验证器给了我 4 个关于此语法的错误.如果你们能帮我找到解决这个问题的办法.

i have added a script tag in side a select tag which creates options dynamically. The function works fine but the W3C validator gives me 4 errors regarding this syntax. It will be helpful if you guys could find me a solution for this problem.

这些是重复 2 次的 2 个错误.

These are the 2 errors that repeat 2 times.

1. 此处的文档类型不允许元素脚本"

1. document type does not allow element "script" here

2. year_option();未完成的选择"的结束标记

2. year_option(); end tag for "select" which is not finished

推荐答案

1)

发送“验证码”获取 | 15天全站免登陆