Custom Post Types using wrong template (index) instead of archive-{type}.php – previously worked as expected

The issue was, in fact, the new taxonomy using “year” clashes with the query. WordPress was accepting year=about-us in the query chain for instance, as year was a taxonomy, before the expected page=about-us – preventing it from appearing as a page and using the index.php template as there is no “year” template. I changed year … Read more

Divi Template A Few Questions

Divi will not be able to support all of the features as you’ve stated out of the box. With integration of things such as WooCommerce which Divi prefers you use, you’ll be able to incorporate features like the quote but probably not on the product comparisons. That being said, DIVI is a very powerful theme, … Read more

Create a shortcode to display the “the_content ()” in my post [closed]

Here is an example of a shortcode that renders post content based on the id and type attribute. [post type=”content” id=”2″] [post type=”title” id=”2″] If you want to render from a template you would use: echo do_shortcode ( ‘[post type=”content” id=”294″]’ ); echo do_shortcode ( ‘[post type=”title” id=”294″]’ ); And here is the actual shortcode … Read more

html blog template to wordpress template

That is a much bigger topic than can be addressed here. Please take a look at the WordPress Codex entry on Theme Development Generally speaking, you break the HTML into a header, footer, and content area. The header goes into header.php, the footer goes into footer.php and the content area goes into index.php or another, … Read more

Template library for WordPress [closed]

Let’s address possibility for starters. There are two parts to front end output in WordPress: Theme template system, which is pretty flexible and relatively easy to adjust, although mostly PHP-centric Template tags (and related) functions, which are extremely PHP–centric and vary wildly as to how easy they are to adjust So implementing templating engine in … Read more

Creating mixture of shortcodes to use in the visual/text editor

I suggest to just append the other things to the content without editing the templates add_filter(‘the_content’,’hang_my_specific_things_on_the_content’); function hang_my_specific_things_on_the_content($content) { // shortcode0 is appended before content $content = do_shortcode(‘[shortcode0]’).$content; // these are appended after the content $content .= do_shortcode(‘[shortcode1]’); $content .= ‘<img src=”https://wordpress.stackexchange.com/questions/312880/someimage.png” />’; $content .= do_shortcode(‘[shortcode2]’); return $content; }