Showing posts with label php string. Show all posts
Showing posts with label php string. Show all posts

Tuesday, November 7, 2017

phpMyPassion

How To Reverse A String In PHP ?

Commonly in interview we have been asked about reverse a string. So here I am going to share the solution for this type of question with my article. Image source : google images This...

Read More

Tuesday, March 21, 2017

anil

how to search a specific word in a string in php?

You can use the strpos function which is used to find the occurrence of one string inside other strpos() : strpos() function — Find the position of the first occurrence of a substring in a different string...

Read More

Tuesday, January 24, 2017

anil

How to count the number of substring occurrences in a string ?

Common PHP issue that mostly developer face. below is the solution for such type of issue.. substr_count substr_count — Count the number of substring occurrences int substr_count ( string $haystack , string $needle [, int $offset = 0 [, int $length ]] ) substr_count() returns the number of times the needle substring occurs in...

Read More

Wednesday, January 18, 2017

anil

How to remove everything before a specific first character?

Sometime developers are facing the issue of eliminating all characters before the first specific character. Here I am describing how you can remove all the characters before a specific thing. Just suppose we have...

Read More