if (isset($type)) { $title[] = JString::ucwords(JText::_('COM_EASYSOCIAL_SH404_PHOTOS_TYPE_' . strtoupper($type))); if (isset($uid)) { if ($type == SOCIAL_TYPE_USER) { $alias = getUserAlias($uid); } if ($type == SOCIAL_TYPE_GROUP) { $alias = getGroupAlias($uid); } if ($type == SOCIAL_TYPE_EVENT) { $alias = getEventAlias($uid); } $title[] = $alias; shRemoveFromGETVarsList('uid'); } shRemoveFromGETVarsList('type'); } // For photos, we need to get the beautiful title if (isset($id)) { $photo = FD::table('Photo'); $photo->load((int) $id); // Remove known extensions from title $extensions = array('jpg', 'png', 'gif'); $fragment = JFilterOutput::stringURLSafe(JString::str_ireplace($extensions, '', $photo->title)); $fragment = uniqueUrl($title, $id . '-' . $fragment); if (isset($layout)) { addLayout($title, $view, $layout); } $title[] = $fragment; shRemoveFromGETVarsList('id'); }
* other free or open source software licenses. * See COPYRIGHT.php for copyright notices and details. */ defined('_JEXEC') or die('Unauthorized Access'); // Determine how is the user's current id being set. if (isset($userid)) { $title[] = getUserAlias($userid); shRemoveFromGETVarsList('userid'); } // Add the view to the list of titles if (isset($view)) { addView($title, $view); } // For photos, we need to get the beautiful title if (isset($id)) { $photo = FD::table('Photo'); $photo->load((int) $id); // Remove known extensions from title $extensions = array('jpg', 'png', 'gif'); $fragment = JFilterOutput::stringURLSafe(JString::str_ireplace($extensions, '', $photo->title)); $fragment = uniqueUrl($title, $fragment); $title[] = $fragment; shRemoveFromGETVarsList('id'); if (isset($layout)) { if ($layout == 'download') { // To enable user to download the photo $title[] = $layout; } shRemoveFromGETVarsList('layout'); } }