i have a php code :
class Test {
function someThing(){ return 1}
}
$test = new Test();
//why this isnt printing bla bla bla 1 ????
echo "bla bla bla $test->someThing()";
but it seems like i cant call function inside a double quoted string
how can i do this ?
thanks
you can only call variables inside a string
but if you use {} you can add code to the block
try this :
echo "bla bla bla {$test->someThing()}";