Fork me on GitHub






Recherche Plug-ins Smartpartner pour Rssfit
Supporter Xoops
Inscrit: 10/08/2004 15:15
De Tours
Messages: 573
Bonjour,

Je recherche le plug-ins Smartpartner pour rssfit. Celui qui est dans le module de rssfit ne fonctionne pas et aucune trace sur les sites pour le trouver.

Didier

Posté le : 25/03/2007 15:18
Partager Twitter Partagez cette article sur GG+
Re: Recherche Plug-ins Smartpartner pour Rssfit
Supporter Xoops
Inscrit: 09/01/2005 13:37
De Breizh
Messages: 16972
Bonjour,

Je n'ai que celui-ci :
<?php
// $Id: rssfit.smartpartner.php 244 2006-07-20 08:41:42Z tuff $
###############################################################################
##                RSSFit - Extendable XML news feed generator                ##
##                Copyright (c) 2004 - 2006 NS Tai (aka tuff)                ##
##                       <http://www.brandycoke.com/> & ... nbsp;   ##
###############################################################################
##                    XOOPS - PHP Content Management System                  ##
##                       Copyright (c) 2000 XOOPS.org                        ##
##                          <http://www.xoops.org/>   ... nbsp;   ##
###############################################################################
##  This program is free software; you can redistribute it and/or modify     ##
##  it under the terms of the GNU General Public License as published by     ##
##  the Free Software Foundation; either version 2 of the License, or        ##
##  (at your option) any later version.                                      ##
##                                                                           ##
##  You may not change or alter any portion of this comment or credits       ##
##  of supporting developers from this source code or any supporting         ##
##  source code which is considered copyrighted (c) material of the          ##
##  original comment or credit authors.                                      ##
##                                                                           ##
##  This program is distributed in the hope that it will be useful,          ##
##  but WITHOUT ANY WARRANTY; without even the implied warranty of           ##
##  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            ##
##  GNU General Public License for more details.                             ##
##                                                                           ##
##  You should have received a copy of the GNU General Public License        ##
##  along with this program; if not, write to the Free Software              ##
##  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA ##
###############################################################################
/*
* About this RSSFit plug-in
* Author: tuff <http://www.brandycoke.com/>
* Requirements:
* Requirements (Tested with):
*  Module: SmartPartner <http://www.smartfactory.ca/>
*  Version: 1.02
*  RSSFit verision: 1.2 / 1.5
*  XOOPS version: 2.0.13.2 / 2.2.3
*/

if( !defined('RSSFIT_ROOT_PATH') ){ exit(); }
class 
RssfitSmartpartner{
    var 
$dirname 'smartpartner';
    var 
$modname;
    var 
$grab;
    
    function 
RssfitSmartpartner(){
    }
    
    function 
loadModule(){
        
$mod =& $GLOBALS['module_handler']->getByDirname($this->dirname);
        if( !
$mod || !$mod->getVar('isactive') ){
            return 
false;
        }
        
$this->modname $mod->getVar('name');
        return 
$mod;
    }
    
    function &
grabEntries(&$obj){
        
$ret false;
        include 
XOOPS_ROOT_PATH."/modules/smartpartner/include/common.php";
        
$partners =& $partner_handler->getPartners($this->grab0_SPARTNER_STATUS_ACTIVE'weight''DESC');
        if( 
false != $partners && count($partners) > ){
            for( 
$i=0$i<count($partners); $i++ ){
                
$ret[$i]['link'] = $ret[$i]['guid'] = SMARTPARTNER_URL.'partner.php?id='.$partners[$i]->getVar('id');
                
$ret[$i]['title'] = $partners[$i]->getVar('title''n');
                
$ret[$i]['description'] = $partners[$i]->getVar('summary');
                
$ret[$i]['category'] = $this->modname;
                
$ret[$i]['domain'] = XOOPS_URL.'/modules/'.$this->dirname.'/';
            }
        }
        return 
$ret;
    }
}
?>


A +

Posté le : 25/03/2007 19:56

La connaissance s'accroît quand on la partage ...
Partager Twitter Partagez cette article sur GG+
Re: Recherche Plug-ins Smartpartner pour Rssfit
Supporter Xoops
Inscrit: 10/08/2004 15:15
De Tours
Messages: 573
Merci Kris,

C'est le même que celui que j'avais et qui ne fonctionne pas.

Didier

Posté le : 26/03/2007 15:11
Partager Twitter Partagez cette article sur GG+
Re: Recherche Plug-ins Smartpartner pour Rssfit
Régulier
Inscrit: 09/03/2004 09:12
Messages: 106
Salut,

De la même façon, je serai également intéressé par ce plugin compatible pour smartpartner 2.0. J'ai fait plusieurs tentatives de modification du code sans succès.

A noter qu'il semble fonctionner sur le site de DuGris :
http://www.dugris.info/modules/rss/rss.php?feed=smartpartner

Voici ce que j'ai voulu mettre en place, mais il y a toujours un truc qui cloche, mais je sais pas quoi...:

