我所做的是通过为joomla 1.7安装mod来绕过joomla 3.0一切正常但是当我尝试仅为注册用户制作mod时,由于某些原因它无法获得jomsocial用户....
这是php代码
关于可能出错的任何想法?
$user =& JFactory::getUser();
if($user->guest != true)
if($envolveUseRealNames == 'real')
$fullname = $user->name;
$spacepos = strpos($fullname, ' ');
if($spacepos != false)
$env_firstname = substr($fullname, 0, $spacepos);
$env_lastname = substr($fullname, $spacepos + 1);
$env_firstname = $fullname;
$env_lastname = null;
else
$env_firstname = $user->username;
$env_lastname = null;
$env_profileImg = null;
$env_isAdmin = $user->authorize('com_content', 'edit', 'content', 'all');
echo(envapi_get_html_for_reg_user($envolveAPIKey, $env_firstname, $env_lastname, $env_profileImg, $env_isAdmin, NULL));
else
if($envolveWhichUsers == 'all')
echo envapi_get_code_for_anon_user($envolveAPIKey);
答案 0 :(得分:4)
正如@Elin所提及的那样Potential backward compatibility issues in Joomla 3.0 and Joomla Platform 12.1: