Php regular expression replacement

Source: Internet
Author: User
Php regular expression replacement question this post is finally edited and replaced by wljk506 in 2014-09-2413: 14: 44 & nbsp; script & nbsp; Code Part comment .... (start to end) & nbsp; is blank $ str & lt; script & gt; & nbsp; document. write (unescape php regular expression replacement problem

This post was last edited by wljk506 at 13:14:44

Replacing the comments of script code //... (// starting to the end of the line) is null

$ Str ="
Script document. write (unescape (\ "% 3 Cspan id = 'szgs _ stat_icon_2 '% 3E % 3C/span % 3E % 3 Cscript src = 'http: // www.szgswljg.gov.cn/sendMark? Siteid = 2 & website = z.com 'type = 'text/javascript '% 3E % 3C/script % 3E \ "); script

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.