Support Forum

Every time that you post a problem, PLEASE add the Joomla and the extension's versions and revisions (for example: Joomla 3.3.6, Contact Enhanced 3.3.5), PHP version and Server's Operating System. If you only manage only one site it is easier if you edit your profile and just add that information to your signature. Don't forget to add a detailed description of the problem. If possible, write down all steps to simulate the problem.

Before submitting a new post, PLEASE make sure you are running the latest version, test in different browsers (IE, FF, Chrome,..) and clear Joomla and browser's cache after every change you make.

Also, most questions are already answered in our FAQ and in iFAQ and Contact Enhanced documentation pages.

× Contact Enhanced is a contact component manager created to replace Joomla! core contacts component and add lots of advantages and new features (see Features ) and it offers many plugins and modules for several different purposes,
Product page | Documentation Page

Field recognition with Mijoshop

8 years 6 months ago #20419 by waitz
Our users register with a mijoshop component ( www.beta.humaniversity.com/register-account )
If they send in the contact form while being logged in ( www.beta.humaniversity.com/contact ) the contact form's First Name field (type=name) populates it with both first and family name from the mijoshop registration fields.

Is there a way I can make an link between Mijoshop's first name field and CE's first name field, and Mijoshop's family name field with CE's family name field?

Thanks

Kristian Rajan | Joomla! 3.7.5 | Contact Enhanced 3.8.2

Please Log in or Create an account to join the conversation.

8 years 6 months ago #20422 by support
Dear Rajan,

Contact Enhanced gets the Name from the Joomla User's database table. What can be done is something different.
  1. Change the Form Field type for the Name and surname (last name) fields to PHP form field type;
  2. Set aliases to: name and surname;
  3. In the name field add the following code:
    $namearray = explode(' ', $user->get('name'));
    $firstName = (!empty($namearray[0]) ? $namearray[0] : '');
    $html = '<input 
    	 type="text" 
    	 id="'.$cf->alias.'" 
    	 name="'.$cf->alias.'" 
    	 value="'.$firstName.'" 
    	 class="inputbox '.($cf->required ? 'required' : '').'" />';
  4. In the surname field add the following code:
    $namearray = explode(' ', $user->get('name'));
    $firstName = (!empty($namearray[0]) ? end($namearray) : '');
    $html = '<input 
    	 type="text" 
    	 id="'.$cf->alias.'" 
    	 name="'.$cf->alias.'" 
    	 value="'.$firstName.'" 
    	 class="inputbox '.($cf->required ? 'required' : '').'" />';

It should solve the problem. ;-)

All the best,

Please Log in or Create an account to join the conversation.

6 years 6 months ago #23665 by waitz
Dear Douglas

It really took some time before I managed to get around to do this, but I just did and it worked perfectly :-)

Is there a way to also do the same with the address fields:
Alias: address1
Alias: address2
Alias: city
Alias: zipcode
Alias: state
Alias: country

Thanks, Rajan

Kristian Rajan | Joomla! 3.7.5 | Contact Enhanced 3.8.2

Please Log in or Create an account to join the conversation.

6 years 6 months ago #23666 by waitz
PS: The placeholder text is of course not visible in the field type PHP. Any way to make the placeholder text visible?

Kristian Rajan | Joomla! 3.7.5 | Contact Enhanced 3.8.2
Attachments:

Please Log in or Create an account to join the conversation.

6 years 6 months ago #23667 by support
Dear Kristian,

1. MijoShop: Where is the data saved? If it is saved in the MijoShop database tables you'll have to retrieve this information on each PHP Form Field type and populate the field. If you don't know how to accomplish that we can do it for you. Please submit the Support -> Contact Form for a customization quote.

2. Placeholder: Add the code below right after <input in order to add the Field name as placeholder:
placeholder="'.$cf->name.'"

Best regards,

Please Log in or Create an account to join the conversation.

6 years 6 months ago #23672 by waitz
Thanks Douglas. I will check with Miwisoft first where the data is stored.

All the best, Rajan

Kristian Rajan | Joomla! 3.7.5 | Contact Enhanced 3.8.2

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum

Copyright © 2018 IdealExtensions.com. All Rights Reserved.

This site is not affiliated with or endorsed by the Joomla!™ Project. It is not supported or warranted by the Joomla!™ Project or Open Source Matters™. The Joomla!™ logo is used under a limited license granted by Open Source Matters™, the trademark holder in the United States and other countries.
We may collect your IP address and your browser's User Agent string while using our site for security reasons and deriving aggregate information (analytics). This information is retained for a minimum of 1 and a maximum of 24 months.
Feedback