最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

php - How to Insert an advert banner for every third Slide using JS Composer Slider

programmeradmin1浏览0评论

Hi I am working on my website and I want to ADD an ADVERT BANNER for every THIRD Post-Slider.

I have previously used this code in a loop but it doesn't work the same for a SLIDER - Here is the Code I used previously on another website:

  if (in_category(37)) { 
    $post_counter++;
    if ($post_counter == 1 || $post_counter == 3) {

 ?>

Let me know if you have any ideas...

Hi I am working on my website and I want to ADD an ADVERT BANNER for every THIRD Post-Slider.

I have previously used this code in a loop but it doesn't work the same for a SLIDER - Here is the Code I used previously on another website:

  if (in_category(37)) { 
    $post_counter++;
    if ($post_counter == 1 || $post_counter == 3) {

 ?>

Let me know if you have any ideas...

Share Improve this question edited Oct 25, 2019 at 16:53 Aqeem Jones asked Oct 24, 2019 at 9:55 Aqeem JonesAqeem Jones 13 bronze badges 3
  • What is happening with this code? Are you getting an ad after 1 and 3? You should post the entire loop code. You should include the image directly into your question and provide more details about what is happening, etc. To get every 3rd you should use if ($post_counter % 3 == 0) – RiddleMeThis Commented Oct 24, 2019 at 13:29
  • It’s fine this QUESTION has been resolved and fixed on my side. Thank you . Apparently I had to edit the APP.min.js file . And now I can run ADVERTS via the slider. – Aqeem Jones Commented Oct 25, 2019 at 16:50
  • Great. Can you post that as an answer and then accept the answer so this question will be marked completed? – RiddleMeThis Commented Oct 25, 2019 at 18:34
Add a comment  | 

1 Answer 1

Reset to default 0

Thanks! Yes I edited the APP.min.JS file in order to show custom adverts on the Jcomposer Page builder...

发布评论

评论列表(0)

  1. 暂无评论