This piece of core code inside header_required.php makes no sense...or does it?
Permalink
I was looking around inside header_required just now and saw this piece of code near the top...
It is possible that I am not seeing something here but that code makes no sense.
It's the same as writing...
But that makes absolutely no sense to me.
How can $pageTitle be assigned to $pageTitle if there is no value inside $pageTitle to begin with?
Would not the same thing be accomplished by simply saying...
Am I understanding this correctly?
Just want to make sure I am not missing anything here. Like some global "magical" thing of C5 having a value inside some global $pageTitle that is being made local in the code above or some such code "magic". I don't know.
Carlos
$pageTitle = (!$pageTitle) ? $c->getCollectionName() : $pageTitle;
It is possible that I am not seeing something here but that code makes no sense.
It's the same as writing...
if (!$pageTitle) { $pageTitle = $c->getCollectionName(); } else { $pageTitle = $pageTitle; }
But that makes absolutely no sense to me.
How can $pageTitle be assigned to $pageTitle if there is no value inside $pageTitle to begin with?
Would not the same thing be accomplished by simply saying...
$pageTitle = $c->getCollectionName();
Am I understanding this correctly?
Just want to make sure I am not missing anything here. Like some global "magical" thing of C5 having a value inside some global $pageTitle that is being made local in the code above or some such code "magic". I don't know.
Carlos