Forums / Bug Reports / [Done v2.0.0] tpl_account_default.php HTML Error

[Done v2.0.0] tpl_account_default.php HTML Error

Locked

Started by dweingart on 2 Feb 2007, 1:58 PM · Views: 2,220

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
2 Feb 2007, 1:58 PM
#1
dweingart avatar

dweingart

New Zenner

Join Date:
Mar 2006
Posts:
9
Plugin Contributions:
0

[Done v2.0.0] tpl_account_default.php HTML Error

Small HTML error in tpl_account_default.php in the #prevOrders table. The cell widths look like this:

<tr> <td width="70px"> <td width="30px"> <td> <td width="70px"> <td width="70px" align="right"> <td align="right"> </tr>

The width attributes shouldn't contain the string "px".

I did a search and couldn't find this mentioned anywhere else.

-dave

28 Feb 2007, 4:45 PM
#2
froyse avatar

froyse

New Zenner

Join Date:
Jul 2006
Posts:
2
Plugin Contributions:
0

Re: [Done v2.0.0] tpl_account_default.php HTML Error

Thanks for pointing that out. I'm using Zen Cart 1.3.0.1 and found a programming error on this same page that causes the HTML layout to break depending which options are active in the Email Notifications section.

<?php
  if (SHOW_NEWSLETTER_UNSUBSCRIBE_LINK !='false' or CUSTOMERS_PRODUCTS_NOTIFICATION_STATUS !='0') {
?>

<h2><?php echo EMAIL_NOTIFICATIONS_TITLE; ?></h2>

<?php
  if (SHOW_NEWSLETTER_UNSUBSCRIBE_LINK=='true') {
?>

<ul id="myAccountNotify" class="list">

<li><?php echo ' <a href="' . zen_href_link(FILENAME_ACCOUNT_NEWSLETTERS, '', 'SSL') . '">' . EMAIL_NOTIFICATIONS_NEWSLETTERS . '</a>'; ?></li>

<?php } //endif newsletter unsubscribe ?>

<?php
  if (CUSTOMERS_PRODUCTS_NOTIFICATION_STATUS == '1') {
?>

<li><?php echo ' <a href="' . zen_href_link(FILENAME_ACCOUNT_NOTIFICATIONS, '', 'SSL') . '">' . EMAIL_NOTIFICATIONS_PRODUCTS . '</a>'; ?></li>

</ul>

<?php } //endif product notification ?>

<?php } // endif don't show unsubscribe or notification ?>

should be

<?php
  if (SHOW_NEWSLETTER_UNSUBSCRIBE_LINK !='false' or CUSTOMERS_PRODUCTS_NOTIFICATION_STATUS !='0') {
?>

<h2><?php echo EMAIL_NOTIFICATIONS_TITLE; ?></h2>

<ul id="myAccountNotify" class="list">

<?php
  if (SHOW_NEWSLETTER_UNSUBSCRIBE_LINK=='true') {
?>

<li><?php echo ' <a href="' . zen_href_link(FILENAME_ACCOUNT_NEWSLETTERS, '', 'SSL') . '">' . EMAIL_NOTIFICATIONS_NEWSLETTERS . '</a>'; ?></li>

<?php } //endif newsletter unsubscribe ?>

<?php
  if (CUSTOMERS_PRODUCTS_NOTIFICATION_STATUS == '1') {
?>

<li><?php echo ' <a href="' . zen_href_link(FILENAME_ACCOUNT_NOTIFICATIONS, '', 'SSL') . '">' . EMAIL_NOTIFICATIONS_PRODUCTS . '</a>'; ?></li>

<?php } //endif product notification ?>

</ul>

<?php } // endif don't show unsubscribe or notification ?>

The enclosing unordered list tags should be placed in the level of the first conditional statement, not with the individual list item conditionals. Otherwise, if only one of the two individual conditions are true, the UL will be missing the opening or closing tag.

28 Feb 2007, 6:24 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: [Done v2.0.0] tpl_account_default.php HTML Error

The issue reported above for v1.3.0.x has already been implemented in v1.3.5. Note that the currently-released version is v1.3.7.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

28 Feb 2007, 7:56 PM
#4
afo avatar

afo

Totally Zenned

Join Date:
Aug 2004
Location:
New York City
Posts:
6,800
Plugin Contributions:
0

Re: [Done v2.0.0] tpl_account_default.php HTML Error

DrByte:

The issue reported above for v1.3.0.x has already been implemented in v1.3.5. Note that the currently-released version is v1.3.7.

You're freaking me out, Dr. Byte. You've marked this thread "Done 1.3.8". :shocking:

Mary Ellen
I came; I saw; I Zenned
Taking over the world... one website at a time
Make sure brain is engaged before putting mouth in gear... or fingers to keyboard.

Holzheimer
Fan Odyssey

28 Feb 2007, 8:00 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: [Done v2.0.0] tpl_account_default.php HTML Error

dweingart:

Small HTML error in tpl_account_default.php in the #prevOrders table. The cell widths look like this:

<tr> <td width="70px"> <td width="30px"> <td> <td width="70px"> <td width="70px" align="right"> <td align="right"> </tr>

The width attributes shouldn't contain the string "px".

I did a search and couldn't find this mentioned anywhere else.

-dave> afo:

You're freaking me out, Dr. Byte. You've marked this thread "Done 1.3.8".

Oops ... actually, the changes to this template for cell-width are addressed in v1.4

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

28 Feb 2007, 8:09 PM
#6
afo avatar

afo

Totally Zenned

Join Date:
Aug 2004
Location:
New York City
Posts:
6,800
Plugin Contributions:
0

Re: [Done v2.0.0] tpl_account_default.php HTML Error

DrByte:

Oops ... actually, the changes to this template for cell-width are addressed in v1.4

Ah... ok... I'm not having a great day at work and seeing a number higher than the latest release confused me... not difficult today... off to do more debugging. :wacko:

Mary Ellen
I came; I saw; I Zenned
Taking over the world... one website at a time
Make sure brain is engaged before putting mouth in gear... or fingers to keyboard.

Holzheimer
Fan Odyssey