MyXoops Forum

Headline News Publisher [Module für Forenlösungen] - myXOOPS German Support

Bleekk

Co-Administrator
Gepostet am:27.09.2014 10:25
Bleekk
Bleekk Offline (Show more)
Co-Administrator
Posts: 1504
Since: 16.12.2002
#2

Aw: Headline News Publisher

Vielen Dank, schaut super aus!

efkan

"myXOOPs"-Neuling
Gepostet am:26.09.2014 14:03
efkan
efkan Offline (Show more)
"myXOOPs"-Neuling
Posts: 20
Since: 31.12.2010
#1

Headline News Publisher

Skaliertes Bild
theme.html Code :
<link href="<{xoImgUrl css/mansetx.css}>" type="text/css" rel="stylesheet" />  
 [!
SCRIPT FILTERED!] 
 [!
SCRIPT FILTERED!]
theme.html add :
<{includeq file="$theme_name/slidetpublisher.html"}>
slidetpublisher.html code :
<{php}>
include_once 
XOOPS_ROOT_PATH '/modules/publisher/include/common.php';
$publisher =& PublisherPublisher::getInstance();
$myts =& MyTextSanitizer::getInstance();
$itemsObj $publisher->getHandler('item')->getItems($limit 6$start 0, array(_PUBLISHER_STATUS_PUBLISHED), -1$sort 'datesub'$order='DESC'''true$criteria nulltrue);
$totalItems count($itemsObj);

global 
$items;
$items = array();
if (
$itemsObj) {
    for ( 
$i 0$i $totalItems$i++ ) {

      
$newItems['itemid']       = $itemsObj[$i]->itemid();
      
$newItems['title']        = $itemsObj[$i]->title();
     
$newItems['body']         = $itemsObj[$i]->body();
      
$newItems['votes']        = $itemsObj[$i]->votes();
     
$newItems['image']        = XOOPS_URL '/uploads/blank.gif';
            
$images $itemsObj[$i]->getImages();
            if (
is_object($images['main'])) {
                
$newItems['image'] = XOOPS_URL '/uploads/' $images['main']->getVar('image_name');
            }
        
$items[] = $newItems;
  }
}
<{/
php}>
    <
div id="mansetx">
      <{
php}>
        foreach ( 
$GLOBALS['items'] as $myrow )
        {
        
$GLOBALS['xoopsTpl']->assign('itemid'$myrow['itemid']);
        
$GLOBALS['xoopsTpl']->assign('title'$myrow['title']);
        
$GLOBALS['xoopsTpl']->assign('body'$myrow['body']);
        
$GLOBALS['xoopsTpl']->assign('votes'$myrow['votes']);
        
$GLOBALS['xoopsTpl']->assign('image'$myrow['image']);
<{/
php}>
    <
div id="mansetx-img">
      <
a href="<{$xoops_url}>/modules/publisher/item.php?itemid=<{$itemid}>"><img width="720" height="315" src="<{$image}>"></a>
    </
div>
     <{
php}>
        }
<{/
php}> 
    <
div id="mansetx-selector">
     <
ul>
      </
ul>
   </
div>
</
div>
Demo : http://estetikameliyatmerkezi.com/xoopson/ Hasta Yataklar?
Diesen Thread durchsuchen:  1 Anonyme Benutzer