Closed

Write a php function for child-theme in Wordpress

The task is to create a php function in the [url removed, login to view] field of the child-theme of a Wordpress theme.

The function must randomly insert a banner/google-ad/item between the posts on the home page or category pages.

Suggested hours this project should take: 1hour

Please download the theme at github below:

[url removed, login to view]

The following solution has been suggested but did not work - insert into [url removed, login to view] file of child-theme:

function insert_between_posts( $post ) {

global $wp_query;

// Check if we're in the right template

if ( ! is_home() )

return;

// Check if we're in the main loop

if ( $wp_query->post != $post )

return;

// Check if we're at the right position

if ( 1 != $wp_query->current_post )

return;

// Display the banner

echo '<div>Some banner</div>';

}

add_action( 'the_post', 'insert_between_posts' );

Skills: CSS, HTML, Javascript, PHP, WordPress

See more: https://github.com/googlesamples/android-UniversalMusicPlayer, https://github.com/officedev/ews-managed-api, https www freelancer com mobile app deep link php url https www freelancer com projects articles write some articles 10896803 ut, child themes need to have a template header in the style.css stylesheet., wordpress child theme tutorial, child theme not working, child theme functions.php example, wordpress child theme plugin, what is a child theme vs parent theme, how to create child theme in wordpress step by step, wordpress grandchild theme, wordpress, https europafreelancer com index php, http 178.89 110.222 game game_v451 php api_url https api vk com api php&amp api_id 3579245&amp api_settings 258&amp viewer_id 20, developers facebook com home php refsrc https 3a 2f 2fm facebook com 2f&soft bookmarks, m facebook com login php next https 3a 2f 2fm facebook com 2freg 2fcreate 2f&refsrc https 3a 2f 2fm facebook com 2freg 2fcreate, https outsource com index php, https m facebook com l php u https s3 eu west 1 amazonaws com guzelsin 404 html vvzffy7gfzxk23suruxnvcmabfs1zpllbld, https b4thewedding com index php project allproject, content www facebook com plugins likebox php href https 3a 2f 2fwww facebook com 2fplaygaana&width 300&height 590&colorscheme li

About the Employer:
( 8 reviews ) Cape Town, South Africa

Project ID: #15726397

17 freelancers are bidding on average R933 for this job

bhaskarmandal

Hi, I am 5 years experienced web developer expert in Wordpress. Relevant Skills and Experience Please check my some wordpress Project : =========================== 1 ) [login to view URL] 2 ) [login to view URL] More

R1088 ZAR in 3 days
(91 Reviews)
6.1
R777 ZAR in 3 days
(66 Reviews)
5.5
ambientinfotech

I have read job requirement carefully, please share project detail we will done this job on time, Thanks Relevant Skills and Experience Skills : Wordpress/Magento/Linux/Css/HTML Proposed Milestones R1088 ZAR - Task c More

R1088 ZAR in 3 days
(70 Reviews)
5.3
NeegrumDev

Look, your project is simple. I'm sure a lot of the bidders can do it. So why should you choose me? Simple: time and price. I can start working right away, and my price is way lower than the avg bid. Relevant Skills a More

R800 ZAR in 2 days
(28 Reviews)
5.2
skchybd

I can do it Relevant Skills and Experience I have 11 years experience on wp Proposed Milestones R666.67 ZAR - ok

R666 ZAR in 3 days
(35 Reviews)
4.8
mangaram1975

Dear Hiring manager,I have been in the web industry for the last 5 years Relevant Skills and Experience Wordpress : [login to view URL] [login to view URL] [login to view URL] http://take-a More

R1088 ZAR in 3 days
(25 Reviews)
4.5
R260 ZAR in 2 days
(42 Reviews)
4.5
R555 ZAR in 0 days
(59 Reviews)
4.6
techviawebs

A proposal has not yet been provided

R1777 ZAR in 5 days
(2 Reviews)
3.5
informationcmn

I am Professional web Developer and Mobile App Developer. I am more Confident in my work. I am expert in Wordprss, Bootstrap & Responsive, HTML 5,CSS, PHP and Java script Languages. Relevant Skills and Experience See More

R1333 ZAR in 3 days
(4 Reviews)
2.9
hungvotan

with 10 years experience in Wordpress, PHP, Woocommerce, SEO. I can help you finish projects which you probose. Please give me skype address. we can communicate each other easily. Relevant Skills and Experience with 1 More

R1666 ZAR in 3 days
(7 Reviews)
2.9
mayankinnovative

A proposal has not yet been provided

R210 ZAR in 10 days
(25 Reviews)
2.7
R1222 ZAR in 3 days
(3 Reviews)
1.9
Mannan1024

Dear Sir, I feel fit for your project. I have good skills of CSS, HTML, Javascript, PHP, WordPress I have 5 years experiences on those field in industry level. Relevant Skills and Experience CSS, HTML, Javascript, PHP More

R1088 ZAR in 3 days
(0 Reviews)
0.0
R1088 ZAR in 3 days
(0 Reviews)
0.0
harendrachohan

A proposal has not yet been provided

R715 ZAR in 6 days
(0 Reviews)
0.0
jamesbasumataryx

I don't necessarily need money from you, i'm just looking for reviews. Please consider my bid. I will complete the work right now. Thanks Relevant Skills and Experience PHP WORDPRESS PHYTON Proposed Milestones R444 Z More

R444 ZAR in 3 days
(0 Reviews)
0.0