Reply to Re: Problem with Include (newb question)

Your name:

Reply:


Posted by Philluminati on 11/07/07 15:12

On Nov 7, 2:53 pm, Philluminati <Phillip.Ross.Tay...@gmail.com> wrote:
> I'm new to PHP and I'm having problems trying to get this include
> statement to work. Can anyone help me?
>
> This is the error I get:
>
> Warning: include() [function.include]: Failed opening '' for inclusion
> (include_path='.:/php/includes') in /home/ptaylor/public_html/am_web/
> model/classes/customer.php on line 3
>
> This is the contents of the customer.php file:
>
> <?php
>
> include(realpath('../interfaces/tableobject.php')); #<---
> THIS IS LINE 3, WHERE THE ERR IS REPORTED
>
> class Customer implements TableObject
> {
> public $Id;
> public $Name;
> public $Comments;
> public $Deleted;
>
> public $Children; #Children are Regions
> public $Rights;
>
> #Customer Constructor.
> public function __construct($id)
> {
>
> parent::__construct();
>
> $this->Id = $id;
> }
>
> public function GetTableName()
> {
> return "customer";
> }
>
> public function GetTableId()
> {
> return $this->Id;
> }
>
> public function GetChildren()
> {
> return $this->Children;
> }
>
> public function GetRights()
> {
> return $this->Rights;
> }
>
> public function GetTreeText()
> {
> return $this->Name;
> }
>
> }
>
> ?>
>
> The file is DEFINETELY 100% in that location. If I do cd ../
> interfaces/ there is a file there called tableobject.php
>
> the contents of that file is this:
>
> <?php
>
> #Represents an object that lives in the database.
>
> public interface TableObject
> {
> function GetTableName();
> function GetTableId();
> function GetChildren();
> function GetRights();
>
> }
>
> ?>
>
> Can anyone help? Is the include statement in the wrong place?
>
> Phill

Don't worry fixed it :-)

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация