Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/sorting/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Joomla 3.1向用户配置文件添加字段_Joomla_Joomla3.1 - Fatal编程技术网

Joomla 3.1向用户配置文件添加字段

Joomla 3.1向用户配置文件添加字段,joomla,joomla3.1,Joomla,Joomla3.1,我想向用户配置文件添加更多字段,例如图像URL。 我希望它能像这样工作: $user = JFactory::getUser(); echo "Your name is {$user->name}, your email is {$user->email}, and your username is {$user->username}"; 换句话说,我希望能够做到这一点: $profilepicture = $user->image; 这可能吗?它是如何实现的?您可

我想向用户配置文件添加更多字段,例如图像URL。 我希望它能像这样工作:

$user = JFactory::getUser();
echo "Your name is {$user->name}, your email is {$user->email}, and your username is 
{$user->username}";
换句话说,我希望能够做到这一点:

$profilepicture = $user->image;

这可能吗?它是如何实现的?

您可以通过克隆当前用户插件并向xml中添加所需的任何字段来创建自己的用户插件。或者,您可以在当前表单中添加另一个xml表单,但必须修改核心以告知何时使用字段。 或者只需将当前表单中的一个字段更改为媒体字段。

  • 是的,这是可能的
  • 它是按照教程完成的

您是想显示额外的字段供用户填写,还是已经完成了,只是想显示结果?@Lodder-我刚刚添加了额外的字段,现在显示结果有问题。