Matching a space in regex

If you’re looking for a space, that would be ” ” (one space). If you’re looking for one or more, it’s ” *” (that’s two spaces and an asterisk) or ” +” (one space and a plus). If you’re looking for common spacing, use “[ X]” or “[ X][ X]*” or “[ X]+” where X … Read more

What do ++ and *+ mean?

++ From What is double plus in regular expressions? That’s a Possessive Quantifier. It basically means that if the regex engine fails matching later, it will not go back and try to undo the matches it made here. In most cases, it allows the engine to fail much faster, and can give you some control … Read more

How do I make a redirect in PHP?

Summary of existing answers plus my own two cents: 1. Basic answer You can use the header() function to send a new HTTP header, but this must be sent to the browser before any HTML or text (so before the <!DOCTYPE …> declaration, for example). 2. Important details die() or exit() Why you should use die() or exit(): The Daily WTF Absolute or relative URL … Read more

Calculate business days

Here’s a function from the user com ments on the date() function page in the PHP manual. It’s an improvement of an earlier function in the comments that adds support for leap years. Enter the starting and ending dates, along with an array of any holidays that might be in between, and it returns the … Read more

deneme bonusu veren sitelerbahis casinomakrobetceltabetpinbahispolobetpolobet girişpinbahis girişmakrobet girişpulibet girişmobilbahis girişkolaybet giriş