Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Form Questions /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

display the contact us form in sidebar using jquery


Go to End


2 Posts   1833 Views

Avatar
dipe

Community Member, 1 Post

2 September 2013 at 11:49pm

Hello I am preety new to solver stripes i want to show a contact us form in side bar like http://allpaksolutions.com/productlist.php have on instant quote please tell me how do i perform this in silver stripes any help will be highly appreciated .thanks in advance

Avatar
cSGermany

Community Member, 37 Posts

3 September 2013 at 12:12am

Hi,

if you're using userforms you can put this function in your page controller

	function ShowForm(){ 
		$get = DataObject::get_one('UserDefinedForm'); 
		return new UserDefinedForm_Controller($get); 
   }

and than call the form with this in the template

	<% control ShowForm %>
		$Form
	<% end_control %>