hi …
i have php object … and it’s contain many methods … and i did some thing to decrease size of object php file … i wrote contentes inside each method into another seperate files at class style to each method … amd inside every main method … i include it’s method class file and define it
example for object before :
class aa{
function __construct()
{
}
// method a
public function a()
{
echo "a";
}
// method b
public function b()
{
echo "b";
}
}
example for object after:
class aa{
function __construct()
{
}
// method a
public function a()
{
require_once("a.php");
$_a = new a()
$_a->method();
}
// method b
public function b()
{
require_once("b.php");
$_b = new b()
$_b->method();
}
}
and for a.php file :
class a{
public function method()
{
echo "a";
}
}
and b.php file :
class b{
public function method()
{
echo "b";
}
}
my question:
is my method don’t make any problem with perofrmance and speed ? because by this idea i decrease main object file size when i include it in any other page …?