Facebook 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 4282
Latest: Eric87
New This Month: 7
New This Week: 1
New Today: 1
Stats
Total Posts: 43660
Total Topics: 7574
Most Online Today: 89
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 0
Guests: 74
Total: 74

Author Topic: How to put Ad Seller Pro in SSL mode  (Read 13231 times)

0 Members and 1 Guest are viewing this topic.

Offline amwebby

  • Community Suite Customer
  • Sr. Member
  • ******
  • Posts: 306
    • View Profile
How to put Ad Seller Pro in SSL mode
« on: January 26, 2013, 04:12:05 am »
I've got an ad running on the front page of my Joomla site using SSI.php

All is well until the user switches to https to fill in a secure form. Then the secure icon shows as broken and the Javascript console reports "The page at https://www.amoc.org displayed insecure content from http://www.amoc.org/forum/index.php?action=adpro;sa=v&id=2&l=1000&m=0&t=1359194613.".

How can I make Adseller Pro switch to https or run Adseller Pro in https all the time?
« Last Edit: January 26, 2013, 09:19:04 am by amwebby »

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16617
    • View Profile
Re: How to put Ad Seller Pro in SSL mode
« Reply #1 on: January 26, 2013, 08:16:22 am »
I don't have anything built in to change the urls to https the system uses the default url that the forum uses for all the content.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline amwebby

  • Community Suite Customer
  • Sr. Member
  • ******
  • Posts: 306
    • View Profile
Re: How to put Ad Seller Pro in SSL mode
« Reply #2 on: January 26, 2013, 08:19:15 am »
Hmm, I'm sure I have the forum set to use https. I'll have to check.

Offline amwebby

  • Community Suite Customer
  • Sr. Member
  • ******
  • Posts: 306
    • View Profile
Re: How to put Ad Seller Pro in SSL mode
« Reply #3 on: January 26, 2013, 09:18:29 am »
Curiouser and couriouser... The forum wasn't set to use https (I'm sure it was..).

However, when I did set it to https everything works fine, until the Joomla site that wraps the forum goes into https. Then the ads don't appear, only the "Advertise Here" link below them.

Can't work that one out, unless the variable I've added to Google Adsense code to switch to https if the site url is secure is somehow getting confused by two secure urls?
« Last Edit: January 26, 2013, 09:21:49 am by amwebby »

Offline amwebby

  • Community Suite Customer
  • Sr. Member
  • ******
  • Posts: 306
    • View Profile
Re: How to put Ad Seller Pro in SSL mode
« Reply #4 on: February 01, 2013, 09:32:20 am »
My workaround to this is similar to the one I use for Adsense where I've used javascript to not show the ad if the site is in https mode.

I applied the same thinking to php and this is what I came up with:
Code: [Select]
<?php
if  ($_SERVER["SERVER_PORT"] == 443
{ echo 
'';} 
else 
{
// Begin Ad Seller Pro Location - Web site bottom
global $sourcedir;
include_once (
$sourcedir '/adseller.php');
$adSellerAdData =  ShowAdLocation(1000);
// Check if any ads where found
if ($adSellerAdData != false)
{
// Display the advertising code
echo $adSellerAdData;
}
// End Ad Seller Pro Location - Web site bottom
}
?>


Now the ad shows in regular mode and when the site switches to secure mode for transactions the ads disappear and hence the insecure content warnings.

I had to adopt this approach as putting my forum in secure mode all the time meant that Chrome simply blocked Adsense content as insecure and other browsers showed an insecure content warning all the time.
« Last Edit: February 01, 2013, 09:36:17 am by amwebby »

 

Related Topics

  Subject / Started by Replies Last post
6 Replies
8499 Views
Last post January 22, 2010, 04:26:17 pm
by SMFHacks
Ad Seller Pro

Started by bulldog71169 « 1 2 » Support

16 Replies
9848 Views
Last post December 30, 2010, 05:18:11 pm
by bulldog71169
1 Replies
12975 Views
Last post October 14, 2014, 09:35:43 am
by Labradoodle-360
7 Replies
14452 Views
Last post March 05, 2020, 11:19:05 am
by Plus
4 Replies
26236 Views
Last post September 15, 2023, 08:42:24 am
by Ghost

+- Recent Topics

Do you offer paid assistance with the SMFBlog mod? by Grammy
February 11, 2025, 02:58:04 pm

SMFBlog Mod by Grammy
February 10, 2025, 07:33:32 pm

[Mod]Bluesky Auto Embed by SMFHacks
January 30, 2025, 01:47:36 pm

Delete a Picture from Trash - Error by SMFHacks
January 29, 2025, 09:06:38 pm

RESOLVED: Store Not Logging Transactions or Sending Emails by SMFHacks
January 23, 2025, 06:24:27 pm

Ability to exclude categories from ezPortal SMF Gallery random image ezblock by Alistair
January 22, 2025, 08:20:13 am

How to move SMF to new server by SMFHacks
January 21, 2025, 08:45:53 pm

Figuring out settings by SMFHacks
January 12, 2025, 04:56:14 pm

Filesizes incorrect by SMFHacks
January 12, 2025, 02:02:47 pm

December 2024 Sale! by SMFHacks
December 02, 2024, 10:30:38 pm

Powered by EzPortal