In article <Pine.BSF.4.10.10201302054330.27254-100000@localhost>,
 [EMAIL PROTECTED] (Philip Olson) wrote:

> > <?
> > include("file1");
> > function_somename();
> > include("file2");
> > function_somename();
> > ?>
> > 
> > file1 and contain a function definition, but the function in both files had 
> > the same name. This will give "Cannot redeclare ....". So can i unset the 
> > function before the second include?

> > This sounds like a job for include_once
> > 
> >   www.php.net/include_once

No, this isn't a case of function being re-declared when the same file gets 
included a second time, it's two separate files declaring two separate 
functions which happen to have the same name.

Give the functions unique names.

-- 
CC

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to