e107inc / e107

e107 Bootstrap CMS (Content Management System) v2 with PHP, MySQL, HTML5, jQuery and Twitter Bootstrap. Issue Discussion Room: https://gitter.im/e107inc/e107
https://e107.org
GNU General Public License v3.0
322 stars 214 forks source link

e_userprofile.php needs updating to v2 standards #756

Closed Moc closed 10 years ago

Moc commented 10 years ago

Recently I found the e_userprofile.php functionality in the code, allowing for plugin developers to enter data into the userprofile. This functionality was added by Lisa back in 2007 and probably requires updating to the new v2 standards (class, globals, etc.). More info: http://wiki.e107.org/index.php?title=Embedding_Into_Userprofile

This is the current way it is used.

if(!function_exists('e_userprofile_pluginname')){
   function e_userprofile_pluginname(){

      $text = "Text for this field";
      $caption = "Field name";

      //either return a one level array of caption and text
      return array('caption'=>$caption, 'text'=>$text);

      //or return a multi level array with an array of captions and an array of texts
      /*
      return array('caption'=>array('caption1', 'caption2'),
                     'text'=>array('text1', 'text2')
                     );
      */
   }
}

It actually still works :)

CaMer0n commented 10 years ago

Working on this..

CaMer0n commented 10 years ago

Deprecated and replaced with e_user.php with v2 standards.