Author Topic: [Add-On] Etano Ad's (SUSPENDED)  (Read 5321 times)

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
[Add-On] Etano Ad's (SUSPENDED)
« on: August 15, 2015, 07:41:40 AM »
INTRODUCING
Etano Ad's

Add-On Version : V1.00 | Script Compatibility: 1.23 / 2.00 / 2.10 | Released : 15th August 2015 | Last Updated : N/A



A great way to earn some extra income is through displaying advertisements. With Etano Ad’s you can schedule ads, set expiry dates, limit who will see ads (i.e Show ad’s to just free members, paid members or all members).
** Guests/Logged Out members see ad's

You can also use it as a ‘benefit’ for users who upgrade by offering an ad-free site to paid users!

NOTE! This mod has been tested within reason with Google Adsense on a responsive site. If you use this mod with Adsense on a responsive site then its recommended you use Adsense’s Responsive Ad Unit. Whilst i can't see any reason for any major compatibility issues with 3rd party services i I make no guarantees over 3rd party compatibility. However i will always try to help if you run into any issues :)



SCREENSHOTS - Click to enlarge

You can see 2 ad widgets live on my demo site at khdev.x10host.com/sassy_lou

.
.



REQUIREMENTS / NOTES

This add-on uses Etanos package installer to install the add-on so most of the installation is automatic.

The add-on installer assumes the following:
1) Your sites skin is located in the ‘def’ folder (yoursite > skins_site > def)
2) Your database uses the default database prefix (dsb_xxxxx)

By default the add-on is set up work with the default Free and Paid memberships. Any additional memberships you have created will be treated as Paid memberships. So if you want to only show ads to free members and you have created additional free memberships then please refer to the manual on modifying the add-on. (If you get stuck on this please feel free to contact me and i will help) ** Don't confuse memberships with subscription packages.



More Info / Download


SUSPENDED



DISCLAIMER

This add-on provides you with the ability to easily manage ads, schedule ads, limit ads to all, paid or free members. It is your responsibility to use ads that are suitable for the locations/site skin which you choose to use ads.

I make no guarantees that this add-on is compatible with 3rd party ad units and also make no guarantees that ads provided by 3rd Party Ad companies will render perfectly within the default widget sections.

Google Adsense - This add-on has been tested with Google Adsense (usingResponsive Ad Unit)  on a live website using a Responsive Skin and things appear to render fine.

Hornyflings

  • Prime Member
  • ****
  • Posts: 196
  • Karma: +3/-0
    • AsiasHeart
Re: [Add-On] Etano Ad's
« Reply #1 on: August 17, 2015, 06:38:57 AM »
I've just installed the add-on.
But am not sure if it's working as it should do because got 4 error messages in etano error log.
Sent one of the messages by PM.

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
Re: [Add-On] Etano Ad's
« Reply #2 on: August 17, 2015, 06:58:36 AM »
I've just installed the add-on.
But am not sure if it's working as it should do because got 4 error messages in etano error log.
Sent one of the messages by PM.

Replied :)

Marble

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 1005
  • Karma: +56/-7
Re: [Add-On] Etano Ad's
« Reply #3 on: September 06, 2015, 10:37:17 PM »
For a moment, I thought I broke the ads mod after a restore from a site backup, but then I tried it out in google chrome and it's working fine. I think Firefox is a little buggy sometimes.
If you see that I'm logged in forever... it just means I turned the page on my browser and forgot to logout.

Marble

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 1005
  • Karma: +56/-7
Re: [Add-On] Etano Ad's
« Reply #4 on: September 13, 2015, 10:05:12 PM »
I'm stumped on one thing and I don't know if it's related to this mod or the placement of the ads code.

I have two login options on my website. Both a widget up in the header of the frame and a login page. When I login with the widget the ads disappear with a premium membership.

I have tried to go directly from my index page and just typing in mysite.com/login.php and logged in. the ads disappeared. I have my access levels set so that non-members cannot view photos or profiles. When I click on a profile thumbnail image from the newest members widget or the newest photos widget, I am redirected to the mysite.com/login.php page. When I login from there, the ads do not disappear. It appears that for some reason, the access levels settings are causing this.

With all logins, the correct membership title appears in the home page.

I went back to the original sitename/processors/login.php file and added your code and I still had the problem.
It doesn't matter which browser I'm using. Tried it with firefox, chrome, PC desktop version of Safari, and iOS Chrome. The problem is still there.

I only have a non-membership, free and paid.

Do you have an idea on why this is happening?
If you see that I'm logged in forever... it just means I turned the page on my browser and forgot to logout.

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
Re: [Add-On] Etano Ad's
« Reply #5 on: September 14, 2015, 03:45:54 AM »
I'm stumped on one thing and I don't know if it's related to this mod or the placement of the ads code.

I have two login options on my website. Both a widget up in the header of the frame and a login page. When I login with the widget the ads disappear with a premium membership.

I have tried to go directly from my index page and just typing in mysite.com/login.php and logged in. the ads disappeared. I have my access levels set so that non-members cannot view photos or profiles. When I click on a profile thumbnail image from the newest members widget or the newest photos widget, I am redirected to the mysite.com/login.php page. When I login from there, the ads do not disappear. It appears that for some reason, the access levels settings are causing this.

