Ads Manager 2 by Siropu

Ads Manager 2 by Siropu [Paid] 2.4.22

No permission to buy (€49.99)
If you want to use Geo criteria, please download the Geo Lite 2 City database and upload the file GeoLite2-City.mmdb to src/addons/Siropu/AdsManager/Vendor/MaxMind. Once the file is in place, this message will go away.

The download links no longer work @Siropu

Due to upcoming data privacy regulations, we are making significant changes to how you access free GeoLite2 databases starting December 30, 2019

 
Suggestion:

Would it be possible to ad a feature whereby advertisers can choose a priority, and there is a relevant pricing structure per chosen pririty

So when it is based on time (not CPC or CPM)

So e.g. You can choose:

  • £500 per year priority 5
  • £400 per year priority 4
  • £300 per year priority 3
  • £200 per year priority 2
  • £100 per year priority 1
 
I am wondering if it is possible to either split-test ads with the software or have one ad slot that shows two different ads, where each is shown randomly but a certain percentage of the time. e.g. you want to show ad1 30% of the time and ad2 70% of the time. Is that possible?
 
If you use a package with random display order and in the ads you set the display priority, then you can achieve something like that.
 
If I set up a monthly recurring payment package (banner -added to the sponsor group- ) and have a second package (banner ) for those who are signed up to the first package and its recurring payment and they cancel the main recurring payment will the second recurring banner continue to run or will it expire because the first subscription expired?
 
If there are two packages and the second package is availiable if the first package is purchased, will the second package stop if they quit paying for the first package or will it continue becasue of recurring payments?
 
Based on "Add advertiser to user groups" package option? They won't be able to see the package, but the ad won't stop.
 
I added a second package that will replace the original package once it expires. Is there a way for the new package banner in the header to rotate with the other banners without displaying two banners? Both packages want the same position.

Would I have to move over the first package banners into the new package for this to display correctly?
 
Last edited:
@Siropu

Looks like approval is required when advertisers update their ads, even if "Ads do not require approval" is enabled for the package.

PS: Thanks again for adding this and the usergroup per package setting, they're incredibly helpful!
 
@Siropu

When re-assigning ads members aren't being added to the advertiser usergroups specified in the package.

Is there a cron that has to run, or should it be instant? Also, they'll be removed from the usergroup once the ad(s) expire, right?
 
@Siropu
I know that it is third party script, but mobile detect give me 200-300 errors in acp only because I have 7.4.x php version.
Could you please solve that?
Same thing for your another addon Ads manager
If you are using the latest version of both add-ons, it shouldn't be a problem. I'm running 7.4 myself with no errors.



Using Ads manager v2.3.17

Code:
Server error log
ErrorException: [E_NOTICE] Trying to access array offset on value of type null src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php:1056
Generated by: Unknown account 24.02.2020. at 15:10
Stack trace
#0 src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php(1056): XF::handlePhpError()
#1 src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php(1177): Mobile_Detect->checkHttpHeadersForMobile()
#2 src/addons/Siropu/AdsManager/Criteria/Device.php(178): Mobile_Detect->isMobile()
#3 src/addons/Siropu/AdsManager/Criteria/Device.php(22): Siropu\AdsManager\Criteria\Device->setDeviceType()
#4 src/XF/Container.php(270): Siropu\AdsManager\Criteria\Device->__construct()
#5 src/XF/App.php(754): XF\Container->createObject()
#6 src/XF/Container.php(228): XF\App->XF\{closure}()
#7 src/XF/App.php(2827): XF\Container->create()
#8 src/addons/Siropu/AdsManager/Entity/Ad.php(363): XF\App->criteria()
#9 src/addons/Siropu/AdsManager/Template/Ad.php(453): Siropu\AdsManager\Entity\Ad->matchesDeviceCriteria()
#10 [internal function]: Siropu\AdsManager\Template\Ad->Siropu\AdsManager\Template\{closure}()
#11 src/XF/Mvc/Entity/AbstractCollection.php(189): array_filter()
#12 src/addons/Siropu/AdsManager/Template/Ad.php(455): XF\Mvc\Entity\AbstractCollection->filter()
#13 src/addons/Siropu/AdsManager/Template/Ad.php(312): Siropu\AdsManager\Template\Ad->prepareAdsForDisplay()
#14 src/addons/Siropu/AdsManager/Template/Ad.php(303): Siropu\AdsManager\Template\Ad->setAds()
#15 src/addons/Siropu/AdsManager/Listener.php(38): Siropu\AdsManager\Template\Ad->__construct()
#16 [internal function]: Siropu\AdsManager\Listener::templaterGlobalData()
#17 src/XF/Extension.php(67): call_user_func_array()
#18 src/XF/App.php(2654): XF\Extension->fire()
#19 src/XF/App.php(1922): XF\App->fire()
#20 src/XF/App.php(1800): XF\App->getGlobalTemplateData()
#21 src/XF/Pub/App.php(435): XF\App->preRender()
#22 src/XF/Mvc/Dispatcher.php(395): XF\Pub\App->preRender()
#23 src/XF/Mvc/Dispatcher.php(58): XF\Mvc\Dispatcher->render()
#24 src/XF/App.php(2184): XF\Mvc\Dispatcher->run()
#25 src/XF.php(391): XF\App->run()
#26 index.php(20): XF::runApp()
#27 {main}
Request state
array(4) {
  ["url"] => string(42) "/attachments/mjesecev-sjetveni-jpg.100142/"
  ["referrer"] => string(32) "http://www.google.com/blank.html"
  ["_GET"] => array(1) {
    ["/attachments/mjesecev-sjetveni-jpg_100142/"] => string(0) ""
  }
  ["_POST"] => array(0) {
  }
}
 
