{"id":4116,"date":"2012-05-23T05:13:18","date_gmt":"2012-05-23T05:13:18","guid":{"rendered":"http:\/\/phpcodez.com\/?p=4116"},"modified":"2012-05-23T05:13:18","modified_gmt":"2012-05-23T05:13:18","slug":"substr_compare","status":"publish","type":"post","link":"http:\/\/phpcodez.com\/substr_compare\/","title":{"rendered":"substr_compare()"},"content":{"rendered":"<p>It compares two strings from a specified start position<\/p>\n<p>This function returns:<br \/>\n0 &#8211; if the two strings are equal<br \/>\n&lt;0 &#8211; if string1 (from startpos) is less than string2<br \/>\n&gt;0 &#8211; if string1 (from startpos) is greater than string2<br \/>\nIf length is equal or greater than length of string1, this function returns FALSE<\/p>\n<p><strong>Example<\/strong><\/p>\n<pre>&lt;?php\n echo substr_compare(\"phpcodexc\",\"phpcode\",0);\n ?&gt;<\/pre>\n<p><strong>Output<\/strong><\/p>\n<p>2<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It compares two strings from a specified start position This function returns: 0 &#8211; if the two strings are equal &lt;0 &#8211; if string1 (from startpos) is less than string2 &gt;0 &#8211; if string1 (from startpos) is greater than string2 If length is equal or greater than length of string1, this function returns FALSE Example &hellip; <a href=\"http:\/\/phpcodez.com\/substr_compare\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">substr_compare()<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25],"tags":[213,370,471],"class_list":["post-4116","post","type-post","status-publish","format-standard","hentry","category-php","tag-functions","tag-php","tag-string"],"_links":{"self":[{"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/posts\/4116","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/comments?post=4116"}],"version-history":[{"count":0,"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/posts\/4116\/revisions"}],"wp:attachment":[{"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/media?parent=4116"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/categories?post=4116"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/phpcodez.com\/wp-json\/wp\/v2\/tags?post=4116"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}