So I'm learning PHP, well I'm learning more complex standards of php as per phpfox. An issue I'm having is with a few lines of code - I get what they 'do'. But I don't understand why they are structured that way. Could someone explain?
In the following line of code the if statements are cornered by {} and not in the usual:
if thing('condition') {
do stuff
}
Way that i'm familiar with. Why is this?
{if Phpfox::isUser() && !PHPFOX_IS_AJAX && $sCustomViewType === null}
{if (Phpfox::getUserBy('profile_page_id') > 0 && defined('PHPFOX_IS_USER_PROFILE'))
|| (isset($aFeedCallback.disable_share) && $aFeedCallback.disable_share)
|| (defined('PHPFOX_IS_USER_PROFILE') && !Phpfox::getService('user.privacy')->hasAccess('' . $aUser.user_id . '', 'feed.share_on_wall'))
|| (defined('PHPFOX_IS_USER_PROFILE') && !Phpfox::getUserParam('profile.can_post_comment_on_profile'))
}
{else}
Also what is the :: thing about? and when I see (not in this) a | by itself, what is that doing?
Thanks very much for any help :)