Thread: Cant logout

Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2007
    Location
    England
    Posts
    82
    Plugin Contributions
    0

    Default Cant logout

    Hello, hopefully someone can help me. We have put a new header at http://www.footprintsglagow.co.uk

    Everything is fine, except you cannot logout, it either simply just doesnt logout the member or goes into a indefinite loop. Maybe something in this code from tpl_header.php thats causing it?

    Is there a quick fix that once clicking logout it will do so? Currently ive put the site down for maintenance due to security issues this will cause.

    thanks

    PHP Code:
    <?php
    /**
     * Common Template - tpl_header.php
     *
     * this file can be copied to /templates/your_template_dir/pagename<br />
     * example: to override the privacy page<br />
     * make a directory /templates/my_template/privacy<br />
     * copy /templates/templates_defaults/common/tpl_footer.php to /templates/my_template/privacy/tpl_header.php<br />
     * to override the global settings and turn off the footer un-comment the following line:<br />
     * <br />
     * $flag_disable_header = true;<br />
     *
     * @package templateSystem
     * @copyright Copyright 2003-2006 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: tpl_header.php 4813 2006-10-23 02:13:53Z drbyte $
     */
    ?>

    <?php
      
    // Display all header alerts via messageStack:
    /**
      if ($messageStack->size('header') > 0) {
        echo $messageStack->output('header');
      }
      if (isset($_GET['error_message']) && zen_not_null($_GET['error_message'])) {
      echo htmlspecialchars(urldecode($_GET['error_message']));
      }
      if (isset($_GET['info_message']) && zen_not_null($_GET['info_message'])) {
       echo htmlspecialchars($_GET['info_message']);
    } else {

    }
    */
    ?>

    <!--bof-header logo and navigation display-->
    <?php
    if (!isset($flag_disable_header) || !$flag_disable_header) {
    ?>

    <div id="headerWrapper">
    <!--bof-navigation display-->
    <div id="navMainWrapper">
    <div id="navMain">


        <ul class="back">
        <li><?php echo '<a href="' HTTP_SERVER DIR_WS_CATALOG '">'?><?php echo HEADER_TITLE_CATALOG?></a></li>
    <?php if ($_SESSION['customer_id']) { ?>
        <li><a href="<?php echo zen_href_link(FILENAME_LOGOFF'''SSL'); ?>"><?php echo HEADER_TITLE_LOGOFF?></a></li>
        <li><a href="<?php echo zen_href_link(FILENAME_ACCOUNT'''SSL'); ?>"><?php echo HEADER_TITLE_MY_ACCOUNT?></a></li>
    <?php
          
    } else {
            if (
    STORE_STATUS == '0') {
    ?>
        <li><a href="<?php echo zen_href_link(FILENAME_LOGIN'''SSL'); ?>"><?php echo HEADER_TITLE_LOGIN?></a></li>
    <?php } } ?>

    <?php if ($_SESSION['cart']->count_contents() != 0) { ?>
        <li><a href="<?php echo zen_href_link(FILENAME_SHOPPING_CART'''NONSSL'); ?>"><?php echo HEADER_TITLE_CART_CONTENTS?></a></li>
        <li><a href="<?php echo zen_href_link(FILENAME_CHECKOUT_SHIPPING'''SSL'); ?>"><?php echo HEADER_TITLE_CHECKOUT?></a></li>
    <?php }?>
    </ul>

    </div>
    <div id="navMainSearch"><?php require(DIR_WS_MODULES 'sideboxes/search_header.php'); ?></div>
    <br class="clearBoth" />
    </div>
    <!--eof-navigation display-->

    <script type="text/javascript" src="images/stmenu.js"></script>

        <div id="logo">
    <table border="0" width="850" id="table1">
            <tr>
                <td width="840" colspan="2">

    <a href="http://www.footprintsglasgow.co.uk"><img src="http://www.footprintsglasgow.co.uk/header2.jpg"></a>
    </td>
            </tr>
            <tr>
                <td width="500"><script type="text/javascript">
    <!--
    stm_bm(["menu61b2",830,"","images/blank.gif",0,"","",0,0,250,0,1000,1,0,0,"","",0,0,1,2,"default","hand",""],this);
    stm_bp("p0",[0,4,0,0,0,0,0,0,100,"",-2,"",-2,50,0,0,"#799BD8","transparent","",3,0,0,"#000000"]);
    stm_ai("p0i0",[0,"Home","","",-1,-1,0,"http://footprintsglasgow.co.uk/","_self","","","","",0,0,0,"","",0,0,0,1,1,"#FFFFF7",1,"#FFFFF7",1,"images/bg_01.gif","images/bg_04.gif",0,0,0,0,"#FFFFF7","#000000","#FFFFFF","#009933","bold 8pt Verdana","bold 8pt Verdana",0,0],80,24);
    stm_aix("p0i1","p0i0",[0,"Company","","",-1,-1,0,"#","_self","","","","",0,0,0,"","",-1,-1],80,24);
    stm_bp("p1",[1,4,0,0,4,0,10,0,100,"",-2,"",-2,80,0,0,"#799BD8","#CCCCCC","",0,1,1,"#CCCCCC #B2B2B2 #B2B2B2"]);
    stm_aix("p1i0","p0i0",[0,"Shipping & Returns ","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=shippinginfo","_self","","","images/icon_01.gif","images/icon_01.gif",10,7,0,"","",0,0,0,0,1,"#CCCCCC",0,"#F2F2F2",0,"","",0,0,0,0,"#FFFFCC","#CCCC00","#000000","#009900","8pt Verdana","8pt Verdana"],80,18);
    stm_aix("p1i1","p1i0",[0,"Privacy Notice","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=privacy","_self"],80,18);
    stm_aix("p1i2","p1i0",[0,"Terms & Conditions","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=conditions","_self"],80,18);
    stm_mc("p1",[5,"#000000",1,0,"",0]);
    stm_ep();
    stm_aix("p0i2","p0i1",[0,"Products"],80,24);
    stm_bpx("p2","p1",[]);
    stm_aix("p2i0","p1i0",[0,"Specials","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=specials","_self","","","images/icon_01.gif","icon_01.gif",10,7,0,"","",0,0,0,0,1,"#B7B7B7",1,"#F2F2F2",0,"","",0,0,0,0,"#FFFFCC","#CCCC00","#333333"],80,18);
    stm_aix("p2i1","p2i0",[0,"New Products","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=products_new","_self","","","images/icon_01.gif","icon_01.gif",10,7,0,"","",0,0,0,0,1,"#B7B7B7",1,"#F2F2F2",0,"","",0,0,0,0,"#FFFFCC","#CCCC00","#333333"],80,18);
    stm_aix("p2i2","p2i1",[0,"Featured Products","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=featured_products","_self","","","images/icon_01.gif","icon_01.gif",10,7,0,"","",0,0,0,0,1,"#B7B7B7",1,"#F2F2F2",0,"","",0,0,0,0,"#FFFFCC","#CCCC00","#333333"],80,18);
    stm_aix("p2i3","p2i0",[0,"All Products","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=products_all","_self","","","images/icon_01.gif","icon_01.gif",10,7,0,"","",0,0,0,0,1,"#B7B7B7",1,"#F2F2F2",0,"","",0,0,0,0,"#FFFFCC","#CCCC00","#333333"],80,18);
    stm_ep();
    stm_aix("p0i3","p0i2",[0,"Clinic"],80,24);
    stm_bpx("p3","p1",[]);
    stm_aix("p3i0","p2i0",[0,"Travel Clinic","","",-1,-1,0,"http://footprintsglasgow.com/travel_clinic.htm","_blank","","","images/icon_01.gif","images/icon_01.gif",10,7,0,"","",0,0,0,0,1,"#FFCC00"],0,18);
    stm_aix("p3i1","p3i0",[0,"Appointments","","",-1,-1,0,"http://footprintsglasgow.com/appointments.htm","_blank","","","images/icon_01.gif","images/icon_01.gif",10,7,0,"","",0,0,0,0,1,"#FFCC00"],0,18);
    stm_mc("p3",[3,"#000000",1,0,"",3]);
    stm_ep();
    stm_aix("p0i4","p0i0",[0,"Search","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=advanced_search","_self","","","","",0,0,0,"","",0,0,0,1,1,"#FFFFF7",1,"#FFFFF7",1,"images/bg_02.gif","images/bg_05.gif"],80,24);
    stm_aix("p0i5","p0i1",[0,"Contact"],80,24);
    stm_bpx("p4","p1",[]);
    stm_aix("p4i0","p3i1",[0,"Contact Us","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=contact_us","_self"],80,18);;
    stm_aix("p4i1","p3i1",[0,"Newsletter Unsubscribe","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=unsubscribe","_self"],80,18);
    stm_aix("p4i2","p3i1",[0,"Link Partners","","",-1,-1,0,"http://footprintsglasgow.co.uk/index.php?main_page=link_partners","_self"],80,18);
    stm_ep();
    stm_ep();
    stm_em();
    //-->
    </script></td>
                <td width="340">
                <img border="0" src="images/cc.jpg"></td>
            </tr>
        </table>
        </div>

    <br class="clearBoth" />



    <!--


    -->

    <!--eof-header logo and navigation display-->

    <!--bof-optional categories tabs navigation display-->
    <?php require($template->get_template_dir('tpl_modules_categories_tabs.php',DIR_WS_TEMPLATE$current_page_base,'templates'). '/tpl_modules_categories_tabs.php'); ?><!--eof-optional categories tabs navigation display--><!--bof-header ezpage links--><?php if (EZPAGES_STATUS_HEADER == '1' or (EZPAGES_STATUS_HEADER == '2' and (strstr(EXCLUDE_ADMIN_IP_FOR_MAINTENANCE$_SERVER['REMOTE_ADDR'])))) { ?><?php require($template->get_template_dir('tpl_ezpages_bar_header.php',DIR_WS_TEMPLATE$current_page_base,'templates'). '/tpl_ezpages_bar_header.php'); ?>
    <?php 
    ?>
    <!--eof-header ezpage links-->
    </div>
    <?php ?>

  2. #2
    Join Date
    Jan 2007
    Location
    England
    Posts
    82
    Plugin Contributions
    0

    Default Re: Cant logout

    Just to elaborate:

    What actually happens is, when you click logout it appears to go into a loop - on accasion the loop does end but doesnt logout. If you dont come out of the loop and close the browser, most times reopening the browser and they are still logged in.

    Really need to find a solution to this. This is my tpl_main_page.php

    PHP Code:
    <?php
    /**
    * Common Template - tpl_main_page.php
    *
    * Governs the overall layout of an entire page<br />
    * Normally consisting of a header, left side column. center column. right side column and footer<br />
    * For customizing, this file can be copied to /templates/your_template_dir/pagename<br />
    * example: to override the privacy page<br />
    * - make a directory /templates/my_template/privacy<br />
    * - copy /templates/templates_defaults/common/tpl_main_page.php to /templates/my_template/privacy/tpl_main_page.php<br />
    * <br />
    * to override the global settings and turn off columns un-comment the lines below for the correct column to turn off<br />
    * to turn off the header and/or footer uncomment the lines below<br />
    * Note: header can be disabled in the tpl_header.php<br />
    * Note: footer can be disabled in the tpl_footer.php<br />
    * <br />
    * $flag_disable_header = true;<br />
    * $flag_disable_left = true;<br />
    * $flag_disable_right = true;<br />
    * $flag_disable_footer = true;<br />
    * <br />
    * // example to not display right column on main page when Always Show Categories is OFF<br />
    * <br />
    * if ($current_page_base == 'index' and $cPath == '') {<br />
    * $flag_disable_right = true;<br />
    * }<br />
    * <br />
    * example to not display right column on main page when Always Show Categories is ON and set to categories_id 3<br />
    * <br />
    * if ($current_page_base == 'index' and $cPath == '' or $cPath == '3') {<br />
    * $flag_disable_right = true;<br />
    * }<br />
    *
    * @package templateSystem
    * @copyright Copyright 2003-2006 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: tpl_main_page.php 3856 2006-06-29 02:26:33Z drbyte $
    */
    // the following IF statement can be duplicated/modified as needed to set additional flags
    if (in_array($current_page_base,explode(",",'list_pages_to_skip_all_right_sideboxes_on_here,separated_by_commas,and_no_spaces')) ) {
    $flag_disable_right true;
    }
     
    $header_template 'tpl_header.php';
    $footer_template 'tpl_footer.php';
    $left_column_file 'column_left.php';
    $right_column_file 'column_right.php';
    $body_id str_replace('_'''$_GET['main_page']);
    ?>
    <body id="<?php echo $body_id 'Body'?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'?>>
    <?php
    if (SHOW_BANNERS_GROUP_SET1 != '' && $banner zen_banner_exists('dynamic'SHOW_BANNERS_GROUP_SET1)) {
    if (
    $banner->RecordCount() > 0) {
    ?>
    <div id="bannerOne" class="banners"><?php echo zen_display_banner('static'$banner); ?></div>
    <?php
    }
    }
    ?>
    <div id="mainWrapper">
    <?php
    /**
    * prepares and displays header output
    *
    */
    require($template->get_template_dir('tpl_header.php',DIR_WS_TEMPLATE$current_page_base,'common'). '/tpl_header.php');?>
    <table width="100%" border="0" cellspacing="0" cellpadding="0" id="contentMainWrapper">
    <tr>
    <?php
    if (COLUMN_LEFT_STATUS == or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
    // global disable of column_left
    $flag_disable_left true;
    }
    if (!isset(
    $flag_disable_left) || !$flag_disable_left) {
    ?>
    <td id="navColumnOne" class="columnLeft" style="width: <?php echo COLUMN_WIDTH_LEFT?>">
    <?php
    /**
    * prepares and displays left column sideboxes
    *
    */
    ?>
    <div id="navColumnOneWrapper" style="width: <?php echo BOX_WIDTH_LEFT?>"><?php require(DIR_WS_MODULES zen_get_module_directory('column_left.php')); ?></div></td>
    <?php
    }
    ?>
    <td valign="top">
    <!-- bof breadcrumb -->
    <?php if (DEFINE_BREADCRUMB_STATUS == '1') { ?>
    <div id="navBreadCrumb"><?php echo $breadcrumb->trail(BREAD_CRUMBS_SEPARATOR); ?></div>
    <?php ?>
    <!-- eof breadcrumb -->
    <?php
    if (SHOW_BANNERS_GROUP_SET3 != '' && $banner zen_banner_exists('dynamic'SHOW_BANNERS_GROUP_SET3)) {
    if (
    $banner->RecordCount() > 0) {
    ?>
    <div id="bannerThree" class="banners"><?php echo zen_display_banner('static'$banner); ?></div>
    <?php
    }
    }
    ?>
    <!-- bof upload alerts -->
    <?php if ($messageStack->size('upload') > 0) echo $messageStack->output('upload'); ?>
    <!-- eof upload alerts -->
    <?php
    /**
    * prepares and displays center column
    *
    */
    require($body_code); ?>
    <?php
    if (SHOW_BANNERS_GROUP_SET4 != '' && $banner zen_banner_exists('dynamic'SHOW_BANNERS_GROUP_SET4)) {
    if (
    $banner->RecordCount() > 0) {
    ?>
    <div id="bannerFour" class="banners"><?php echo zen_display_banner('static'$banner); ?></div>
    <?php
    }
    }
    ?></td>
    <?php
    if (COLUMN_RIGHT_STATUS == or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
    // global disable of column_right
    $flag_disable_right true;
    }
    if (!isset(
    $flag_disable_right) || !$flag_disable_right) {
    ?>
    <td id="navColumnTwo" class="columnRight" style="width: <?php echo COLUMN_WIDTH_RIGHT?>">
    <?php
    /**
    * prepares and displays right column sideboxes
    *
    */
    ?>
    <div id="navColumnTwoWrapper" style="width: <?php echo BOX_WIDTH_RIGHT?>"><?php require(DIR_WS_MODULES zen_get_module_directory('column_right.php')); ?></div></td>
    <?php
    }
    ?>
    </tr>
    </table>
    <?php
    /**
    * prepares and displays footer output
    *
    */
    require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE$current_page_base,'common'). '/tpl_footer.php');?>
    </div>
    <!--bof- parse time display -->
    <?php
    if (DISPLAY_PAGE_PARSE_TIME == 'true') {
    ?>
    <div class="smallText center">Parse Time: <?php echo $parse_time?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
    <?php
    }
    ?>
    <!--eof- parse time display -->
    <!--bof- banner #6 display -->
    <?php
    if (SHOW_BANNERS_GROUP_SET6 != '' && $banner zen_banner_exists('dynamic'SHOW_BANNERS_GROUP_SET6)) {
    if (
    $banner->RecordCount() > 0) {
    ?>
    <div id="bannerSix" class="banners"><?php echo zen_display_banner('static'$banner); ?></div>
    <?php
    }
    }
    ?>
    <!--eof- banner #6 display -->
    </body>

  3. #3
    Join Date
    Jan 2007
    Location
    England
    Posts
    82
    Plugin Contributions
    0

    Default Re: Cant logout

    Anyone have any ideas?

  4. #4
    Join Date
    Jan 2007
    Location
    England
    Posts
    82
    Plugin Contributions
    0

    Default Re: Cant logout

    It seems those pages arnt the ones at fault.

    Basically i need to get this working again (logout not looping but actually logging out) so we are prepared to pay someone to fix this site.

    If your interested, then please PM me with fee and timescale. thanks.

 

 

Similar Threads

  1. customers cant check out and I cant get to admin
    By rdsbaker in forum General Questions
    Replies: 7
    Last Post: 27 Mar 2011, 11:05 PM
  2. LogOut Button
    By artistic in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 6 Feb 2010, 10:10 PM
  3. No Logout option
    By gazaa in forum Managing Customers and Orders
    Replies: 3
    Last Post: 28 Feb 2008, 09:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg