Forums / All Other Contributions/Addons / Ezpages Footer Columns support

Ezpages Footer Columns support

Views: 22,563

Results 141 to 152 of 152
22 Dec 2013, 5:13 PM
#141
azzenner avatar

azzenner

New Zenner

Join Date:
Oct 2005
Posts:
65
Plugin Contributions:
0

Ezpages Footer Columns support

Hi Glen,
It's just on a local home test server at the moment so I can't give you a URL. I will be installing it up on the host in a test environment in a day or so. We did try carefully merging things after the initial install made the Ezpages Improved Menus graphics go away, but had to back it out.

We went ahead and installed Flexible Footer Menus and have that working now. I'd still like to understand what happened for future use because I have a couple of other sites that will be getting spruced up. Also, perhaps others on the forums wanting to use both plugins could benefit.
Happy Holidays! Debbie

22 Dec 2013, 5:25 PM
#142
azzenner avatar

azzenner

New Zenner

Join Date:
Oct 2005
Posts:
65
Plugin Contributions:
0

Re: Ezpages Footer Columns support

Hi Glen,
Here's more info from my husband who did the install...We had the Ezpages Improved Menu plugin installed and working. When he installed the Ezpages Footer Columns plugin, some of the file names were the same and it apparently overlaid them, thus causing the Improved Menu stuff to go away. He backed it out and tried merging some of the code but it still didn't work right. That's when we just decided to try the Flexible Footer Menu plugins and that seems to work ok with it. Not sure if this helps or not. Let me know if you need more specific info.
Thanks, Debbie

23 Dec 2013, 3:09 AM
#143
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Ezpages Footer Columns support

I bave found the issue: I had updated and improved both EZ-Pages Footer Columns and EZ-Pages Improved Menus last December, but I did not finish testing and packaging and upload the Menus mod. The new versions of both are compatible, as are the old versions of both, but old and new are not. So I will put the EZ-Pages Improved Menus update back on the front burner and get it uploaded (after the holidays, can't concentrate on it now).

23 Dec 2013, 3:38 PM
#144
azzenner avatar

azzenner

New Zenner

Join Date:
Oct 2005
Posts:
65
Plugin Contributions:
0

Re: Ezpages Footer Columns support

Sounds great! Thanks. I'm sure that must have been our issue, trying to mix old & new.
Happy Holidays to you and yours!

Debbie

18 Sep 2015, 2:25 AM
#145
signagen2 avatar

signagen2

New Zenner

Join Date:
Jul 2015
Location:
Clarksburg
Posts:
29
Plugin Contributions:
0

Re: Ezpages Footer Columns support

That is a very nice addon. Thank you. But there is PHP warning after installation as follows.

PHP Warning: Division by zero in .....includes/functions/extra_functions/str_replace_int_functions.php on line 22

How to fix the issue?

Many thanks!!!

18 Sep 2015, 2:34 AM
#146
signagen2 avatar

signagen2

New Zenner

Join Date:
Jul 2015
Location:
Clarksburg
Posts:
29
Plugin Contributions:
0

Re: Ezpages Footer Columns support

After installation, i got a pretty nice footer like the picture. However now I want the footer background extending to 100% width of screen while keep the width of four column at 906 px. Is there any way I can do that. Sorry I am not good at css. I tried to change the footer background image repeat-x for #navSuppWrapper in stylesheet.css but no luck. Many thanks.

27 Jan 2021, 6:23 PM
#147
downtoearth avatar

downtoearth

New Zenner

Join Date:
Aug 2015
Posts:
3
Plugin Contributions:
0

Re: Ezpages Footer Columns support

Does anyone have this working on version 1.5.7? I'm trying to upgrade from 1.5.4 and I get the following debug log:

#1 trigger_error() called at [C:\xampp\htdocs\zencart157\store\includes\classes\db\mysql\query_factory.php:170]
#2 queryFactory->show_error() called at [C:\xampp\htdocs\zencart157\store\includes\classes\db\mysql\query_factory.php:142]
#3 queryFactory->set_error() called at [C:\xampp\htdocs\zencart157\store\includes\classes\db\mysql\query_factory.php:269]
#4 queryFactory->Execute() called at [C:\xampp\htdocs\zencart157\store\includes\modules\downtoearth\ezpages_bar_footer.php:24]
#5 include(C:\xampp\htdocs\zencart157\store\includes\modules\downtoearth\ezpages_bar_footer.php) called at [C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\templates\tpl_ezpages_bar_footer.php:18]
#6 require(C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\templates\tpl_ezpages_bar_footer.php) called at [C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_footer.php:31]
#7 require(C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_footer.php) called at [C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_main_page.php:173]
#8 require(C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_main_page.php) called at [C:\xampp\htdocs\zencart157\store\index.php:94]
--> PHP Fatal error: 1054:Unknown column 'pages_title' in 'order clause' :: select * from ezpages where status_footer = 1 and footer_sort_order > 0 order by footer_sort_order, pages_title ==> (as called by) C:\xampp\htdocs\zencart157\store\includes\modules\downtoearth\ezpages_bar_footer.php on line 24 <== in C:\xampp\htdocs\zencart157\store\includes\classes\db\mysql\query_factory.php on line 170.

27 Jan 2021, 6:49 PM
#148
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,798
Plugin Contributions:
22

Re: Ezpages Footer Columns support

I'm not 100% sure because I don't have that plugin installed, but this should help:
edit your C:\xampp\htdocs\zencart157\store\includes\modules\downtoearth\ezpages_bar_footer.php and simply replace all content with this:

<?php
/**
 * ezpages bar (footer) - used to display links to EZ-Pages content in horizontal format (usually as a footer element)
 *
 * @copyright Copyright 2003-2020 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: DrByte 2020 May 19 Modified in v1.5.7 $
 */
if (!defined('IS_ADMIN_FLAG')) {
  die('Illegal Access');
}
$zco_notifier->notify('NOTIFY_START_EZPAGES_FOOTERBAR');

$var_linksList = array();

// test if bar should display:
if (EZPAGES_STATUS_FOOTER == '1' || (EZPAGES_STATUS_FOOTER == '2' && zen_is_whitelisted_admin_ip())) {

  if (!$sniffer->table_exists(TABLE_EZPAGES_CONTENT)) {
    return; // early exit; db not upgraded
  }
  $pages_query = $db->Execute("SELECT e.pages_id, e.page_open_new_window, e.page_is_ssl, e.alt_url, e.alt_url_external, e.toc_chapter, ec.pages_title
                              FROM  " . TABLE_EZPAGES . " e,
                                    " . TABLE_EZPAGES_CONTENT . " ec
                              WHERE e.pages_id = ec.pages_id 
                              AND ec.languages_id = " . (int)$_SESSION['languages_id'] . "
                              AND e.status_footer = 1
                              AND e.footer_sort_order > 0
                              ORDER BY e.footer_sort_order, ec.pages_title");
  if ($pages_query->RecordCount()>0) {
    $rows = 0;
    $page_query_list_footer = array();
    foreach ($pages_query as $page_query) {
      $rows++;
      $page_query_list_footer[$rows]['id'] = $page_query['pages_id'];
      $page_query_list_footer[$rows]['name'] = $page_query['pages_title'];
      $page_query_list_footer[$rows]['sort'] = $page_query->fields['footer_sort_order'];//ezpages_footer_columns
      $page_query_list_footer[$rows]['altURL'] = '';

      // if altURL is specified, check to see if it starts with "http", and if so, create direct URL, otherwise use a zen href link
      switch (true) {
        // external link new window or same window
        case ($page_query['alt_url_external'] != ''):
        $page_query_list_footer[$rows]['altURL']  = $page_query['alt_url_external'];
        break;
        // internal link new window
        case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '1'):
        $page_query_list_footer[$rows]['altURL']  = (substr($page_query['alt_url'],0,4) == 'http') ?
        $page_query['alt_url'] :
        ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true));
        break;
        // internal link same window
        case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '0'):
        $page_query_list_footer[$rows]['altURL']  = (substr($page_query['alt_url'],0,4) == 'http') ?
        $page_query['alt_url'] :
        ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true));
        break;
      }

      // if altURL is specified, use it; otherwise, use EZPage ID to create link
      $page_query_list_footer[$rows]['link'] = ($page_query_list_footer[$rows]['altURL'] =='') ?
      zen_href_link(FILENAME_EZPAGES, 'id=' . $page_query['pages_id'] . ($page_query['toc_chapter'] > 0 ? '&chapter=' . $page_query['toc_chapter'] : ''), ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL')) :
      $page_query_list_footer[$rows]['altURL'];
      $page_query_list_footer[$rows]['link'] .= ($page_query['page_open_new_window'] == '1' ? '" rel="noreferrer noopener" target="_blank' : '');
    }

    $var_linksList = $page_query_list_footer;
  }
} // test for display

