Server : LiteSpeed System : Linux server 3.10.0-1160.90.1.el7.x86_64 #1 SMP Thu May 4 15:21:22 UTC 2023 x86_64 User : alsaif ( 1057) PHP Version : 7.4.33 Disable Function : show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname Directory : /home/alsaif/domains/alsaif.group/public_html/templates/startsik/html/mod_minifrontpage/ |
<?php
/**
* @package Joomla.Site
* @subpackage mod_minifrontpage
*
* @copyright Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*
* @subpackage mod_minifrontpage
* @author TemplatePlazza
* @link http://www.templateplazza.com
*/
defined('_JEXEC') or die;
$theme_overlay = $params->get('theme_overlay');
$doc->addStyleSheet(JURI::base(true).'/modules/mod_minifrontpage/tmpl/default/grid.min.css?v='.$static_files_version);
/* Skin */
$doc->addStyleSheet(JURI::base(true).'/modules/mod_minifrontpage/tmpl/default/skin/'.$theme_overlay->overlay_skin.'.css?v='.$static_files_version);
// General params
$count = $params->get('count');
$show_date = $theme_overlay->show_date;
$date_format = $theme_overlay->date_format;
if($date_format == "custom_date_format") {
$date_format = $theme_overlay->custom_date_format;
}
/* Theme Settings */
$overlay_num_column = $theme_overlay->overlay_num_column;
$overlay_show_author = $theme_overlay->overlay_show_author;
$overlay_show_cat = $theme_overlay->overlay_show_cat;
$overlay_thumbnail_position = $theme_overlay->overlay_thumbnail_position;
$overlay_show_more = $theme_overlay->overlay_show_more;
if($overlay_show_more == 1) {
$overlay_more_item_count = $theme_overlay->overlay_more_item_count;
}else {
$overlay_more_item_count = $params->get('count');
}
$overlay_skin = str_replace('.min', '', $theme_overlay->overlay_skin);
$overlay_cat_pos = $theme_overlay->overlay_cat_pos;
$overlay_cat_pos_align = $theme_overlay->overlay_cat_pos_align;
if(($overlay_cat_pos == "1") && ($overlay_thumbnail_position == "top")){
$doc->addStyleDeclaration("
.mfp_mid_".$module->id." .mfp_cat a {position: absolute;top:0;".$overlay_cat_pos_align.": 0;z-index: 9999;background: #222;padding: 5px 8px;line-height:1!important;text-decoration:none;color:#fff!important;}.mfp_mid_".$module->id." .mfp_overlay_item:hover .mfp_cat a {background:#cc0000;}");
}
?>
<div class="mfp_overlay_skin_<?php echo $overlay_skin;?> mfp_mid_<?php echo $module->id;?>">
<div class="mfp-grid">
<?php
$n = 1;
$moreitem = "";
foreach ($list as $item) :
// Get the thumbnail
$thumb_img = MinifrontpageHelper::getThumbnail($item->id, $item->images,$thumb_folder,$show_overlay_thumb,$custom_overlay_thumb,$thumb_width,$thumb_height,$item->title,$item->introtext,$module->id);
// Item count check for showing More Articles Block
if($n <= $overlay_more_item_count){
?>
<div class="mfp-col-xs-12 mfp-col-sm-6 mfp-col-md-<?php echo 12/$overlay_num_column;?> mfp_overlay_item">
<div>
<?php
// Show Thumbnail - Position before title
if(($overlay_thumbnail_position == "top")||($overlay_thumbnail_position == "left") || ($overlay_thumbnail_position == "right")) { ?>
<a href="<?php echo $item->link; ?>" class="mfp_thumb_pos_<?php echo $overlay_thumbnail_position; ?>" itemprop="url"><?php echo $thumb_img[0]; ?></a>
<?php } ?>
<?php
// Show Article Category
if($overlay_show_cat){
echo "<span class='mfp_cat'><a href=".JRoute::_('index.php?option=com_content&view=category&id='.$item->catid).">".$item->category_title."</a></span>";
}
?>
<h4 class="mfp_overlay_title">
<a href="<?php echo $item->link; ?>" itemprop="url">
<?php echo JHtmlString::truncate(strip_tags($item->title), $title_truncate); ?>
</a>
</h4>
<?php
// Show Author
if($overlay_show_author){
echo "<span class='mfp_author'>".$item->author."</span>";
}
?>
<?php
// Show Date
if($show_date) {
if($overlay_show_author) {
echo "- ";
}
echo "<span class='mfp_date'>".JHtml::_('date',($params->get('ordering') == "m_dsc")?$item->modified:$item->created, JText::_($date_format))."</span>";
}
?>
<?php if($show_intro != 0){ ?>
<p class="mfp_introtext">
<?php
// Show Thumbnail - Position before introtext
if(($overlay_thumbnail_position == "top2")||($overlay_thumbnail_position == "left2") || ($overlay_thumbnail_position == "right2")) { ?>
<a href="<?php echo $item->link; ?>" class="mfp_thumb_pos_<?php echo $overlay_thumbnail_position; ?>" itemprop="url"><?php echo $thumb_img[0]; ?></a>
<?php } ?>
<?php
echo JHtmlString::truncate(strip_tags($item->introtext), $introtext_truncate); ?>
</p>
<?php } ?>
</div>
</div>
<?php } else {
$moreitem .= '<li><a href="'.$item->link.'" itemprop="url">'.JHtmlString::truncate(strip_tags($item->title), $title_truncate).'</a><span class="mfp_date">'.JHtml::_('date',($params->get('ordering') == "m_dsc")?$item->modified:$item->created, JText::_($date_format)).'</span></li>';
}
$n++;
endforeach; ?>
<?php
if($overlay_show_more == 1) {
$grid_width = (((ceil(($count - ($count - $overlay_more_item_count))/$overlay_num_column)) * $overlay_num_column) - $overlay_more_item_count) * (12/$overlay_num_column);
if($grid_width == 0) {
$grid_width = 12;
}
$row2 = (ceil(($count - ($count - $overlay_more_item_count))/$overlay_num_column)) * $overlay_num_column;
if($moreitem != "") {?>
<div class="mfp-col-xs-12 mfp-col-sm-6 mfp-col-md-<?php echo $grid_width;?> mfp_overlay_item mfp_overlay_more_articles">
<div>
<h5><?php echo JText::_('MOD_MFP_THM_overlay_MORE_ARTICLES'); ?></h5>
<ul><?php echo $moreitem; ?></ul>
</div>
</div>
<?php
}
} ?>
</div>
</div>