now this is quite difficult to phrase or to find for me, as I am still new at wordpress and I would like to do something that I suppose is a bit more complicating. Basically I have an area in my theme with 3 possible templates. When you create a page you can choose if that area should have: 1 Box 2 Boxes 3 Boxes

Now in those boxes should be information. Now the question: How do I get dynamic content into those boxes AFTER the client chose which template he would like to use for his post.

It is very important for me that you understand that I am not looking for "Template Name" in the PHP file so that you can choose the template for a specific page.

I want to have dynamic content for pages in a particular template that needs to be customized from page to page.

I hope that somebody has an answer to that.

Thank you very much in advance.

Best wishes Richard


1 Answer 1


I think I understand what you're talking about. You would like to allow users to choose the amount of columns to be used for the page/post they are creating. You want to use different template files to achieve the different template layouts.

There are two ways of doing this. One is to use different template files as you mentioned and setting up a short-code to surround the different blocks in the post/page editor.

The other way which I believe is the best route is to use args to tweak the output of the content. SitePoint has a pretty easy to follow article explaining this method. If you're interested here is the article: http://www.sitepoint.com/split-wordpress-content-into-multiple-sections/

The only problem I've encountered using the methods above are explaining to users how they work. The content that will eventually gets displayed in one, two, or three columns all gets added using a single text editor which is a one column editor. At first it seems to give users trouble, but they catch on quickly.

An option that I've not mentioned, but you might want to look into would be using Advanced Custom Fields to separate the content into blocks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.