Re: Find match of string if only at end of string

From: Date: Wed, 11 Jul 2012 16:45:47 +0000
Subject: Re: Find match of string if only at end of string
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-318425@lists.php.net to get a copy of this message
Answered it myself (funny how writing out a problem as descriptively as possible makes the brain work better). $end_of_url = substr("http://domain.com/about/page/subpage/", strlen("/about/page/") * -1); $same_post = ($end_of_url == "/about/page/");

« previous php.general (#318425) next »