newbie LAC Posted August 13, 2018 Author Posted August 13, 2018 (edited) 10 hours ago, Silnei L Andrade said: Hi @newbie LAC, with this plugin i can remove ADS of certain forums? Hello, You can create adverts and use conditions where to display adverts Example Edited August 13, 2018 by newbie LAC
loccom Posted August 23, 2018 Posted August 23, 2018 have version 1.0.8 installed. Set up an ad to use geo countries. But it ignores the country and displays whatever country i choose. I select Argentina and still shows in uk. Any ideas what could be wrong @newbie LAC ?
newbie LAC Posted August 23, 2018 Author Posted August 23, 2018 Hello, 16 minutes ago, loccom said: have version 1.0.8 installed. Set up an ad to use geo countries. But it ignores the country and displays whatever country i choose. I select Argentina and still shows in uk. Any ideas what could be wrong @newbie LAC ? Could you tell me that UK ip address? I'll check it. Be sure you use IPS GEO service.
loccom Posted August 23, 2018 Posted August 23, 2018 2 minutes ago, newbie LAC said: Hello, Could you tell me that UK ip address? I'll check it. Be sure you use IPS GEO service. Its definatly a UK IP, I use the same ip on other systems, and I have GEO turned on in club enhancements too ahh i think its because my IPS subscription ran out the other day. Clever old IPS
Sergey_SV Posted September 10, 2018 Posted September 10, 2018 Hi I am trying to workaround the Adsence requiment for not serving ads in several topics with "improper" content. this I could do with, {{if \IPS\Request::i()->app == 'forums' and \IPS\Request::i()->module == 'forums' and \IPS\Request::i()->controller == 'topic' and in_array(\IPS\Request::i()->id, array(107168,164188))}} and serving the static ad with ELSE condition but also I have several forums locked for guests and because IPS could no provide solution for allowing the Adsense crawler in this forums, google serve no ads there. I tried to solve this issue with ELSEIF condition, but then whle code became too bulky and duplicate. Coudl I somehow combine the following logic to serve the ads in the topic view: If the ForumID = a,b,c OR TopicID= d,e,f then "Code1" else "code 2" Thank you
newbie LAC Posted September 10, 2018 Author Posted September 10, 2018 (edited) Hello, 13 minutes ago, Sergey_SV said: Coudl I somehow combine the following logic to serve the ads in the topic view: If the ForumID = a,b,c OR TopicID= d,e,f then "Code1" else "code 2" {{$forumId = 0; $topicId = 0;}} {{if \IPS\Request::i()->app == 'forums' and \IPS\Request::i()->module == 'forums' and \IPS\Request::i()->controller == 'forums'}} {{$forumId = \IPS\Request::i()->id;}} {{elseif \IPS\Request::i()->app == 'forums' and \IPS\Request::i()->module == 'forums' and \IPS\Request::i()->controller == 'topic'}} {{$topicId = \IPS\Request::i()->id; try { $topic = \IPS\forums\Topic::loadAndCheckPerms(\IPS\Request::i()->id); $forumId = $topic->forum_id; } catch(\Exception $e) {};}} {{endif}} {{if in_array($forumId, array('a','b','c')) or in_array($topicId, array('d','e','f'))}} Code1 {{else}} code 2 {{endif}} Edited September 10, 2018 by newbie LAC Sergey_SV 1
DSystem Posted September 10, 2018 Posted September 10, 2018 @newbie LAC In "Extra condition", A script will be allowed to not serve ads in Clubs
newbie LAC Posted September 10, 2018 Author Posted September 10, 2018 Hello, 3 minutes ago, DSyste said: @newbie LAC In "Extra condition", A script will be allowed to not serve ads in Clubs I'll upload new version coming soon. Sorry for delay
DSystem Posted September 10, 2018 Posted September 10, 2018 I would not like to use variable "forumid" to specify all the forums where I do not want the advertisement. Would not it have another variable that could identify that we are in a club and thus not publish the banner?
Sergey_SV Posted September 10, 2018 Posted September 10, 2018 15 minutes ago, newbie LAC said: Hello, {{$forumId = 0; $topicId = 0;}} {{if \IPS\Request::i()->app == 'forums' and \IPS\Request::i()->module == 'forums' and \IPS\Request::i()->controller == 'forums'}} {{$forumId = \IPS\Request::i()->id;}} {{elseif \IPS\Request::i()->app == 'forums' and \IPS\Request::i()->module == 'forums' and \IPS\Request::i()->controller == 'topic'}} {{$topicId = \IPS\Request::i()->id; try { $topic = \IPS\forums\Topic::loadAndCheckPerms(\IPS\Request::i()->id); $forumId = $topic->forum_id; } catch(\Exception $e) {};}} {{endif}} {{if in_array($forumId, array('a','b','c')) or in_array($topicId, array('d','e','f'))}} Code1 {{else}} code 2 {{endif}} Great! worked like a charm
newbie LAC Posted September 10, 2018 Author Posted September 10, 2018 1 minute ago, DSyste said: I would not like to use variable "forumid" to specify all the forums where I do not want the advertisement No need to do it. 1 minute ago, DSyste said: Would not it have another variable that could identify that we are in a club and thus not publish the banner? No. Forum created in the club is a forum and looks like forum. I added 1 variable to determine club pages Wait while I'll upload new version DSystem 1
newbie LAC Posted September 11, 2018 Author Posted September 11, 2018 12 minutes ago, DSyste said: What's New in Version 1.0.9 ? Hello, Read file changelog
newbie LAC Posted September 11, 2018 Author Posted September 11, 2018 Show advert on all pages except clubs {{if !isset(\IPS\Output::i()->hiddenElements['nbenhadverts_club_id'])}} This advert doesn't display in clubs {{endif}} DSystem 1
DSystem Posted September 11, 2018 Posted September 11, 2018 20 minutes ago, newbie LAC said: Show advert on all pages except clubs {{if !isset(\IPS\Output::i()->hiddenElements['nbenhadverts_club_id'])}} This advert doesn't display in clubs {{endif}} Worked like a charm. 😎 Would not it be nice to have nbenhadverts_forum_id too? It would be simpler and I believe that faster too.
newbie LAC Posted September 11, 2018 Author Posted September 11, 2018 1 minute ago, DSyste said: Would not it be nice to have nbenhadverts_forum_id too? I added for nodes \IPS\Output::i()->hiddenElements['nbenhadverts_node_id'] But this afffect to all nodes: forum, files category, calendar etc You can use something like {{if \IPS\Output::i()->hiddenElements['nbenhadverts_node_class'] == 'IPS\forums\Forum' and \IPS\Output::i()->hiddenElements['nbenhadverts_node_id'] == 5}} Show advert in the forum with ID 5 including topics {{endif}} DSystem 1
DSystem Posted September 11, 2018 Posted September 11, 2018 Perfect !!! My script before: {{if request.app == 'forums' and request.module == 'forums' and request.do != 'add' and !isset(\IPS\Output::i()->hiddenElements['nbenhadverts_club_id'])}} {{$forumId = 0; try { $topic = \IPS\forums\Topic::loadAndCheckPerms( \IPS\Request::i()->id ); $forumId = $topic->forum_id; } catch( \Exception $e ) {};}} {{if !in_array($forumId, array(26,10))}}1{{endif}}{{endif}} Current Script: {{if \IPS\Output::i()->hiddenElements['nbenhadverts_node_class'] == 'IPS\forums\Forum' and request.do != 'add' and !isset(\IPS\Output::i()->hiddenElements['nbenhadverts_club_id']) and !in_array(\IPS\Output::i()->hiddenElements['nbenhadverts_node_id'], array(26,10))}}1{{endif}}
gavpedz Posted September 18, 2018 Posted September 18, 2018 Is anyone having issues with ads not auto renewing? In the last month even though invoices have been paid the ads linked to those are not auto renewed and are left disabled meaning I have to go and manually adjust the end date where as before this would be done automatically on invoice payment.
newbie LAC Posted September 18, 2018 Author Posted September 18, 2018 Hello, 4 hours ago, gavpedz said: Is anyone having issues with ads not auto renewing? In the last month even though invoices have been paid the ads linked to those are not auto renewed and are left disabled meaning I have to go and manually adjust the end date where as before this would be done automatically on invoice payment. Not sure this issue related with my app.
DSystem Posted September 21, 2018 Posted September 21, 2018 (edited) You can show an ad only after the user has created a topic? Today I use this way but I do not have the expected result -> member.member_posts == 1 It would spend something like -> member.member_topics == 1 Edited September 21, 2018 by DSyste
newbie LAC Posted September 22, 2018 Author Posted September 22, 2018 Hello, 15 hours ago, DSyste said: You can show an ad only after the user has created a topic? sql-query only {{if \IPS\Member::loggedIn()->member_id and \IPS\Db::i()->select('COUNT(*)', 'forums_topics', array('starter_id=?', \IPS\Member::loggedIn()->member_id))->first() == 1}} DSystem 1
Maxtor Posted September 30, 2018 Posted September 30, 2018 (edited) images not working here: (i cant find extra information about this product) Edited September 30, 2018 by Maxtor
newbie LAC Posted October 1, 2018 Author Posted October 1, 2018 Hello, 10 hours ago, Maxtor said: (i cant find extra information about this product) Ask here 10 hours ago, Maxtor said: images not working here:
Recommended Posts