1
Hi everyone!
I have a question... I want to create php block with XOOPS user variables, but it works only with html :( and only with one system template block called system_block_user.html. There I can put <{$xoops_uname}> and as result I'll have user name. That's ok. But if I make php block, there is only one variable working - {X_SITEURL}, and no like {X_UNAME}! That's bad.
I tryed to recode /class/xoopsblock.php with something like this
elseif ( $c_type == 'P' ) {
ob_start();
echo eval($this->getVar('content', 'N'));
$content = ob_get_contents();
ob_end_clean();
return str_replace('{X_SITEURL}', XOOPS_URL.'/', $content);
to
elseif ( $c_type == 'P' ) {
ob_start();
echo eval($this->getVar('content', 'N'));
$content = ob_get_contents();
ob_end_clean();
return str_replace('{X_SITEURL}', $user->getVar("uname"), $content);
and many others
but nothing happened :(
Plz anybody tell me how to make this thing..
TNX!