字符串是否包含Ajax?

时间:2015-10-04 11:44:19

标签: javascript jquery html5 validation

我正在为JavaScript编写一个教程页面并阻止xss我想检查用户的输入是否包含任何ajax,以及它是否返回错误字符串。此外,输入中可用于xss的任何其他元素都应该使其出错。这个代码是什么?

1 个答案:

答案 0 :(得分:2)

尝试定义包含方法的 Step 5 of 6 | Installation -------------------------------------------------------------------------------- Each component will be installed individually. If you cancel the installation, some components might remain on your system. This installation may take several minutes, depending on your system and the options you selected. -------------------------------------------------------------------------------- Installing Intel(R) MPI Library, Runtime Environment for applications running on Intel(R) 64 Architecture component...Uninstalling Intel(R) MPI Benchmarks component... -------------------------------------------------------------------------------- Uninstalling Intel(R) MPI Library, Runtime Environment for applications running on Intel(R) 64 Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) MPI Library, Runtime Environment for applications running on Intel(R) Many Integrated Core Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) MPI Library for applications running on Intel(R) 64 Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) MPI Library for applications running on Intel(R) Many Integrated Core Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) Trace Analyzer for Intel(R) 64 Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) Trace Collector for Intel(R) 64 Architecture component... -------------------------------------------------------------------------------- Uninstalling Intel(R) Trace Collector for Intel(R) Many Integrated Core Architecture component... -------------------------------------------------------------------------------- Uninstalling Cluster Checker common files component... -------------------------------------------------------------------------------- Uninstalling Cluster Checker Analyzer component... -------------------------------------------------------------------------------- Uninstalling Cluster Checker Collector component... -------------------------------------------------------------------------------- Uninstalling Cluster Checker Database component... -------------------------------------------------------------------------------- Uninstalling Command line interface component... -------------------------------------------------------------------------------- Uninstalling Sampling Driver kit component... -------------------------------------------------------------------------------- Uninstalling Graphical user interface component... -------------------------------------------------------------------------------- Uninstalling Command line interface component... -------------------------------------------------------------------------------- Uninstalling Graphical user interface component... -------------------------------------------------------------------------------- Uninstalling Command line interface component... -------------------------------------------------------------------------------- Uninstalling Graphical user interface component... -------------------------------------------------------------------------------- Uninstalling Intel C++ Compiler for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel C++ Compiler for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel Fortran Compiler for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel Fortran Compiler for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel MKL core libraries for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel(R) Xeon Phi(TM) coprocessor support component... -------------------------------------------------------------------------------- Uninstalling Fortran 95 interfaces for BLAS and LAPACK for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling GNU* Compiler Collection support for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling PGI* compiler support for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling SP2DP interface for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Cluster support for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel MKL core libraries for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Fortran 95 interfaces for BLAS and LAPACK for IA-32 component... -------------------------------------------------------------------------------- Uninstalling GNU* Compiler Collection support for IA-32 component... -------------------------------------------------------------------------------- Uninstalling PGI* compiler support for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel TBB threading support for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel TBB threading support for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel IPP single-threaded libraries for IA-32: General package component... -------------------------------------------------------------------------------- Uninstalling Intel IPP single-threaded libraries for Intel(R) 64: General package component... -------------------------------------------------------------------------------- Uninstalling Intel IPP multi-threaded libraries for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel IPP multi-threaded libraries for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling Intel IPP Cryptography single-threaded for IA-32 for Linux component... -------------------------------------------------------------------------------- Uninstalling Intel IPP Cryptography single-threaded for Intel(R) 64 for Linux component... -------------------------------------------------------------------------------- Uninstalling Intel Cryptography IPP multi-threaded for Intel(R) 64 for Linux component... -------------------------------------------------------------------------------- Uninstalling Intel Cryptography IPP multi-threaded for IA-32 for Linux component... -------------------------------------------------------------------------------- Uninstalling Intel IPP Cryptography single-threaded for Intel(R) 64 for Android component... -------------------------------------------------------------------------------- Uninstalling Intel IPP Cryptography single-threaded for IA-32 for Android component... -------------------------------------------------------------------------------- Uninstalling Intel TBB source code component... -------------------------------------------------------------------------------- Uninstalling Intel TBB component... -------------------------------------------------------------------------------- Uninstalling Intel DAAL for IA-32 component... -------------------------------------------------------------------------------- Uninstalling Intel DAAL for Intel(R) 64 component... -------------------------------------------------------------------------------- Uninstalling GNU* GDB 7.6 (Provided under GNU General Public License v3) component... -------------------------------------------------------------------------------- Uninstalling Source of GNU* GDB 7.6 (Provided under GNU General Public License v3) component... -------------------------------------------------------------------------------- Uninstalling libelfdwarf.so library and it's sources (Provided under GNU Lesser General Public License) component... -------------------------------------------------------------------------------- Uninstalling GDB Eclipse* Integration on Intel(R) 64 (Provided under Eclipse Public License v.1.0) component... -------------------------------------------------------------------------------- Uninstalling Source of GDB Eclipse* Integration (Provided under Eclipse Public License v.1.0) component... -------------------------------------------------------------------------------- Uninstalling GNU* GDB 7.8 on Intel(R) 64 (Provided under GNU General Public License v3) component... -------------------------------------------------------------------------------- Uninstalling Source of GNU* GDB 7.8 (Provided under GNU General Public License v3) component... -------------------------------------------------------------------------------- Uninstalling Python sources (Provided under Python Software Foundation License) component... -------------------------------------------------------------------------------- Finalizing product configuration... -------------------------------------------------------------------------------- ln: failed to create symbolic link ‘/opt/intel/parallel_studio_xe_2016.0.047/documentation_2016’: No such file or directory ln: failed to create symbolic link ‘/opt/intel/parallel_studio_xe_2016.0.047/samples_2016’: No such file or directory chmod: cannot access ‘/opt/intel/parallel_studio_xe_2016.0.047/uninstall’: No such file or directory Press "Enter" key to continue ,不应通过验证的字符串,使用带有字符串作为参数的RegExp

RegExp.prototype.test()