Image behind the post’s title

The image you are referring to is set via your themes style.css file and not via the WordPress admin or in your theme options. You can find the file here: http://promisingcoins.com/wp-content/themes/structural/style.css Here is the CSS that is used for this section (line #1305): .breadcrumb { background: url(images/breadcrumb.png); position: relative; text-align: center; padding: 60px 0px; margin-top: … Read more

$_GET parametters not working in an specific template

WordPress is removing all unknown (not registered) $_GET parameters while processing the request (same is true for $_POST). You can either register the custom variable, or just go the canonical PHP way by using filter_input(). This will access the original, unchanged GET parameters. If you are using filter_input(), you have to hook into pre_get_posts to … Read more

Automatically set post_parent value

You can do that easily using save_post hook like so: function set_post_parent_on_save($post_id) { // If this is just a revision, don’t do anything if ( wp_is_post_revision( $post_id ) ) return; // Check if it is a post if ( ‘post’ == get_post_type( $post_id ) ) { // unhook this function so it doesn’t loop infinitely … Read more

How to create a page that shows the last 10 posts?

By default WordPress displays your content in a blog format on the homepage. Using Default Static and Blog Page Settings in WordPress. WordPress comes with built-in support for creating a custom home page (static front page), and a separate page for blog posts. To use this method, you need to create two new WordPress pages. … Read more

Output Post with ACF Fields into other Post

To not duplicate code you could make a file in your theme/child-theme for the html of the post which you intend to embed, let’s say x_cpt_render_html.php: function get_x_cpt_html(){ ?> <div class=”x-cpt”> <h2> <?php the_title(); ?> </h2> <div class=”content”> <?php the_content(); ?></div> <div class=”custom”> <?php the_field(‘custom’); ?> </div> </div><?php } Then you could embed this file … Read more