Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Khurram Muslim
Khurram Muslim
12,391 Points

How to have a video placeholder and contact form on homepage

I want to do something like this on homepage of my website http://www.switchvideo.com/ (basically I want to have a video placeholder along with contact form on my homepage)

and my website is which I'm working on is http://instanteureka.com/

could any one tell me how I achieve this any idea about that would be highly appreciated!

and most importantly I'm working on wordpress theme

4 Answers

The way I would do it is with custom fields. Since you use WordPress, I would recommend downloading a plugin called 'Advanced Custom Fields'. You can create new fields, and assign them to a page, or specific template in your theme etc. You can create a lot of types of fields with this plugin, editors, input fields etc. The fields can be very easily added to a template by using a small piece of PHP, which you find in the documentation of the plugin.

Same for the form. The best way is to use a plugin for this. 'Contact form 7' or 'Gravity forms'. Those are some of the most popular form plugins out there. With the custom fields plugin, you can create a field and assign it to the right page or template. You can then add the shortcode for the contact form inside the custom field and you're all set.

Of course it requires some HTML and CSS work to position and style the blocks to your needs.

Let me know if that helps you.

Khurram Muslim
Khurram Muslim
12,391 Points

I've just installed bridge wordpress theme so I may able to do it via advanced custom field plugin? do check http://instanteureka.com/

That theme looks nice. Although, you might want to check first if the theme has any specific settings, that might do the job for you. Perhaps that way you won't need a plugin.

Khurram Muslim
Khurram Muslim
12,391 Points

Thank you for the input!

I think I need a plugin as theme has slider on homepage but not have any related settings which I want to do