Curly Bracket Delimeters.


Posted on 16th Feb 2014 07:03 pm by admin

I'd always believed that the starting and ending delimeters in preg_ functions had to be the same character, but recently discovered that you can use the curly brackets.

Example:
Code: [Select]if(preg_match('{[0-9]}', $input)) {
I was just wondering if there was any disadvantage/advantage of using this method?

No comments posted yet

Your Answer:

Login to answer
195 Like 29 Dislike
Previous forums Next forums
Other forums

Help with setcookie()
Merry Xmas to those on this foruum
Older guy here with some experience but not allot so please be

Placing and array within an array then sorting it!
I have a page that runs two large mysql queries and saves the results into arrays, in php I then per

Taylor Series Function
So I am working a a project for my intro C++ class, and I am having some trouble with a function for

CHECH A STRING FOR ' " ' (DOUBLE QUOTES)
I am checking for delimiter (.!?) and if there is a " after a sentence then it should neglect a

Table sorting
Hi,

I'm trying to modify the following in order to make the output table sorted alphabeticall

need help with php get
i have a option box that gets filled with dates, but how do i get once the option value has been cli

Can I call a class inside a function?
I have a class written in another file that handles my image resizing.

Can I do this (php say

Limiting checkboxes?
Hi guys,

I have this code: Code: if(isset($_POST['selected'])) {
foreach($_POST['selec

help countdown timers
hello every one,

I'd like to know how to insert many countdowns in the same page.
The dura

session variable problem
Session variable is not working in Fire fox i am getting null value but it is working fine in IE.

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash