I will try to show this by an example:
class DogShelter
{
private $dog;
public function handleDogDirect( )
{
$this->dog = trim( $this->dog );
$this->dog = rtrim( $this->dog, 'abc' );
$this->dog = strtolower( $this->dog );
$this->dog = basename( $this->dog );
}
public function handleDogIndirect( )
{
$dog = $this->dog;
$dog = trim( $dog );
$dog = rtrim( $dog, 'abc' );
$dog = strtolower( $dog );
$dog = basename( $dog );
$this->dog = $dog;
}
}
Which is the better function in different cases - handleDogDirect
or handleDogIndirect
?
- Why?
- Which one is probably faster?
- Which one should I use?
By the way:
Since the rep recalc, I can't login with my OpenID from wordpress anymore. It keeps saying No OpenID endpoint found.
. I would really appreciate any help.