CoreFiles by mySites.guru
mod_unread.php30 lines, 1,250 bytes, from Joomla_1.0.12-Stable-Full_Package.zip
Raw History Compare with 1.0.11
md5
8637e325ab5a6b2e8f7f950bff372af7
sha1
133a3ea60579ce6138541a337fe1fcc6735c8e1d
sha256
0ed18004c6990625290565de121886cb804bce9e96a8640e3f6c607705e1bb1d
<?php
/**
* @version $Id: mod_unread.php 5026 2006-09-13 18:45:52Z friesengeist $
* @package Joomla
* @copyright Copyright (C) 2005 Open Source Matters. All rights reserved.
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/

// no direct access
defined( '_VALID_MOS' ) or die( 'Restricted access' );

$query = "SELECT COUNT(*)"
. "\n FROM #__messages"
. "\n WHERE state = 0"
. "\n AND user_id_to = " . (int) $my->id
;
$database->setQuery( $query );
$unread = $database->loadResult();

if ($unread) {
	echo "<a href=\"index2.php?option=com_messages\" style=\"color: red; text-decoration: none;  font-weight: bold\">$unread <img src=\"images/mail.png\" align=\"middle\" border=\"0\" alt=\"Mail\" /></a>";
} else {
	echo "<a href=\"index2.php?option=com_messages\" style=\"color: black; text-decoration: none;\">$unread <img src=\"images/nomail.png\" align=\"middle\" border=\"0\" alt=\"Mail\" /></a>";
}
?>

No other release has this exact content. See every version of this file.