<?php
if( !defined('RSSFIT_ROOT_PATH') ){ exit(); }
class 
RssfitSmartpartner{
    var 
$dirname 'smartpartner';
    var 
$modname;
    var 
$grab;
    
    function 
RssfitSmartpartner(){
    }
    
    function 
loadModule(){
        
$mod =& $GLOBALS['module_handler']->getByDirname($this->dirname);
        if( !
$mod || !$mod->getVar('isactive') ){
            return 
false;
        }
        
$this->modname $mod->getVar('name');
        return 
$mod;
    }
    
        function &
grabEntries(&$obj){
        
$ret false;
        @include_once(
XOOPS_ROOT_PATH."/modules/smartpartner/include/functions.php");
        
$partner_handler =& smartpartner_gethandler('partner');
        
$partners $partner_handler->getPartners($this->grab0);
        if( 
false != $partners && count($partners) > ){
            for( 
$i=0$i<count($partners); $i++ ){
                
$ret[$i]['link'] = $ret[$i]['guid'] = XOOPS_URL.'/modules/smartpartner/partner.php?id='.$partners[$i]->getVar('id');
                
$ret[$i]['title'] = $partners[$i]->getVar('title''n');
                
$ret[$i]['description'] = $partners[$i]->getVar('summary');
                
$ret[$i]['category'] = $this->modname;
                
$ret[$i]['domain'] = XOOPS_URL.'/modules/'.$this->dirname.'/';
            }
        }
        return 
$ret;
    }
}
?>


Si quelqu'un peut jeter un oeil et me donner un avis,
Merci beaucoup d'avance !
machenzy

Posté le : 04/04/2008 02:36

Open in new window
Partager Twitter Partagez cette article sur GG+
Re: Recherche Plug-ins Smartpartner pour Rssfit
Régulier
Inscrit: 09/03/2004 09:12
Messages: 106
En fait, j'ai changé de méthode
Voici quelque chose qui fonctionne :
<?php
// $Id: rssfit.wfdownloads.php 72 2005-11-12 05:09:33Z tuff $
###############################################################################
##                RSSFit - Extendable XML news feed generator                ##
##                   Copyright (c) 2004 NS Tai (aka tuff)                    ##
##                       <http://www.brandycoke.com/> & ... nbsp;   ##
###############################################################################
##                    XOOPS - PHP Content Management System                  ##
##                       Copyright (c) 2000 XOOPS.org                        ##
##                          <http://www.xoops.org/>   ... nbsp;   ##
###############################################################################
##  This program is free software; you can redistribute it and/or modify     ##
##  it under the terms of the GNU General Public License as published by     ##
##  the Free Software Foundation; either version 2 of the License, or        ##
##  (at your option) any later version.                                      ##
##                                                                           ##
##  You may not change or alter any portion of this comment or credits       ##
##  of supporting developers from this source code or any supporting         ##
##  source code which is considered copyrighted (c) material of the          ##
##  original comment or credit authors.                                      ##
##                                                                           ##
##  This program is distributed in the hope that it will be useful,          ##
##  but WITHOUT ANY WARRANTY; without even the implied warranty of           ##
##  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            ##
##  GNU General Public License for more details.                             ##
##                                                                           ##
##  You should have received a copy of the GNU General Public License        ##
##  along with this program; if not, write to the Free Software              ##
##  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA ##
###############################################################################
/*
* About this RSSFit plug-in
* Author: machenzy <http://www.applis-portables.net/>
* Requirements (Tested with):
*  Module: SmartPartner <http://http://www.smartfactory.ca/>
*  Version: 2.0 rc1
*  RSSFit verision: 1.21
*  XOOPS version: 2.0.17 / 2.2.3
*/

if( !defined('RSSFIT_ROOT_PATH') ){ exit(); }
class 
Rssfitsmartpartner extends XoopsObject{
    var 
$dirname 'smartpartner';
    var 
$modname;
    var 
$module;
    var 
$grab;
    
    function 
Rssfitsmartpartner(){
    }
    
    function 
loadModule(){
        
$mod =& $GLOBALS['module_handler']->getByDirname($this->dirname);
        if( !
$mod || !$mod->getVar('isactive') ){
            return 
false;
        }
        
$this->modname $mod->getVar('name');
        
$this->module =& $mod;
        return 
$mod;
    }
    
    function &
grabEntries(&$obj){
        global 
$xoopsDB;
        
$myts =& MyTextSanitizer::getInstance();
        
$perm_handler =& xoops_gethandler('groupperm');
        
$ret false;
        
$i 0;
        
$sql "SELECT id, title, last_update, summary, status FROM ".$xoopsDB->prefix("smartpartner_partner")." WHERE status = 2 ORDER BY last_update DESC";
        
$result $xoopsDB->query($sql$this->grab0);
        while( 
$row $xoopsDB->fetchArray($result) ){
                
$ret[$i]['title'] = $row['title'];
                
$link XOOPS_URL.'/modules/'.$this->dirname.'/partner.php?id='.$row['id'];
                
$ret[$i]['link'] = $ret[$i]['guid'] = $link;
                
$ret[$i]['timestamp'] = $row['last_update'];
                
$ret[$i]['description'] = $myts->displayTarea($row['summary']);
                
$ret[$i]['category'] = $this->modname;
                
$ret[$i]['domain'] = XOOPS_URL.'/modules/'.$this->dirname.'/';
                
$i++;
                }
        return 
$ret;
    }
}
?>


voili voilou

Posté le : 08/04/2008 18:29

Open in new window
Partager Twitter Partagez cette article sur GG+

 Haut   Précédent   Suivant



Vous pouvez voir les sujets.
Vous ne pouvez pas débuter de nouveaux sujets.
Vous ne pouvez pas répondre aux contributions.
Vous ne pouvez pas éditer vos contributions.
Vous ne pouvez pas effacez vos contributions.
Vous ne pouvez pas ajouter de nouveaux sondages.
Vous ne pouvez pas voter en sondage.
Vous ne pouvez pas attacher des fichiers à vos contributions.
Vous ne pouvez pas poster sans approbation.

Propulsé avec XOOPS | Graphisme adapté par Tatane, Grosdunord, Montuy337513

54 Personne(s) en ligne (39 Personne(s) connectée(s) sur Forum) | Utilisateur(s): 0 | Invité(s): 54 | Plus ...