E
E
exxagw2015-12-09 13:12:29
Regular Expressions
exxagw, 2015-12-09 13:12:29

How to write a regexp condition?

$content = " +  +  +  +  + ";
$pattern = ____ тут regexp ____;
if (preg_match($pattern, $content, $matches) > 0) {
   echo $matches[0];
}

And I should get everything except what starts with [[- or [[!-, but as a result you don't need to get "!"
$param_1
$param_2
*param_3
*param4_

Help good people

Answer the question

In order to leave comments, you need to log in

[[+comments_count]] answer(s)
M
Max, 2015-12-09
@AloneCoder

/\[\[\!?(?!\-).(\w+)\]\]/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question