I have 6 files, and two of them do not seem to want to play well. I keep getting a "Cannot redeclare class" error.
** edit **
I know its these 2 files, because when i comment out the include for login.php, the error goes away.
**end edit**
The full error:
Fatal error: Cannot redeclare class Base in coreBase.php on line 7
Base.php
Code: <?php
/**
* Base.php is the base class for all functions.
*
*/
class Base {
function __construct() {
include("Admin.php");
include("Feed.php");
include("Login.php");
include("Session.php");
include("SQLManager.php");
include("Twitter.php");
}
function __destruct() {
}
}
?>
Login.php
Code: <?php
/**
* Login.php is the class for all Application login functions.
*
*/
class Login extends Base {
function __construct() {
}
function Login() {
}
function Logout() {
}
function __destruct() {
}
}
?>
All of the files that are included in the Base __construct, extend Base.
Anyone have any ideas?
Odd or Even
Inside of a while loop I need to echo several rows of info...easy enough.In the loop (for the sake off css) I need to distinguish between odd and even row numbers.Code:
Wierd echo error?
Hi, i got the most wierd php error ever and i don't know why..Code: echo "<td><strong>MP:</strong></td>"; echo
I would like "for" to wait 5 sec
I would like my 'for' loop to wait 5 sec before second iteration.for ($i=0; $i<10; $i++){........//I would like it to wait 5 seconds here}
I need an iframe that calls up a different page according to the date
hiI don't know any php (only html) and I urgently need to do the following: I need an iframe that calls up a different page according to the date e.g. on the 2th Dec a page called 'special2.php',
Do something every fifth time?
I'm trying to write a loop, but I want it to do something different after every fifth instance. Like, I want it do something like this:Quoteecho $a1;echo $a2;echo $a3;echo $a4;echo $a5.$b;echo $a6;And
More pug propaganda.
http://www.youtube.com/watch?v=8Kkrmubsgf8The commercial is definitely worth watching pug awesomeness.I'm sure none of you have seen it as it recently came out (About 4 months ago). Pugs can surf,
script is pulling more then they have....
I have this script for my game where they can change there race. This will cost them 2,500 points. However in our database points are called crystals. If the person has 500 points, and the script
mysql UPDATE request not working and driving me crazy!!!
Hi,I have been stuck on this for ages.Quite simply I am trying to update my database with an update command:Code: $query="UPDATE `spence13_Portfolio`.`skillsList` SET `skillName` =
Take info from one coloum and move to another
Hi all,I have this:Code: [Select]$array = "SELECT stock_id FROM stocks WHERE stock_id BETWEEN '1' and '5' ";$res = mysql_query($array);$count = 0;while ($row = mysql_fetch_assoc($res)){ if
Most basic form question ever?
Hello,I want to use this snippet to make sure the fields in a form are ok before processing it.Code: <FORM method="post">To:<input type="text"