Reply to Re: include files with similar contents

Your name:

Reply:


Posted by Gunnar G on 02/06/07 09:55

Kimmo Laine wrote:

> "Gunnar G" <debian@comhem.se> wrote in message
> news:LmXxh.31301$E02.12903@newsb.telia.net...
>> ... but moving the include line to this
>>
>> class a
>> {
>> include("page.php");
>> function foo($x){return $x+1;}
>> }
>>
>> class b
>> {
>> function foo($x){return $x+1;}
>> }
>>
>> and it no longer works.
>
>
> I'm guessing page.php defines another function named foo. In this case,
> just take the extra foo from class a and throw it out the window. If you
> include it from page.php, you don't need top redefine it... doi!
Well, in this case page.php had only 6 characters in it

<?php ?>

so there should'nt be any problem.Very strange.

[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

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