Page 1 sur 1

Aide sur construire d'un fichier

Posté : 21 mars 2015, 19:02
par Nath
J'ai ce code :
<?php
class Product extends ProductCore
{
    public $Recettes;
    public function __construct($id_product = null, $full = false, $id_lang = null, $id_shop = null, Context $context = null)
    {
      Product::$definition['fields']['Recettes'] = array('type' => self::TYPE_HTML, 'lang' => true, 'validate' => 'isString');
      parent::__construct($id_product, $full, $id_lang, $id_shop, $context);
    }
}
?>
et je souhaite y ajouter dans le fichier :
public $Conseils Nutritionnel;
    public function __construct($id_product = null, $full = false, $id_lang = null, $id_shop = null, Context $context = null)
    {
      Product::$definition['fields']['Conseils Nutritionnel'] = array('type' => self::TYPE_HTML, 'lang' => true, 'validate' => 'isString');
      parent::__construct($id_product, $full, $id_lang, $id_shop, $context);
Comment insérer ce code après le 1er ?
Que je le mets à la suite, ça me plante mon site.

Merci d'avance pour votre aide.