1
rgauci
error when Default Template is set to clone
  • 2009/10/27 7:39

  • rgauci

  • Not too shy to talk

  • Posts: 173

  • Since: 2007/8/31


In Templates I have cloned XOOPS Default Template and renamed it but a blank screen comes up with the following error:

Fatal error: Cannot redeclare XoopsImagesetimg::imgset_refid() in /home/gistudio/public_html/kernel/imagesetimg.php on line 65

Any clues please????

2
ghia
Re: error when Default Template is set to clone
  • 2009/10/27 9:43

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


Oops, seems some unfinished business in /kernel/imagesetimg.php
/**
 * XOOPS Image Sets Image
 *
 * @package     kernel
 * @author      Kazumi Ono  <onokazu@xoops.org>
 * @copyright   (c) 2000-2003 The XOOPS Project - www.xoops.org
 */
class XoopsImagesetimg extends XoopsObject
{
    
/**
     * Constructor
     */
    
function XoopsImagesetimg()
    {
        
$this->XoopsObject();
        
$this->initVar('imgsetimg_id'XOBJ_DTYPE_INTnullfalse);
        
$this->initVar('imgsetimg_file'XOBJ_DTYPE_OTHERnullfalse);
        
$this->initVar('imgsetimg_body'XOBJ_DTYPE_SOURCEnullfalse);
        
$this->initVar('imgsetimg_imgset'XOBJ_DTYPE_INTnullfalse);
    }

    
/**
     * Returns Class Base Variable imgset_refid
     */
    
function id($format 'N')
    {
        return 
$this->getVar('imgset_refid'$format);
    }

    
/**
     * Returns Class Base Variable imgset_refid
     */
    
function imgset_refid($format '')
    {
        return 
$this->getVar('imgset_refid'$format);
    }

    
/**
     * Returns Class Base Variable imgset_refid
     */
    
function imgset_refid($format '')
    {
        return 
$this->getVar('imgset_refid'$format);
    }

    
/**
     * Returns Class Base Variable imgset_refid
     */
    
function imgset_refid($format '')
    {
        return 
$this->getVar('imgset_refid'$format);
    }

    
/**
     * Returns Class Base Variable imgset_refid
     */
    
function imgset_refid($format '')
    {
        return 
$this->getVar('imgset_refid'$format);
    }

}
Replace this class definition by:
/**
 * XOOPS Image Sets Image
 *
 * @package     kernel
 * @author      Kazumi Ono  <onokazu@xoops.org>
 * @copyright   (c) 2000-2003 The XOOPS Project - www.xoops.org
 */
class XoopsImagesetimg extends XoopsObject
{
    
/**
     * Constructor
     */
    
function XoopsImagesetimg()
    {
        
$this->XoopsObject();
        
$this->initVar('imgsetimg_id'XOBJ_DTYPE_INTnullfalse);
        
$this->initVar('imgsetimg_file'XOBJ_DTYPE_OTHERnullfalse);
        
$this->initVar('imgsetimg_body'XOBJ_DTYPE_SOURCEnullfalse);
        
$this->initVar('imgsetimg_imgset'XOBJ_DTYPE_INTnullfalse);
    }

    
/**
     * Returns Class Base Variable imgsetimg_id with default format N
     */
    
function id($format 'N')
    {
        return 
$this->getVar('imgsetimg_id'$format);
    }

    
/**
     * Returns Class Base Variable imgsetimg_id
     */
    
function imgsetimg_id($format '')
    {
        return 
$this->getVar('imgsetimg_id'$format);
    }

    
/**
     * Returns Class Base Variable imgsetimg_file
     */
    
function imgsetimg_file($format '')
    {
        return 
$this->getVar('imgsetimg_file'$format);
    }

    
/**
     * Returns Class Base Variable imgsetimg_body
     */
    
function imgsetimg_body($format '')
    {
        return 
$this->getVar('imgsetimg_body'$format);
    }

    
/**
     * Returns Class Base Variable imgsetimg_imgset
     */
    
function imgsetimg_imgset($format '')
    {
        return 
$this->getVar('imgsetimg_imgset'$format);
    }

}

3
Mamba
Re: error when Default Template is set to clone
  • 2009/10/27 10:25

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


Thanks Ghia. I've updated SVN, but feel free to do it yourself next time. I assume, you have access to SVN, right?

Login

Who's Online

263 user(s) are online (175 user(s) are browsing Support Forums)


Members: 0


Guests: 263


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits