fredriksundstrom
Forum Replies Created
-
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Excerpt warning upon new installI’ve installed the new version and can also conclude that it is indeed solved. Thanks!
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Can't select nor correlate ads to advertiserAll of a sudden, all the ads are now visible in correlation to the user that created them (under the Advertisers page).
I still cannot use the select-feature in the individual ads to select a new user though. Nothing happens upon clicking “Select” in the modal window, after choosing a new user.
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Doesn't count impressions or clicksAcknowledged. And it works just as you explained it, of course. Thank you!
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Doesn't count impressions or clicksHere’s a few screenshots: https://imgur.com/a/yT1yN
And I’m currently on version 1.5.4.34.
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Doesn't count impressions or clicksActually, I’m not seeing any ads in the admin when going to “Advertisers” either, although my admin user “owns” the current ad, with ID 1. It says no records there as well.
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Turn off default ad placements?Alright. If you are willing to let me in anyway, given we can establish some sort of trust, I’ll be a contributor to a better plugin through pull-requests and I’ll not touch the paid version at all.
You know at what e-mail to find me. Otherwise, I’ll just keep posting here. ??
Thanks for the quick fixes, anyway!
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Turn off default ad placements?This was my fault. Though, still interested in the git repo. I’m available here as well: [email protected]
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Excerpt warning upon new installOr, depending on the intended functionality, to catch it even sooner, maybe rearrange the code a bit and get the check higher up:
public function addExcerptAds( $excerpt ) { $options = self::getSettings(); $bpTI = explode('_', $options['bpAdsId']); if (count($bpTI) == 1) return $excerpt; $bpAd = ''; $bpId = (int)$bpTI[1]; $bpType = (int)$bpTI[0]; if(!$this->isSingle) { if(empty($this->clause)) $this->clause = self::buildWhereClause(); if(!empty($options['beforePost']) && !empty($options['bpExcerpt']) && !empty($options['bpAdsId'])) { $bpAd = self::buildAdObject( $bpType, $bpId, null, $options['bpUseCodes'], $this->clause); } return $bpAd.$excerpt; } else return $excerpt; }
Only in the case that any other real situation would have the array count higher than 1.
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Excerpt warning upon new installP.S. I’m using the javascript way of showing ads, if it makes any difference. And PHP 7.
Anyway… I don’t know if it’s the prettiest of solutions in this case, but a simple check might get rid of it, and still leave working code. Like this:
public function addExcerptAds( $excerpt ) { $options = self::getSettings(); $bpAd = ''; $bpTI = explode('_', $options['bpAdsId']); if (!isset($bpTI[1])) return $excerpt; $bpId = (int)$bpTI[1]; $bpType = (int)$bpTI[0]; if(!$this->isSingle) { if(empty($this->clause)) $this->clause = self::buildWhereClause(); if(!empty($options['beforePost']) && !empty($options['bpExcerpt']) && !empty($options['bpAdsId'])) { $bpAd = self::buildAdObject( $bpType, $bpId, null, $options['bpUseCodes'], $this->clause); } return $bpAd.$excerpt; } else return $excerpt; }
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] Problem in scheduling the postHi! Not sure if it’s related, but I noticed the plugin doesn’t go by the local time. I’m in Sweden, thus one hour ahead of UTC. When I schedule my ads, they go by the UTC time and not the local time I’ve set in the settings for WordPress, which is +1 hour.
Line 459 to 463 in sam-pro-front.php could be something like:
// Schedule $schedule = ''; if($rules['schedule']) { $schedule = " AND IF(sa.schedule, '" . current_time('mysql') . "' BETWEEN sa.sdate AND sa.fdate, TRUE)"; }
Instead. Changing the MySQL function NOW() to WordPress equivalent which should respect the local time set, with the MySQL format. ??
Regards,
Fredrik