newbie LAC Posted May 17, 2019 Author Share Posted May 17, 2019 Hello, 6 hours ago, Sonya* said: Node? Yes. {{$show = true;}} {{if $item = \IPS\Output::i()->hiddenElements['nbenhadverts_item_item'] and ($item->mapped('pinned') or $item->mapped('featured'))}} {{$show = false;}} {{elseif $club = \IPS\Output::i()->hiddenElements['nbenhadverts_club'] and $club->featured}} {{$show = false;}} {{endif}} {{if $show}} Show advert everywhere except of pinned and featured items {{endif}} Sonya* 1 Link to comment
Sonya* Posted May 17, 2019 Share Posted May 17, 2019 Perfect! It is even valid for the featured club features, not only for the club's homepage. Link to comment
PCHelpforumBE Posted June 3, 2019 Share Posted June 3, 2019 Hi @newbie LAC I'm expirimenting with Google Automatic advertisement placing. For this i just would need 1 location inside the <head>tag I prefer not to edit my Theme directly. Can i create it with a custom location set by your mod? Link to comment
PCHelpforumBE Posted June 3, 2019 Share Posted June 3, 2019 Great 🙂 haha thanks 1 minute ago, Sonya* said: @KarelPCH Link to comment
newbie LAC Posted June 4, 2019 Author Share Posted June 4, 2019 Hello, 12 hours ago, KarelPCH said: Can i create it with a custom location set by your mod? The post above is correct Link to comment
sulervo Posted July 9, 2019 Share Posted July 9, 2019 (edited) Type of advertisement: Supply HTML Code Show the advertisement: Just below the page header HTML code: <script type="text/javascript"> if(window.innerWidth > 1019) { var forums = ["83", "84", "85", "86"]; var forum_id = request.id; if (forums.includes(forum_id) { // Desktop tag/code 1 } else { // Desktop tag/code 2 } } else { var forums = ["83", "84", "85", "86"]; var forum_id = request.id; if (forums.includes(forum_id)) { // Mobile tag/code 1 } else { // Mobile tag/code 2 } } </script> There is JavaScript in the field of HTML code.. not even know if it's working but it's the best I can make. 1. The first "if" = Desktop or mobile. 2. The second "if" = Two tags available and the forum id defines which one is in use. Now I don't know how to get "request.id" so do you have an idea how to solve this? Maybe Extra Condition field would work better? @newbie LAC Fixed version: <script type="text/javascript"> if(window.innerWidth > 1019) { var forums = [83, 84, 85, 86]; var forum_id = {expression="(request.app == 'forums' and request.module == 'forums'and request.controller == 'forums' and isset(request.id)) ? request.id : 0"}; if (forums.includes(forum_id)) { // Desktop tag/code 1 } else { // Desktop tag/code 2 } } else { var forums = [83, 84, 85, 86]; var forum_id = {expression="(request.app == 'forums' and request.module == 'forums'and request.controller == 'forums' and isset(request.id)) ? request.id : 0"}; if (forums.includes(forum_id)) { // Mobile tag/code 1 } else { // Mobile tag/code 2 } } </script> Edited July 16, 2019 by sulervo Link to comment
newbie LAC Posted July 10, 2019 Author Share Posted July 10, 2019 Hello, 12 hours ago, sulervo said: Now I don't know how to get "request.id" so do you have an idea how to solve this? Maybe Extra Condition field would work better? var forum_id = {expression="(request.app == 'forums' and request.module == 'forums'and request.controller == 'forums' and isset(request.id)) ? request.id : 0"}; sulervo 1 Link to comment
sulervo Posted July 16, 2019 Share Posted July 16, 2019 (edited) Do you know is it possible to get forum ID in topic view? @newbie LAC Edited July 16, 2019 by sulervo Link to comment
newbie LAC Posted July 16, 2019 Author Share Posted July 16, 2019 Hello, 1 minute ago, sulervo said: Do you know is it possible to get forum ID in topic view? @newbie LAC sulervo 1 Link to comment
sulervo Posted July 16, 2019 Share Posted July 16, 2019 How about JavaScript solution? Sorry I forgot told it. Thank you. Link to comment
newbie LAC Posted July 17, 2019 Author Share Posted July 17, 2019 (edited) Hello, 13 hours ago, sulervo said: How about JavaScript solution? Sorry I forgot told it. Thank you. // Topic view var forum_id = {expression="(request.app == 'forums' and request.module == 'forums'and request.controller == 'topic') ? \IPS\Output::i()->hiddenElements['nbenhadverts_node_id'] : 0"}; Edited July 17, 2019 by newbie LAC sulervo 1 Link to comment
jesuralem Posted September 1, 2019 Share Posted September 1, 2019 Just so you know, i have 2 ads in the sidebar with your app, and for some reason i wasn't able to edit or move any block in the sidebar, any move just would not be saved. I was able to do it disabling your app and re-enabling it once mu changes were made. Link to comment
newbie LAC Posted September 2, 2019 Author Share Posted September 2, 2019 Hello, 14 hours ago, jesuralem said: Just so you know, i have 2 ads in the sidebar with your app, and for some reason i wasn't able to edit or move any block in the sidebar, any move just would not be saved. I was able to do it disabling your app and re-enabling it once mu changes were made. I need more information to reproduce - Adverts settings - Widgets locations Link to comment
jesuralem Posted September 2, 2019 Share Posted September 2, 2019 Here is a screenshot, if i try to move (or remove) any widget in the sidebar, the move just isn't saved. I have 2 ads block (basic div) in the sidebar, both are configured like this : Link to comment
newbie LAC Posted September 2, 2019 Author Share Posted September 2, 2019 (edited) 58 minutes ago, jesuralem said: Here is a screenshot, if i try to move (or remove) any widget in the sidebar, the move just isn't saved. Thanks. I'll look into that Upd. Fixed for next release. Edited September 2, 2019 by newbie LAC Link to comment
jesuralem Posted September 2, 2019 Share Posted September 2, 2019 3 hours ago, newbie LAC said: Upd. Fixed for next release. Great, thanks for the quick answer. Link to comment
Chris027 Posted September 11, 2019 Share Posted September 11, 2019 This looks really nice, but there is one thing stopping me from moving from Google Ad Manager. I need the ability to automatically generate click and impression reports and have them sent to different emails addresses. Question: Is this possible with enhanced advertisements? Link to comment
newbie LAC Posted September 12, 2019 Author Share Posted September 12, 2019 Hello, 8 hours ago, Chris027 said: Question: Is this possible with enhanced advertisements? No Link to comment
Jirinex Posted September 20, 2019 Share Posted September 20, 2019 Does anyone know if I can use this plugin to put an add on a specific thread and only there? Link to comment
newbie LAC Posted September 20, 2019 Author Share Posted September 20, 2019 (edited) Hello, 4 minutes ago, Jirinex said: Does anyone know if I can use this plugin to put an add on a specific thread and only there? Yes using condition or css selector Edited September 20, 2019 by newbie LAC Link to comment
Nesa Posted October 1, 2019 Share Posted October 1, 2019 Hi @newbie LAC Just to make sure I understand correctly 🙂 I want on my Forum to add space for Google Adsense between posts in topic view. Every Topic, every page. For example, after every 7th and 15th post (I have 20 post per page in topic view). This application of yours can enable this? Link to comment
newbie LAC Posted October 2, 2019 Author Share Posted October 2, 2019 Hello, 7 hours ago, Nesa said: I want on my Forum to add space for Google Adsense between posts in topic view. Every Topic, every page. For example, after every 7th and 15th post (I have 20 post per page in topic view). This application of yours can enable this? Yes 7 hours ago, Nesa said: I want on my Forum to add space for Google Adsense between posts in topic view. Every Topic, every page. For example, after every 7th and 15th post (I have 20 post per page in topic view). You can also use Nesa 1 Link to comment
Nesa Posted October 2, 2019 Share Posted October 2, 2019 @newbie LAC Thanks a lot for advice. 👍I bought (NB40) Ads After X Posts, easily installed, set it up and everything works fine. 🙂 Link to comment
Silnei L Andrade Posted October 13, 2019 Share Posted October 13, 2019 @newbie LAC With the plugin I can display a banner in a particular forum? If so, could you give an example of how to do this? Thanks! Link to comment
Recommended Posts