The 5th annual nopCommerce conference will take place in India on the 10th-11th of October. Please find more about this event here

Second contact form

< 1 2
Posted: June 20, 2012 at 10:09 AM Quote #72297
Russ,

Thanks for the guidance.  
However, I would like to know, How did you add additional fields to the forms ?! I want to add multiple fields I.e. drop down, checkboxes radio buttons and couple of text boxes.

Please advise.

Thanks,
Elisha
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: June 20, 2012 at 10:27 AM Quote #72298
NopCommerce is now built using the MVC model (something I've had to try and teach myself about).

So you need to modify


Firstly the view contains the form elements, this is where you lay out the extra fields.

Then you need the model to also contain these fields.

The validator also gets extended to handle the extra fields.


So that's the front end. Next up it needs to be sent through to you so extend the controller to handle the extra fields and format your email as you want it.

The files are all listed in the post above that need changing. Have a go :)
This post/answer is useful
1
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: June 21, 2012 at 2:52 AM Quote #72337
Russ,

Thanks for ur guidance I did the changes and it worked for me. J

now what I want to do is to store new fields on database!! I suppose you must have done these type of work. Can you please guide me on this as well.

Thanks again J,

Elisha Cornelius
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: June 21, 2012 at 4:40 AM Quote #72343
I have only had the form email me, not store anything to the database. I imagine though you need to modify ContactUsSend in the CommonController.cs file.

I have tried figuring it out myself now, but got a bit lost. My idea would be to see how a newsletter subscription is added, as this must work with the database. The controller is NewsletterController.cs, which deals with Nop.Services.Messages.NewsLetterSubscriptionService.cs. This uses class of NesLetterSubscription defined in Nop.Core.Domain.Messages.NewsLetterSubscription.cs. Other than that I'm a bit lost at the moment, sorry.

Maybe someone else can help, or there is another thread on this forum about adding to the database.

Good luck
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: February 20, 2014 at 11:18 PM Quote #116802
HI ,

I am new to Nopcommerece, i am working on v2.60 in that i want to develop one request a catalog form same as contactus form but add some more fields
i followed same as contactus page ( for that i created one requestsend view, requestsend Model, common controller and validation, routeprovider ) after that build application and debug that it's working fine when every click to send button at that time through error
[Unable to cast object of type 'Nop.Web.Models.Common.RequestModel' to type 'Nop.Web.Models.Common.ContactUsModel'.]

how can i overcome that error, if anyone help me..

Thanks,
Venkat.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Thanks,
Venkat Goud,
https://venkatb4me.wordpress.com/
Posted: March 03, 2015 at 10:55 PM Quote #141008
venkatgoud wrote:
HI ,

I am new to Nopcommerece, i am working on v2.60 in that i want to develop one request a catalog form same as contactus form but add some more fields
i followed same as contactus page ( for that i created one requestsend view, requestsend Model, common controller and validation, routeprovider ) after that build application and debug that it's working fine when every click to send button at that time through error
[Unable to cast object of type 'Nop.Web.Models.Common.RequestModel' to type 'Nop.Web.Models.Common.ContactUsModel'.]

how can i overcome that error, if anyone help me..

Thanks,
Venkat.




Hi Do you get any solution about this problem . i also face same issue please help me.

Thanks,
Mukesh
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: March 04, 2015 at 2:40 AM Quote #141016
Hi Mukesh,

Once check with standered applications
C:...\...\Presentation\Nop.Web\Views\Catalog\ProductRequestQuote.cshtml . how to flow the productrequestquote page like that can you create new contactus page.

Thanks,
Venkat Goud.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Thanks,
Venkat Goud,
https://venkatb4me.wordpress.com/
Posted: April 16, 2015 at 1:58 AM Quote #143564
i developed one website using nopcommerce V3.50 but i have one issue.

how to make another contact us form in nopcommerce v3.50 and this view show in footer because i want to display contact us form in whole pages in Footer section

Thanks,
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
--
Regards
SAGAR PATEL
Posted: July 11, 2019 at 9:08 PM Quote #242442
Hi,
To make the 2nd form you can refer to this Plugin. It is quite useful

https://www.nopcommerce.com/p/1713/dynamic-form-nopcommerce-plugin-contact-form-nopcommerce.aspx

Thanks!
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Plugin Dynamic Form for nopCommerce (Plugin Contact Form Nopcommerce): http://nopplugin.com/dynamic-form-nopcommerce

Nopcommerce Amp Plugin: http://nopplugin.com/google-accelerated-mobile-for-nopcommerce

Nopcommerce Multi Tenant: http://nopplugin.com/nopcommerce-multi-tenant-download
< 1 2
Premium support services
  • Dedicated premium support services provided by core developers are intended for persons who run mission critical websites, work on projects with tight deadlines, or want to get dedicated support.
Professional services
  • Want to open a new store? Want to take your store to the next level? Need a custom extension? We can customize nopCommerce to fit your store perfectly. Request a quote to get started.