Q:

Protected functions in PHP

This may seem pretty simple and I am sure it is, I am just not getting it. 
I understand that protected properties in a class in PHP can only be accessed within the class itself and inherited classes.   Here is my code so far:
class q {

    public $publicQ = "This is a public property";
    protected $protectedQ = "This is a proected property";

    public function displayProtected() {

        echo $this->protectedQ;

    }

}

$q = new q;
echo $q->publicQ; #prints "This is a public property"
echo $q->protectedQ; #nothing
$q->displayProtected();

I have read the documentation, looked at other answers on SO and the concept just is not clicking with me.   What do protected properties actually do, why would we use them and why is my example not working? 

A:

Think of your public properties and methods as an API you expose to the outside world and private/protected ones as "inner workings" of your class that the outside world not only shouldn't be concerend with but shouldn't be able to mess with either. 
Here comes the obligatory bad car analogy:
The methods you'd expose in a Car class could be driveForward() and driveBackwards().  Both of them would make use of a method called transmitTheDriveToTheWheels() but it shouldn't concern the car's users and shouldn't be accessed by them, so you'd "hide" it by making it private. 
Your car would have an engine property.  You definitely don't want someone to be able to replace the engine with a cute little kitty by going $car->engine = $kitty; so you'd make the engine private as well. 
Finally, your car would have a mileage property.  You want the user to be able to read the mileage but not to be able to modify it.  So you make the mileage private and expose a public getMileage() method. 
Now whether you want to use private or protected to encapsulate the "inner" stuff of your class, depends on whether you expect the class to be extended or not.