With all logins, the correct membership title appears in the home page.

I went back to the original sitename/processors/login.php file and added your code and I still had the problem.
It doesn't matter which browser I'm using. Tried it with firefox, chrome, PC desktop version of Safari, and iOS Chrome. The problem is still there.

I only have a non-membership, free and paid.

Do you have an idea on why this is happening?

Hey,

Sorry, the issue you're experiencing is my fault.
It's caused by the placement of the code which sets the session info for ad's.

The block of code the user manual instructs you add to yoursite > processors > login.php needs moving.

Around lines 68 to 75 find
Code: [Select]
<?php

unset(
$user['last_activity']);
$_SESSION[_LICENSE_KEY_]['user']=array_merge(isset($_SESSION[_LICENSE_KEY_]['user']) ? $_SESSION[_LICENSE_KEY_]['user'] : array(),$user);
$_SESSION[_LICENSE_KEY_]['user']['loginout']=$time;
if (isset($_on_after_login)) {
for ($i=0;isset($_on_after_login[$i]);++$i) {
call_user_func($_on_after_login[$i]);
}
}

#### PUT AD CODE HERE #####


Move the ad's session coding below it.

That will solve the issue. :)

Marble

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 1005
  • Karma: +56/-7
Re: [Add-On] Etano Ad's
« Reply #6 on: September 14, 2015, 08:44:35 AM »
Oh! very good. It's working perfectly now. :)
If you see that I'm logged in forever... it just means I turned the page on my browser and forgot to logout.

MuscularItalian

  • Confirmed Member
  • **
  • Posts: 18
  • Karma: +0/-0
Re: [Add-On] Etano Ad's
« Reply #7 on: September 18, 2015, 04:25:24 AM »
Having an issue creating an ad. I did everything in the instructions. When I go to create a new ad then click "create ad" on the Create a new ad screen, it takes me back to where all of my are supposed to be show in list format, but nothing is created? Also there is no HTML code section when i click create ad, that is in the documentation, but not my site. Any idea whats up?

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
Re: [Add-On] Etano Ad's
« Reply #8 on: September 18, 2015, 06:15:46 AM »
Having an issue creating an ad. I did everything in the instructions. When I go to create a new ad then click "create ad" on the Create a new ad screen, it takes me back to where all of my are supposed to be show in list format, but nothing is created? Also there is no HTML code section when i click create ad, that is in the documentation, but not my site. Any idea whats up?

Hi,

Seems odd.. Can you create an ad but before submitting it take a screenshot of the page so I can check it?

You can either post the screenshot here or email it to me at khwebdevelopment@gmail.com

Also any errors appearing in your error log?


Hornyflings

  • Prime Member
  • ****
  • Posts: 196
  • Karma: +3/-0
    • AsiasHeart
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #9 on: March 18, 2016, 10:23:29 AM »
Hello KHDev,
it's first time I've created an ad for random use and added the following widget into home.html as mentioned in the instructions to show Random Widget - Content Area only ads:

Code: [Select]
<!--widget="adverts(array('area'=>'content'))"-->
However the result is that every content area ad will be shown although they are not defined as ads to be used in the random widget, that means setting for "Random?" is "No".

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #10 on: March 18, 2016, 06:23:55 PM »
Hello KHDev,
it's first time I've created an ad for random use and added the following widget into home.html as mentioned in the instructions to show Random Widget - Content Area only ads:

Code: [Select]
<!--widget="adverts(array('area'=>'content'))"-->
However the result is that every content area ad will be shown although they are not defined as ads to be used in the random widget, that means setting for "Random?" is "No".


Thanks for letting me know.

Theres an error in the code in plugins > widget > advert >  adverts.class.php

on line 73 find

Code: [Select]
$where=" `ad_type`='$ad_type' AND 'rand_incl'=0 AND `start`<='$today' AND `end`>='$today' ORDER BY RAND()";

change to:

Code: [Select]
$where=" `ad_type`='$ad_type' AND `rand_in`=1 AND `start`<='$today' AND `end`>='$today' ORDER BY RAND()";

and that should fix it :)

Sorry about that :)

Hornyflings

  • Prime Member
  • ****
  • Posts: 196
  • Karma: +3/-0
    • AsiasHeart
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #11 on: March 19, 2016, 01:10:30 AM »
Hello KHDev,
thanks for helping out and your great support.
Seems it's working now as it should do.

insha

  • Confirmed Member
  • **
  • Posts: 3
  • Karma: +0/-0
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #12 on: April 09, 2016, 12:05:24 PM »
can you send download link?

sante

  • Active Member
  • ***
  • Posts: 26
  • Karma: +0/-0
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #13 on: April 23, 2016, 08:47:15 AM »
Will there be an update to this? I am looking to put some ads into the site and this looks good.

KHDev

  • Global Moderator
  • Veteran Member
  • *****
  • Posts: 512
  • Karma: +45/-2
  • Etano Contributor (Skins & Mods)
Re: [Add-On] Etano Ad's (SUSPENDED)
« Reply #14 on: April 23, 2016, 04:38:28 PM »
Will there be an update to this? I am looking to put some ads into the site and this looks good.

Yes, it will be available again shortly. I'm currently restructuring my project to make sure everything is of a high quality and making any changes needed to improve them :)