I have to learn about OOP chaining:
$data = new myclass;
$data->sub_function()->main_function();
But now I want to code it looks like this:
$data = new myclass;
$main = $data->main_function();
$sub = $main->sub_function();
If so how would write the class functions for this?
Please help me!