Jump to content

contact form to cms page


Recommended Posts

Hi!

 

I would be very thankful, if somebody could help me.

The situation is following - I can't figure out, how to insert/import default contact form (from contact) into the cms page with my contact information. I want to put that contact form under my contact details.

The shop will be in 3 languages, so adding my text to contact-form.tpl will not help, because I don't know how to translate it there.

 

Any suggestions?

Link to comment
Share on other sites

You can translate anything you put into a tpl. Look for a structure similar to the following in the tpl file:

 

{l s='some string to translate'}

 

The first char is a lowercase L, and s stands for the string to be translated. Once this structure is in place, you can translate it like any other translatable string using Back Office > Tools > Translations > Front Office Translations > relevant language > relevant section (contact-form in your case)

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...

You can translate anything you put into a tpl. Look for a structure similar to the following in the tpl file:

 

{l s='some string to translate'}

 

The first char is a lowercase L, and s stands for the string to be translated. Once this structure is in place, you can translate it like any other translatable string using Back Office > Tools > Translations > Front Office Translations > relevant language > relevant section (contact-form in your case)

 

 

Big thanks!

Link to comment
Share on other sites

  • 3 months later...

Can anybody help me please? I am interested by the first part of MrrD question:

how to insert/import default contact form (from contact) into the cms page

So, "ContactControllerCore extends FrontController", therefore in case of adding

ControllerFactory::getController('ContactController')->run();

to cmscontroller.php i get full contact-form page on my cms page.

How can i do this?

Link to comment
Share on other sites

  • 2 weeks later...

How can i do this?

add

ControllerFactory::getController('ContactController')->preProcess();
ControllerFactory::getController('ContactController')->setMedia();
ControllerFactory::getController('ContactController')->process();
ControllerFactory::getController('ContactController')->displayContent();

instead of ControllerFactory::getController('ContactController')->run();

Link to comment
Share on other sites

You can translate anything you put into a tpl. Look for a structure similar to the following in the tpl file:

{l s='some string to translate'}

The first char is a lowercase L, and s stands for the string to be translated. Once this structure is in place, you can translate it like any other translatable string using Back Office > Tools > Translations > Front Office Translations > relevant language > relevant section (contact-form in your case)

Thanks for explanations but how to do when you want to add html in these strings ? as it doesn't accept them :(

 

Thanks,

 

Vincèn

Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...