[TEP-COMMIT] CVS: catalog/catalog checkout_confirmation.php,1.141,1.142 checkout_payment.php,1.115,1.116 stylesheet.css,1.57,1.58

Harald Ponce de Leon <[email protected]>
Newsgroups gmane.comp.web.oscommerce.cvs
Message-ID <[email protected]>
Update of /cvsroot/tep/catalog/catalog
In directory sc8-pr-cvs1:/tmp/cvs-serv17341

Modified Files:
	checkout_confirmation.php checkout_payment.php stylesheet.css 
Log Message:
update the layout of the messagestack output messages


Index: checkout_confirmation.php
===================================================================
RCS file: /cvsroot/tep/catalog/catalog/checkout_confirmation.php,v
retrieving revision 1.141
retrieving revision 1.142
diff -u -d -r1.141 -r1.142
--- checkout_confirmation.php	3 Dec 2003 17:32:52 -0000	1.141
+++ checkout_confirmation.php	4 Dec 2003 14:12:16 -0000	1.142
@@ -47,9 +47,7 @@
 
   if (DISPLAY_CONDITIONS_ON_CHECKOUT == 'true') {
     if (!isset($_POST['conditions']) || ($_POST['conditions'] != '1')) {
-      $messageStack->add_session('checkout_conditions', ERROR_CONDITIONS_NOT_ACCEPTED, 'error');
-
-      tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
+      $messageStack->add_session('checkout_payment', ERROR_CONDITIONS_NOT_ACCEPTED, 'error');
     }
   }
 
@@ -62,8 +60,12 @@
 
   $payment_modules->update_status();
 
-  if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {
-    tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
+  if ( (is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !isset($$payment)) || (isset($$payment) && is_object($$payment) && ($$payment->enabled == false)) ) {
+    $messageStack->add_session('checkout_payment', ERROR_NO_PAYMENT_MODULE_SELECTED, 'error');
+  }
+
+  if ($messageStack->size('checkout_payment') > 0) {
+    tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
   }
 
   if (is_array($payment_modules->modules)) {

Index: checkout_payment.php
===================================================================
RCS file: /cvsroot/tep/catalog/catalog/checkout_payment.php,v
retrieving revision 1.115
retrieving revision 1.116
diff -u -d -r1.115 -r1.116
--- checkout_payment.php	3 Dec 2003 17:32:53 -0000	1.115
+++ checkout_payment.php	4 Dec 2003 14:12:16 -0000	1.116
@@ -72,6 +72,10 @@
   require(DIR_WS_CLASSES . 'payment.php');
   $payment_modules = new payment;
 
+  if (isset($_GET['payment_error']) && is_object(${$_GET['payment_error']}) && ($error = ${$_GET['payment_error']}->get_error())) {
+    $messageStack->add('checkout_payment', $error['error'], 'error');
+  }
+
   require(DIR_WS_LANGUAGES . $osC_Session->value('language') . '/' . FILENAME_CHECKOUT_PAYMENT);
 
   $breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
@@ -150,27 +154,10 @@
         <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
       </tr>
 <?php
-  if (isset($_GET['payment_error']) && is_object(${$_GET['payment_error']}) && ($error = ${$_GET['payment_error']}->get_error())) {
+  if ($messageStack->size('checkout_payment') > 0) {
 ?>
       <tr>
-        <td><table border="0" width="100%" cellspacing="0" cellpadding="2">
-          <tr>
-            <td class="main"><b><?php echo tep_output_string_protected($error['title']); ?></b></td>
-          </tr>
-        </table></td>
-      </tr>
-      <tr>
-        <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBoxNotice">
-          <tr class="infoBoxNoticeContents">
-            <td><table border="0" width="100%" cellspacing="0" cellpadding="2">
-              <tr>
-                <td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
-                <td class="main" width="100%" valign="top"><?php echo tep_output_string_protected($error['error']); ?></td>
-                <td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
-              </tr>
-            </table></td>
-          </tr>
-        </table></td>
+        <td><?php echo $messageStack->output('checkout_payment'); ?></td>
       </tr>
       <tr>
         <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
@@ -179,16 +166,6 @@
   }
 
   if (DISPLAY_CONDITIONS_ON_CHECKOUT == 'true') {
-    if ($messageStack->size('checkout_conditions') > 0) {
-?>
-      <tr>
-        <td><?php echo $messageStack->output('checkout_conditions'); ?></td>
-      </tr>
-      <tr>
-        <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
-      </tr>
-<?php
-    }
 ?>
       <tr>
         <td><table border="0" width="100%" cellspacing="0" cellpadding="2">

Index: stylesheet.css
===================================================================
RCS file: /cvsroot/tep/catalog/catalog/stylesheet.css,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- stylesheet.css	23 Jul 2003 15:31:35 -0000	1.57
+++ stylesheet.css	4 Dec 2003 14:12:16 -0000	1.58
@@ -19,6 +19,8 @@
   background: #ffffff;
   color: #000000;
   margin: 0px;
+  font-family: Verdana, Arial, sans-serif;
+  font-size: 10px;
 }
 
 A {
@@ -289,3 +291,12 @@
 /* input requirement */
 
 .inputRequirement { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #ff0000; }
+
+.messageStack {
+  margin: 5px;
+  font-size: 10px;
+  color: #465584;
+  background-color: #FFFCF5;
+  border-width: 1px;
+  border-style: dotted;
+}



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.