Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Center store mod problem


RojanUK

Recommended Posts

Posted

Hi,

 

I've downloaded the center store contribution and am trying to install it. I've made all the necessary modifications to the header.php and footer.php and now I need to import the configuration.sql file. But I have no idea how to do that.

 

Obviously I've read the instructions and it said to use phpMyAdmin, which I've never used before. I have found it and started it, but I still don't see how to import anything using that.

 

I've tried to search the KB and Wiki, but no luck.

 

Can anybody give me a hand please?

 

Thanks!

 

(by the way: is there anybody who knows how to move the login/create account from the welcome line to text links in the header I'd be really thankfull too...)

RojanUK

Posted

Never mind about the center shop question. I just fixed it myself.

 

I am however still looking for a solution to move those login/create account links in the welcome line to the link bar under the header. Anyone?

RojanUK

Posted
Never mind about the center shop question. I just fixed it myself.

 

I am however still looking for a solution to move those login/create account links in the welcome line to the link bar under the header. Anyone?

In your index.php file look for the following line

 

<td class="main"><?php echo tep_customer_greeting(); ?></td>

 

You can find the header at this line

 

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

 

so you could move it up under that but what you will probably need to do is move it to your

includes/header.php file

 

to place it exactly where you want it to be in the header.

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Posted

I'm also interested how you would embed the login option in the top bar under the header - I'll keep quiet and wait for any success story to emerge hopefully! ;)

Posted

I too have been looking to see how to do this..

I removed the <td class="main"><?php echo tep_customer_greeting(); ?></td> from the index.php and put it in the header. php

 

After a bit of fooling around to get the position right it works like a charm

Thanks ozcsys

Posted

I moved it as well and the line did disappear on the main page, but even though I did place it in the header.php file, the links did not appear in the header.... *grumble*

 

Back to the drawing board...

 

Is it maybe possible for someone who has done this already to paste the full new line out of the header.php here, so that we can do a cut and paste?

 

What I'm looking for to be clear is to get something like:

 

| login | create accout | my account | cart contents | checkout |

 

on the right side of the header bar, where currently only the last three as listed.

 

Thanks guys.

RojanUK

Posted
I moved it as well and the line did disappear on the main page, but even though I did place it in the header.php file, the links did not appear in the header.... *grumble*

 

Back to the drawing board...

 

Is it maybe possible for someone who has done this already to paste the full new line out of the header.php here, so that we can do a cut and paste?

 

What I'm looking for to be clear is to get something like:

 

| login | create accout | my account | cart contents | checkout |

 

on the right side of the header bar, where currently only the last three as listed.

 

Thanks guys.

post your header file here.

Your online success is Paramount.

Posted
What I'm looking for to be clear is to get something like:

 

| login | create accout | my account | cart contents | checkout |

 

 

I managed to achieve this, but was at a loss to make the 'login' and 'create account' text appear in the same style as the 'my account' and 'cart contents' links in the bar - meaning I couldn't get them to show as white and underline when hovered - those links are being treated as some sort of class I imagine.

I only actually wanted to add the 'login' link as 'create account' isn't needed I feel as it's dealt with when a new customer wants to check out with a purchase by default.

So I'm sort of nearly there after a bit of tweeking but I can't get a handle on their appearance.

Posted
What I'm looking for to be clear is to get something like:

 

| login | create accout | my account | cart contents | checkout |

 

 

I managed to achieve this, but was at a loss to make the 'login' and 'create account' text appear in the same style as the 'my account' and 'cart contents' links in the bar - meaning I couldn't get them to show as white and underline when hovered - those links are being treated as some sort of class I imagine.

I only actually wanted to add the 'login' link as 'create account' isn't needed I feel as it's dealt with when a new customer wants to check out with a purchase by default.

So I'm sort of nearly there after a bit of tweeking but I can't get a handle on their appearance.

the class setting is probably in the td tag - check it is the same for all the links.

Your online success is Paramount.

Posted
post your header file here.

<?php

/*

$Id: header.php,v 1.42 2003/06/10 18:20:38 hpdl Exp $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2003 osCommerce

 

Released under the GNU General Public License

*/

 

// check if the 'install' directory exists, and warn of its existence

if (WARN_INSTALL_EXISTENCE == 'true') {

if (file_exists(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/install')) {

$messageStack->add('header', WARNING_INSTALL_DIRECTORY_EXISTS, 'warning');

}

}

 

// check if the configure.php file is writeable

if (WARN_CONFIG_WRITEABLE == 'true') {

if ( (file_exists(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/includes/configure.php')) && (is_writeable(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/includes/configure.php')) ) {

$messageStack->add('header', WARNING_CONFIG_FILE_WRITEABLE, 'warning');

}

}

 

// check if the session folder is writeable

if (WARN_SESSION_DIRECTORY_NOT_WRITEABLE == 'true') {

if (STORE_SESSIONS == '') {

if (!is_dir(tep_session_save_path())) {

$messageStack->add('header', WARNING_SESSION_DIRECTORY_NON_EXISTENT, 'warning');

} elseif (!is_writeable(tep_session_save_path())) {

$messageStack->add('header', WARNING_SESSION_DIRECTORY_NOT_WRITEABLE, 'warning');

}

}

}

 

// check session.auto_start is disabled

if ( (function_exists('ini_get')) && (WARN_SESSION_AUTO_START == 'true') ) {

if (ini_get('session.auto_start') == '1') {

$messageStack->add('header', WARNING_SESSION_AUTO_START, 'warning');

}

}

 

if ( (WARN_DOWNLOAD_DIRECTORY_NOT_READABLE == 'true') && (DOWNLOAD_ENABLED == 'true') ) {

if (!is_dir(DIR_FS_DOWNLOAD)) {

$messageStack->add('header', WARNING_DOWNLOAD_DIRECTORY_NON_EXISTENT, 'warning');

}

}

 

if ($messageStack->size('header') > 0) {

echo $messageStack->output('header');

}

 

///////////////////

///////////////////

// [0001] BOF: WebMakers.com Added: Center Shop

// This goes before any other table of the shop

//

// Is center Shop ON/OFF ?

///////////////////

 

if ( CENTER_SHOP_ON == 'on' ) {

 

///////////////////

// [0001] Background Color ON/OFF and CellPadding for around the shop?

///////////////////

 

if ( CENTER_SHOP_BACKGROUND_ON == 'on' ) {

?>

<table width="100%" cellpadding="<?php echo CENTER_SHOP_PADDING; ?>" cellspacing="0" border="0" bgcolor="<?php echo CENTER_SHOP_BACKGROUND_COLOR_OUT; ?>">

<tr><td>

<?php

}

 

 

///////////////////

// [0001] Shop Width Size and Shop Background Color

///////////////////

?>

<table width="<?php echo CENTER_SHOP_WIDTH; ?>" align="center" BGCOLOR="<?php echo CENTER_SHOP_BACKGROUND_COLOR; ?>" BORDER="<?php echo CENTER_SHOP_BORDER; ?>" bordercolor="<?php echo CENTER_SHOP_BORDERCOLOR; ?>" CELLSPACING="<?php echo CENTER_SHOP_CELLSPACING; ?>" CELLPADDING="<?php echo CENTER_SHOP_CELLPADDING; ?>" >

<tr><td BGColor="FFFFFF">

<?php

 

///////////////////

// [0001] The rest of this <td> statement is located at the end of footer.php

///////////////////

}

 

 

?>

<table border="0" width="100%" cellspacing="0" cellpadding="0">

<tr class="header">

<td align="center" valign="middle"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'banner5.jpg', 'WorldWide Wonders UK') . '</a>'; ?></td>

<!--

<td align="right" valign="bottom"><?php echo '<a href="' . tep_href_link(FILENAME_ACCOUNT, '', 'SSL') . '">' . tep_image(DIR_WS_IMAGES . 'header_account.gif', HEADER_TITLE_MY_ACCOUNT) . '</a>  <a href="' . tep_href_link(FILENAME_SHOPPING_CART) . '">' . tep_image(DIR_WS_IMAGES . 'header_cart.gif', HEADER_TITLE_CART_CONTENTS) . '</a>  <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '">' . tep_image(DIR_WS_IMAGES . 'header_checkout.gif', HEADER_TITLE_CHECKOUT) . '</a>'; ?>  </td>

-->

</tr>

</table>

<table border="0" width="100%" cellspacing="0" cellpadding="1">

<tr class="headerNavigation">