@Siropu

Just did a new advertiser onboarding test and having issues. Package has "Ads do not require approval" checked. Advertiser paid for the ad. Ad status is Approved (but not displaying, enable/disable toggle is off). Options for admin to receive email and alert notifications are checked, but admin did not receive either notification.

Feel free to start a conversation if you need help testing :)
 
From time to time i get this error:

Code:
    XF\CssRenderException: Error rendering template public:siropu_ads_manager_ad.less: ParseError: missing opening `{` in public:siropu_ads_manager_ad.less on line 3800, column 1 (on or near line 3800) src/XF/CssRenderException.php:87

    Generiert von: Unbekanntes Konto 24 Februar 2020 um 12:16

Stack-Trace

 3797 |             max-width: 728px;
 3798 |         }
 3799 |     }
*3800*| }
 3801 | .p-header .sam-swiper-container
 3802 | {
 3803 |     max-width: 728px;
------------

#0 src/XF/CssRenderer.php(408): XF\CssRenderException::createFromLessException(Object(Less_Exception_Chunk), 'public:siropu_a...', '// Note that th...')
#1 src/XF/CssRenderer.php(342): XF\CssRenderer->renderToCss('public:siropu_a...', '// Note that th...')
#2 src/XF/CssRenderer.php(250): XF\CssRenderer->renderTemplate('public:siropu_a...', NULL)
#3 src/XF/CssRenderer.php(116): XF\CssRenderer->renderTemplates(Array, Array, Array)
#4 src/XF/CssWriter.php(53): XF\CssRenderer->render(Array)
#5 css.php(30): XF\CssWriter->run(Array, 46, 2, '1989932e49176fe...')
#6 {main}

-------------

Previous Less_Exception_Chunk: ParseError: missing opening `{` in anonymous-file-2029.less on line 3800, column 1
3798|         }
3799|     }
3800| }
3801| .p-header .sam-swiper-container
3802| {
3803|     max-width: 728px; - src/vendor/oyejorge/less.php/lib/Less/Parser.php:677
#0 src/vendor/oyejorge/less.php/lib/Less/Parser.php(621): Less_Parser->GetRules(NULL)
#1 src/vendor/oyejorge/less.php/lib/Less/Parser.php(449): Less_Parser->_parse()
#2 src/XF/CssRenderer.php(404): Less_Parser->parse('// Note that th...')
#3 src/XF/CssRenderer.php(342): XF\CssRenderer->renderToCss('public:siropu_a...', '// Note that th...')
#4 src/XF/CssRenderer.php(250): XF\CssRenderer->renderTemplate('public:siropu_a...', NULL)
#5 src/XF/CssRenderer.php(116): XF\CssRenderer->renderTemplates(Array, Array, Array)
#6 src/XF/CssWriter.php(53): XF\CssRenderer->render(Array)
#7 css.php(30): XF\CssWriter->run(Array, 46, 2, '1989932e49176fe...')
#8 {main}

array(4) {
  ["url"] => string(452) "/forums/css.php?css=public%3Aandy_chat.less%2Cpublic%3Alightslider.less%2Cpublic%3Anode_list.less%2Cpublic%3Anotices.less%2Cpublic%3Asiropu_ads_manager_ad.less%2Cpublic%3Astructured_list.less%2Cpublic%3Ath_nodeStyling_nodes.46.less%2Cpublic%3Auix_extendedFooter.less%2Cpublic%3Auix_socialMedia.less%2Cpublic%3Auix_welcomeSection.less%2Cpublic%3Axfmg_media_list.less%2Cpublic%3Aextra.less&s=46&l=2&d=1582447394&k=1989932e49176fe6aa5c3a00c4d1f63374430244"
  ["referrer"] => string(36) "https://www.pattayaforum.net/forums/"
  ["_GET"] => array(5) {
    ["css"] => string(321) "public:andy_chat.less,public:lightslider.less,public:node_list.less,public:notices.less,public:siropu_ads_manager_ad.less,public:structured_list.less,public:th_nodeStyling_nodes.46.less,public:uix_extendedFooter.less,public:uix_socialMedia.less,public:uix_welcomeSection.less,public:xfmg_media_list.less,public:extra.less"
    ["s"] => string(2) "46"
    ["l"] => string(1) "2"
    ["d"] => string(10) "1582447394"
    ["k"] => string(40) "1989932e49176fe6aa5c3a00c4d1f63374430244"
  }
  ["_POST"] => array(0) {
  }
}

I checked the template siropu_ads_manager_ad.less several time.
There is no missing opening {

So i don`t really understand why this error comes up.
 
Strange. I'm using 7.4 myself and can't reproduce this.
As far I can see, all errors are related with images (attachments) in posts.

Code:
Server error log
ErrorException: [E_NOTICE] Trying to access array offset on value of type null src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php:1056
Generated by: Unknown account 25.02.2020. at 19:58
Stack trace
#0 src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php(1056): XF::handlePhpError()
#1 src/addons/Siropu/AdsManager/Vendor/MobileDetect/Mobile_Detect.php(1177): Mobile_Detect->checkHttpHeadersForMobile()
#2 src/addons/Siropu/AdsManager/Criteria/Device.php(178): Mobile_Detect->isMobile()
#3 src/addons/Siropu/AdsManager/Criteria/Device.php(22): Siropu\AdsManager\Criteria\Device->setDeviceType()
#4 src/XF/Container.php(270): Siropu\AdsManager\Criteria\Device->__construct()
#5 src/XF/App.php(754): XF\Container->createObject()
#6 src/XF/Container.php(228): XF\App->XF\{closure}()
#7 src/XF/App.php(2827): XF\Container->create()
#8 src/addons/Siropu/AdsManager/Entity/Ad.php(363): XF\App->criteria()
#9 src/addons/Siropu/AdsManager/Template/Ad.php(453): Siropu\AdsManager\Entity\Ad->matchesDeviceCriteria()
#10 [internal function]: Siropu\AdsManager\Template\Ad->Siropu\AdsManager\Template\{closure}()
#11 src/XF/Mvc/Entity/AbstractCollection.php(189): array_filter()
#12 src/addons/Siropu/AdsManager/Template/Ad.php(455): XF\Mvc\Entity\AbstractCollection->filter()
#13 src/addons/Siropu/AdsManager/Template/Ad.php(312): Siropu\AdsManager\Template\Ad->prepareAdsForDisplay()
#14 src/addons/Siropu/AdsManager/Template/Ad.php(303): Siropu\AdsManager\Template\Ad->setAds()
#15 src/addons/Siropu/AdsManager/Listener.php(38): Siropu\AdsManager\Template\Ad->__construct()
#16 [internal function]: Siropu\AdsManager\Listener::templaterGlobalData()
#17 src/XF/Extension.php(67): call_user_func_array()
#18 src/XF/App.php(2654): XF\Extension->fire()
#19 src/XF/App.php(1922): XF\App->fire()
#20 src/XF/App.php(1800): XF\App->getGlobalTemplateData()
#21 src/XF/Pub/App.php(435): XF\App->preRender()
#22 src/XF/Mvc/Dispatcher.php(395): XF\Pub\App->preRender()
#23 src/XF/Mvc/Dispatcher.php(58): XF\Mvc\Dispatcher->render()
#24 src/XF/App.php(2184): XF\Mvc\Dispatcher->run()
#25 src/XF.php(391): XF\App->run()
#26 index.php(20): XF::runApp()
#27 {main}
Request state
array(4) {
  ["url"] => string(30) "/attachments/yozuri-jpg.26167/"
  ["referrer"] => string(340) "https://www.google.com/search?oe=utf-8&gcc=hr&ctzn=Europe%2FSarajevo&ctf=1&v=9.94.7.16.arm&fheit=0&biw=913&bih=600&ntyp=1&ram_mb=913&action=devloc&source=and.gsa.widget.text&tbm=isch&rcid=8095&ei=&ar=0&ampcct=23&noj=1&client=tablet-android-huawei&wf=pp1&padt=200&padb=914&hl=hr-HR&fbts=1582656488110&qsubts=1582656487496&q=sabiki%20varalice"
  ["_GET"] => array(1) {
    ["/attachments/yozuri-jpg_26167/"] => string(0) ""
  }
  ["_POST"] => array(0) {
  }
}

PHP version - 7.4.3
MySQL version - 10.3.22 (10.3.22-MariaDB)
Server software - nginx/1.17.8
 
Advertiser paid for the ad.
Using what payment option?

Options for admin to receive email and alert notifications are checked, but admin did not receive either notification.
For non super admins, you have to set the admin permission "Manage Ads Manager" in order to get the notifications.

From time to time i get this error
Haven't seen this before. I have no idea why you get it.

As far I can see, all errors are related with images (attachments) in posts.
Will look into it and see if I can find the problem.
 
Using what payment option?


For non super admins, you have to set the admin permission "Manage Ads Manager" in order to get the notifications.

I think I see the issue, I tried using Stripe (test mode). Got the Thank You message, so it appeared that it went through, but it didn't.
 
Top Bottom