Backend Development
PHP Problem
How to implement PHP regular matching that does not contain a certain characterHow to implement PHP regular matching that does not contain a certain character
How to implement php regular matching that does not contain a certain character: first create a PHP sample file; then enter the statement "$search = '//is ';preg_match_all($search,$str,$r);"; Finally, execute the file.

Recommended: "PHP Video Tutorial"
php Regular matching content does not include A certain character
Specific question:
I need to match characters that include , but they cannot contain
For example:
Hello customer, I recommend the following projects to you:
I want to match
Implementation method:
<?php $str = '客户您好,为您推荐以下项目:<项目2:项目名称<项目3:项目名称>>以及<项目1:项目名称>'; $search = '/<([^<]*?)>/is'; preg_match_all($search,$str,$r); echo '<pre class="brush:php;toolbar:false">'; print_r($r); echo ''; ?>
The above is the detailed content of How to implement PHP regular matching that does not contain a certain character. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undress AI Tool
Undress images for free

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver Mac version
Visual web development tools

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

Dreamweaver CS6
Visual web development tools





