Categories

Wednesday, April 24, 2024
#919814419350 therichposts@gmail.com
Php

Php Preg_Match Pattern for Week Days Name

Php preg_match Pattern for Week Days Name - The Rich Post

Hello to all, welcome to therichpost.com. In this post, I will tell you, Php Preg_Match Pattern for Week Days Name. 

This code helped me lot to solved my major problem in work and I am hoping this will help others.

Here is the working code and tested code for Php Preg_Match Pattern for Week Days Name:

$str = '2018-09-09sundayShift1From=12:30pm';

preg_match('/monday?|tuesday?|wednesday?|thursday?|friday?|saturday?|sunday?/', $str, $matchs);
echo $matchs[0];
//output is sunday

 If you have any query related to this post, then please do ask questions or comment below.

Thank you.

therichpost
the authortherichpost
Hello to all. Welcome to therichpost.com. Myself Ajay Malhotra and I am freelance full stack developer. I love coding. I know WordPress, Core php, Angularjs, Angular 14, Angular 15, Angular 16, Angular 17, Bootstrap 5, Nodejs, Laravel, Codeigniter, Shopify, Squarespace, jQuery, Google Map Api, Vuejs, Reactjs, Big commerce etc.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.