Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

if in ssl mode, do not show footer


Guest

Recommended Posts

how could i achieve this?

 

i have google ads/banners in the footer and they muck up the ssl transitions

http://www.oscommerce.info/kb/osCommerce/G...mon_Problems/75

 

Scroll to the bottom.

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Link to comment
Share on other sites

the code provided there didn't work in includes/footer.php

 

i have tables surrounding the ads that need to be removed as well, if the ads don't show.

 

i was hoping somebody knew how to make it so all i have to do is place the edit on includes/footer.php instead of editing each individual page that needs this stuff removed :(

Link to comment
Share on other sites

the code provided there didn't work in includes/footer.php

 

i have tables surrounding the ads that need to be removed as well, if the ads don't show.

 

i was hoping somebody knew how to make it so all i have to do is place the edit on includes/footer.php instead of editing each individual page that needs this stuff removed :(

It'll be a variation on the same thing to completely remove the footer. Just wrap the

 

<!-- footer //-->

<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>

<!-- footer_eof //-->

 

in the if...

 

<!-- footer //-->

<?php

if ($request_type != 'SSL') {require(DIR_WS_INCLUDES . 'footer.php')}; ?>

<!-- footer_eof //-->

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Link to comment
Share on other sites

the files i need to remove are in the footer, but i do not want to remove the ENTIRE footer... like leave the copyright text and whatnot :)

So?

 

Build a version of the footer without the stuff you don't want in ssl and switch them back and forth.

 

Call it ssl_footer.php or something.

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Link to comment
Share on other sites

that defeats the purpose of my initial post ;) i already knew how to make a new footer, i was just hoping there was a faster way to do it

We don't know what's in your footer.

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Link to comment
Share on other sites

We don't know what's in your footer.

 

rofl, exactly, post that footer code and we'll slice it up to show only the allowed parts for SSL.

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Link to comment
Share on other sites

  • 3 weeks later...
It'll be a variation on the same thing to completely remove the footer. Just wrap the

 

<!-- footer //-->

<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>

<!-- footer_eof //-->

 

in the if...

 

<!-- footer //-->

<?php

if ($request_type != 'SSL') {require(DIR_WS_INCLUDES . 'footer.php')}; ?>

<!-- footer_eof //-->

 

So, do you have to just replace that code everywhere it shows up?

Link to comment
Share on other sites

I tried to ex out the footer with that code and I got the white screen of parse error.

 

I have banners in my footer that are causing alert windows to show up announcing insecure items because they are counters being loaded in from outside my server.

 

Does anyone have advice for me about this? I would really appreciate help. Thanks and Happy New Year!!!

Link to comment
Share on other sites

I tried to ex out the footer with that code and I got the white screen of parse error.

 

I have banners in my footer that are causing alert windows to show up announcing insecure items because they are counters being loaded in from outside my server.

 

Does anyone have advice for me about this? I would really appreciate help. Thanks and Happy New Year!!!

 

I have this in my footer.php. Just replace the existing banner code:

<?php if ($request_type != 'SSL') {echo tep_display_banner('static', $banner);} else {
$randomBanner = (rand()%99)+1;//99 is the only thing you may need to change
echo tep_display_banner('static', $randomBanner);
}?>

 

Then, I just make sure that I put my Adsense (or any other non-SSL-friendly) banner as the highest ID value for the banners. Replace 99 with however many banners you have that are SSL friendly and you're ready to go.

 

Check out www.homeappliancesuperstore.com for an example. I have 3 banners, but only the 2 images show up on the SSL pages. (99 = 2 on this script)

 

Hope that helps.

Joseph

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...