Get yesterday date in PHP- To get yesterday’s date in PHP simply use the DateTime class and instantiate it with the constructor parameter ‘yesterday’ Then you can format the DateTime object with the format method. Code to Get yesterday date in PHP-

Unexpected T_VARIABLE An “unexpected T_VARIABLE” means that there’s a literal $variable name, which doesn’t fit into the current expression/statement structure. It most commonly indicates a missing semicolon in the previous line. Variable assignments following a statement are a good indicator of where to look: 2. String concatenation A frequent mishap are string concatenations with forgotten . operator: Btw, you should prefer string interpolation (basic variables in

How to solve Parse error / syntax error in phpRead More »

Get tomorrow date in PHP- To get tomorrow’s date in PHP simply use the DateTime class and instantiate it with the constructor parameter ‘tomorrow’ Then you can format the DateTime object with the format method. Code to get tomorrow date in PHP