$zco_notifier->notify('NOTIFY_END_EZPAGES_FOOTERBAR');

The difference is in the query, which now uses two tables for ez-pages, instead of the one single table as it was when the plugin was released...

My site - Pro ZC Help
My portfolio | My plugins

27 Jan 2021, 8:18 PM
#149
downtoearth avatar

downtoearth

New Zenner

Join Date:
Aug 2015
Posts:
3
Plugin Contributions:
0

Re: Ezpages Footer Columns support

Thanks very much for your help! Now I get the following debug log:

#1 require(C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\templates\tpl_ezpages_bar_footer.php) called at [C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_footer.php:33]
#2 require(C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\common\tpl_footer.php) called at [C:\xampp\htdocs\zencart157\store\includes\templates\template_default\common\tpl_main_page.php:179]
#3 require(C:\xampp\htdocs\zencart157\store\includes\templates\template_default\common\tpl_main_page.php) called at [C:\xampp\htdocs\zencart157\store\index.php:94]
--> PHP Warning: Division by zero in C:\xampp\htdocs\zencart157\store\includes\templates\downtoearth\templates\tpl_ezpages_bar_footer.php on line 49.

And line 49 in tpl_ezpages_bar_footer.php is:

$col_width = (int)(100/$cols);//update divs with % width

Any idea how to fix that error?

27 Jan 2021, 9:23 PM
#150
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,798
Plugin Contributions:
22

Re: Ezpages Footer Columns support

My bad, sorry about that... The code I gave you was incorrect - I wasn't paying attention. Here's a revised copy:

<?php
/**
 * ezpages bar (footer) - used to display links to EZ-Pages content in horizontal format (usually as a footer element)
 *
 * @copyright Copyright 2003-2020 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: DrByte 2020 May 19 Modified in v1.5.7 $
 */
if (!defined('IS_ADMIN_FLAG')) {
    die('Illegal Access');
}
$zco_notifier->notify('NOTIFY_START_EZPAGES_FOOTERBAR');

$var_linksList = array();

// test if bar should display:
if (EZPAGES_STATUS_FOOTER == '1' || (EZPAGES_STATUS_FOOTER == '2' && zen_is_whitelisted_admin_ip())) {

    if (!$sniffer->table_exists(TABLE_EZPAGES_CONTENT)) {
        return; // early exit; db not upgraded
    }
    $pages_query = $db->Execute("SELECT e.pages_id, e.page_open_new_window, e.page_is_ssl, e.alt_url, e.alt_url_external, e.toc_chapter, e.footer_sort_order, ec.pages_title
                              FROM  " . TABLE_EZPAGES . " e,
                                    " . TABLE_EZPAGES_CONTENT . " ec
                              WHERE e.pages_id = ec.pages_id 
                              AND ec.languages_id = " . (int)$_SESSION['languages_id'] . "
                              AND e.status_footer = 1
                              AND e.footer_sort_order > 0
                              ORDER BY e.footer_sort_order, ec.pages_title");
    if ($pages_query->RecordCount()>0) {
        $rows = 0;
        $page_query_list_footer = array();
        foreach ($pages_query as $page_query) {
            $rows++;
            $page_query_list_footer[$rows]['id'] = $page_query['pages_id'];
            $page_query_list_footer[$rows]['name'] = $page_query['pages_title'];
            $page_query_list_footer[$rows]['sort'] = $page_query['footer_sort_order'];//ezpages_footer_columns
            $page_query_list_footer[$rows]['altURL'] = '';

            // if altURL is specified, check to see if it starts with "http", and if so, create direct URL, otherwise use a zen href link
            switch (true) {
                // external link new window or same window
                case ($page_query['alt_url_external'] != ''):
                    $page_query_list_footer[$rows]['altURL']  = $page_query['alt_url_external'];
                    break;
                // internal link new window
                case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '1'):
                    $page_query_list_footer[$rows]['altURL']  = (substr($page_query['alt_url'],0,4) == 'http') ?
                        $page_query['alt_url'] :
                        ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true));
                    break;
                // internal link same window
                case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '0'):
                    $page_query_list_footer[$rows]['altURL']  = (substr($page_query['alt_url'],0,4) == 'http') ?
                        $page_query['alt_url'] :
                        ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true));
                    break;
            }

            // if altURL is specified, use it; otherwise, use EZPage ID to create link
            $page_query_list_footer[$rows]['link'] = ($page_query_list_footer[$rows]['altURL'] =='') ?
                zen_href_link(FILENAME_EZPAGES, 'id=' . $page_query['pages_id'] . ($page_query['toc_chapter'] > 0 ? '&chapter=' . $page_query['toc_chapter'] : ''), ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL')) :
                $page_query_list_footer[$rows]['altURL'];
            $page_query_list_footer[$rows]['link'] .= ($page_query['page_open_new_window'] == '1' ? '" rel="noreferrer noopener" target="_blank' : '');
        }

        $var_linksList = $page_query_list_footer;
    }
} // test for display

$zco_notifier->notify('NOTIFY_END_EZPAGES_FOOTERBAR');

This WILL produce columns as expected, but depending on your template, it might require additional CSS tweaks, or even code changes because it just does simple percentage calculations.

My site - Pro ZC Help
My portfolio | My plugins

27 Jan 2021, 9:42 PM
#151
downtoearth avatar

downtoearth

New Zenner

Join Date:
Aug 2015
Posts:
3
Plugin Contributions:
0

Re: Ezpages Footer Columns support

That works!! Thank you so much - I really appreciate the help!!

7 Jun 2021, 6:29 PM
#152
jasonshanks avatar

jasonshanks

Zen Follower

Join Date:
Feb 2009
Location:
atlanta GA
Posts:
297
Plugin Contributions:
0

Re: Ezpages Footer Columns support

balihr:

My bad, sorry about that... The code I gave you was incorrect - I wasn't paying attention. Here's a revised copy:

<?php /** * ezpages bar (footer) - used to display links to EZ-Pages content in horizontal format (usually as a footer element) * * @copyright Copyright 2003-2020 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0 * @version $Id: DrByte 2020 May 19 Modified in v1.5.7 $ */ if (!defined('IS_ADMIN_FLAG')) { die('Illegal Access'); } $zco_notifier->notify('NOTIFY_START_EZPAGES_FOOTERBAR'); $var_linksList = array(); // test if bar should display: if (EZPAGES_STATUS_FOOTER == '1' || (EZPAGES_STATUS_FOOTER == '2' && zen_is_whitelisted_admin_ip())) { if (!$sniffer->table_exists(TABLE_EZPAGES_CONTENT)) { return; // early exit; db not upgraded } $pages_query = $db->Execute("SELECT e.pages_id, e.page_open_new_window, e.page_is_ssl, e.alt_url, e.alt_url_external, e.toc_chapter, e.footer_sort_order, ec.pages_title FROM " . TABLE_EZPAGES . " e, " . TABLE_EZPAGES_CONTENT . " ec WHERE e.pages_id = ec.pages_id AND ec.languages_id = " . (int)$_SESSION['languages_id'] . " AND e.status_footer = 1 AND e.footer_sort_order > 0 ORDER BY e.footer_sort_order, ec.pages_title"); if ($pages_query->RecordCount()>0) { $rows = 0; $page_query_list_footer = array(); foreach ($pages_query as $page_query) { $rows++; $page_query_list_footer[$rows]['id'] = $page_query['pages_id']; $page_query_list_footer[$rows]['name'] = $page_query['pages_title']; $page_query_list_footer[$rows]['sort'] = $page_query['footer_sort_order'];//ezpages_footer_columns $page_query_list_footer[$rows]['altURL'] = ''; // if altURL is specified, check to see if it starts with "http", and if so, create direct URL, otherwise use a zen href link switch (true) { // external link new window or same window case ($page_query['alt_url_external'] != ''): $page_query_list_footer[$rows]['altURL'] = $page_query['alt_url_external']; break; // internal link new window case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '1'): $page_query_list_footer[$rows]['altURL'] = (substr($page_query['alt_url'],0,4) == 'http') ? $page_query['alt_url'] : ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true)); break; // internal link same window case ($page_query['alt_url'] != '' && $page_query['page_open_new_window'] == '0'): $page_query_list_footer[$rows]['altURL'] = (substr($page_query['alt_url'],0,4) == 'http') ? $page_query['alt_url'] : ($page_query['alt_url']=='' ? '' : zen_href_link($page_query['alt_url'], '', ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL'), true, true, true)); break; } // if altURL is specified, use it; otherwise, use EZPage ID to create link $page_query_list_footer[$rows]['link'] = ($page_query_list_footer[$rows]['altURL'] =='') ? zen_href_link(FILENAME_EZPAGES, 'id=' . $page_query['pages_id'] . ($page_query['toc_chapter'] > 0 ? '&chapter=' . $page_query['toc_chapter'] : ''), ($page_query['page_is_ssl']=='0' ? 'NONSSL' : 'SSL')) : $page_query_list_footer[$rows]['altURL']; $page_query_list_footer[$rows]['link'] .= ($page_query['page_open_new_window'] == '1' ? '" rel="noreferrer noopener" target="_blank' : ''); } $var_linksList = $page_query_list_footer; } } // test for display $zco_notifier->notify('NOTIFY_END_EZPAGES_FOOTERBAR'); ``` > > This WILL produce columns as expected, but depending on your template, it might require additional CSS tweaks, or even code changes because it just does simple percentage calculations. I know this is some time later , but i am having the same issue. When i use your updated code for the ezpages_bar_footer.php , i get the same errors as the other user. #1 require(/surplusremotes.com/includes/templates/bootstrap/templates/tpl_ezpages_bar_footer.php) called at [/surplusremotes.com/includes/templates/bootstrap/common/tpl_footer.php:33] #2 require(/surplusremotes.com/includes/templates/bootstrap/common/tpl_footer.php) called at [/surplusremotes.com/includes/templates/bootstrap/common/tpl_main_page.php:253] #3 require(surplusremotes.com/includes/templates/bootstrap/common/tpl_main_page.php) called at [/surplusremotes.com/index.php:94] --> PHP Warning: Use of undefined constant EZPAGES_FOOTER_EXT - assumed 'EZPAGES_FOOTER_EXT' (this will throw an Error in a future version of PHP) in /surplusremotes.com/includes/templates/bootstrap/templates/tpl_ezpages_bar_footer.php on line 33. I am using ZC 1.5.7C with boot strap4 installed and the only other plugin being ZX Slideshow , please help.

Zencart 1.5.6c PHP 7.2 Order Replacement AC Adapters and Power Cords Online https://www.missingcord.com