You have bookmarked items
Jump To:
Viewing Topic "Add custom fields to "contact business" form"

4 Item(s)     Sort:  Newest Oldest

per page
 
  Post
Posted By: Richard Hardin
Total Posts: 4
Joined Date: Sep 6, 2019

I want to add some extra fields to the contact business form such as phone #, best time to reach you, and a couple other things.  I would like to know the proper directory in order to alter the code for this form.  Any help would be appreciated.

Posted : Sep 6, 2019
Posted By: George Bara
Total Posts: 1417
Joined Date: Jun 17, 2013

Hi,

 

You would need to modify the contact form in the views/companies/tmpl/listing_utils.php, modify the email template and also add the new fields on the database.

Posted : Sep 6, 2019
Posted By: Richard Hardin
Total Posts: 4
Joined Date: Sep 6, 2019

Thanks for the reply!

I was in the right directory, but I don't think of would of thought to look in that file.

I was able to get the form modified and get new fields in the correct database table, but I'm having an issue finding where the data is being sent to for the email template. I did find the EmailService class, but I'm confused with where it's grabbing the template from. Also, the action on the form goes to JRoute::_('index.php?option=com_jbusinessdirectory'). Where is the data actually getting parsed at?

I really appreciate the help!

Posted : Sep 6, 2019
Posted By: Richard Hardin
Total Posts: 4
Joined Date: Sep 6, 2019

Hello,

 

Ok, I didn't realize that the email templates were configurable on the backend, so that's awesome.  The two things I need to know, however.  First is, what are the correct placeholders to use in the email templates?  It doesn't appear to be any of the names in the form, so how are those placeholders generated? Second is where is the data sent to after that form submission so I can get the data from the new new form fields to go into the database.

Thanks!

Posted : Sep 6, 2019

4 Item(s)     Sort:  Newest Oldest

per page
 

Viewing Topic "Add custom fields to "contact business" form"


      You have bookmarked items
Jump To:

Who is online

 
Users browsing this topic 1 logged customers:: 0 and guest 1 (based on users active over the past 5 minutes)