1. dnaservizio
  2. Features Request
  3. Saturday, April 11 2020, 06:11 PM
I've made a new form that must be filled in by the user during the first registration phase. I've created it with a "new group" and then a "new field", it's a 5-choice "drop down field" style field.
In addition, I've already created 5 template styles (and the related 5 menus).
Now I would like to connect, one by one, all of the 5 template styles to te related one of the 5 choices.
I can't find a way to make it happen, but i'm sure it's possible, can you please tell me how?
THK you Max
Attachments (4)
admin Accepted Answer
Admin
Hi and sorry for late reply, from your screenshots you seems to use Italian language. We are Italians developers, so if you prefer you can use this language.

Anyway...unfortunately this is not possible natively with Easy Profile, but there is a simple way to make it.

You can override Easy Profile profile page to make a redirect to correct profile menu item id:
- Copy file from /components/com_jsn/views/profile/tmpl/default.php at /templates/your-template-folder/html/com_jsn/profile/default.php (This is the Joomla override feature, with this you will not loss changes when you upgrade Easy Profile in future)
- In the new file at line 27 add following code:
$currentMenuID = JFactory::getApplication()->input->get('Itemid');

if($currentMenuID != 123 && $this->user->I_am_a=="0") JFactory::getApplication()->redirect(JRoute::_('index.php?option=com_jsn&view=profile&id='.$this->user->id.'Itemid=123'));

if($currentMenuID != 124 && $this->user->I_am_a=="1") JFactory::getApplication()->redirect(JRoute::_('index.php?option=com_jsn&view=profile&id='.$this->user->id.'Itemid=124'));

if($currentMenuID != 125 && $this->user->I_am_a=="2") JFactory::getApplication()->redirect(JRoute::_('index.php?option=com_jsn&view=profile&id='.$this->user->id.'Itemid=125'));

if($currentMenuID != 126 && $this->user->I_am_a=="3") JFactory::getApplication()->redirect(JRoute::_('index.php?option=com_jsn&view=profile&id='.$this->user->id.'Itemid=126'));

if($currentMenuID != 127 && $this->user->I_am_a=="4") JFactory::getApplication()->redirect(JRoute::_('index.php?option=com_jsn&view=profile&id='.$this->user->id.'Itemid=127'));
NOTE: Replace 123...127 with the ID of the specific menu items
  1. more than a month ago
  2. Features Request
  3. # 1
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.