<td class="headerNavigation">  <?php echo $breadcrumb->trail(' » '); ?></td>

<td align="right" class="headerNavigation"><?php if (tep_session_is_registered('customer_id')) { ?><a href="<?php echo tep_href_link(FILENAME_LOGOFF, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_LOGOFF; ?></a>  |  <?php } ?><a href="<?php echo tep_href_link(FILENAME_ACCOUNT, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_MY_ACCOUNT; ?></a>  |  <a href="<?php echo tep_href_link(FILENAME_SHOPPING_CART); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CART_CONTENTS; ?></a>  |  <a href="<?php echo tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CHECKOUT; ?></a>   </td>

</tr>

</table>

<?php

if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) {

?>

<table border="0" width="100%" cellspacing="0" cellpadding="2">

<tr class="headerError">

<td class="headerError"><?php echo htmlspecialchars(urldecode($HTTP_GET_VARS['error_message'])); ?></td>

</tr>

</table>

<?php

}

 

if (isset($HTTP_GET_VARS['info_message']) && tep_not_null($HTTP_GET_VARS['info_message'])) {

?>

 

<table border="0" width="100%" cellspacing="0" cellpadding="2">

<tr class="headerInfo">

<td class="headerInfo"><?php echo htmlspecialchars($HTTP_GET_VARS['info_message']); ?></td>

</tr>

</table>

<?php

}

?>

RojanUK

Posted

Try:

 

Add(to includes/languages/english.php):

 

define('HEADER_TITLE_CREATE_ACCOUNT', 'Create Account');
define('HEADER_TITLE_LOGIN', 'Login');

 

Change(in header file):

 

<table border="0" width="100%" cellspacing="0" cellpadding="1">
<tr class="headerNavigation">
<td class="headerNavigation">  <?php echo $breadcrumb->trail(' » '); ?></td>
<td align="right" class="headerNavigation"><?php if (tep_session_is_registered('customer_id')) { ?><a href="<?php echo tep_href_link(FILENAME_LOGOFF, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_LOGOFF; ?></a>  |  <?php } ?><a href="<?php echo tep_href_link(FILENAME_ACCOUNT, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_MY_ACCOUNT; ?></a>  |  <a href="<?php echo tep_href_link(FILENAME_SHOPPING_CART); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CART_CONTENTS; ?></a>  |  <a href="<?php echo tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CHECKOUT; ?></a>   </td>
</tr>
</table>

 

To:

 

<table border="0" width="100%" cellspacing="0" cellpadding="1">
<tr class="headerNavigation">
<td class="headerNavigation">  <?php echo $breadcrumb->trail(' » '); ?></td>
<td align="right" class="headerNavigation">
<?php if (tep_session_is_registered('customer_id')) { ?><a href="<?php echo tep_href_link(FILENAME_LOGOFF, '', 'SSL'); ?>" class="headerNavigation"><?php echo 
HEADER_TITLE_LOGOFF; ?></a>  |  
<?php } ?>
<a href="<?php echo tep_href_link(FILENAME_LOGIN, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_LOGIN; ?></a>  | 
<a href="<?php echo tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CREATE_ACCOUNT; ?></a>  | 
<a href="<?php echo tep_href_link(FILENAME_ACCOUNT, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_MY_ACCOUNT; ?></a>  |  
<a href="<?php echo tep_href_link(FILENAME_SHOPPING_CART); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CART_CONTENTS; ?></a>  |  
<a href="<?php echo tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'); ?>" class="headerNavigation"><?php echo HEADER_TITLE_CHECKOUT; ?></a>   </td>
</tr>
</table>

Your online success is Paramount.

Posted

Yesudo: That's it almost. There's a slight error. I haven't looked at it yet to see if I can find it myself though, which I will do next. The links are now located in the bar as I wanted - THANK YOU SO MUCH! - but my logo has disappeared... :rolleyes:

 

I will have a look myself but if you see it before I do, please post it here.

 

Thanks again, mate! You are truly a life-saver.

RojanUK

Posted

Found the problem... had accidentally overwritten the header td. Working like a charm now. Thanks again!! :D

RojanUK

Posted

thanks Yesudo, my'n is now sorted as well - after a small struggle 'login' is sitting in my header bar nicely. ;)

Archived

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

×
×
  • Create New...