Jump to content

Archived

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

luigicosta

last question about the end of product info

Recommended Posts

well well I'm almost done editing the product info page

but now I remained the only thing left:

at the bottom of every product I have the purple bar with links that are all left and shifted much closer I have no idea what I can do ....

As always, every idea or suggestion find the door opened

thanks

 

 

http://www.footballshirtstar.com/product_info.php/maglia-calcio-inter-trasferta-stagione-2010-2011-p-32

 

 

 

P. S. for moderators can you correct the subject?

Share this post


Link to post
Share on other sites

in shopping_cart.php it looks good, compare the two pages.

 

note: I´m using an old g4 ibook and the screen is expanding to wide... lots of white space..

Share this post


Link to post
Share on other sites

Go to

 

http://validator.w3.org/

 

enter a site url for a product info page and check and repair all the 97 Errors, 37 warning(s)

 

Once cleaned up your site will be better. Then of course you will have to check every other page on your site.


REMEMBER BACKUP, BACKUP AND BACKUP

Get the latest Phoenix version here

It's easy to say to yes every question.

Share this post


Link to post
Share on other sites

What they will do is to let you know if you have any open divs and things, which help get your code right, and reduce errors on different browsers. Oscommerce passes in its default setup, so if it has errors it has to be some poor coding that has been added. Its not that hard to remove all the errors, or at least the important ones.


REMEMBER BACKUP, BACKUP AND BACKUP

Get the latest Phoenix version here

It's easy to say to yes every question.

Share this post


Link to post
Share on other sites

@@14steve14

 

I'll try .... however it is a shitty job

I do first to start again from scratch as I did and I can do it again better and error free ....

....maybe it's just a tag too much .... but where?

I feel like crying ....

Share this post


Link to post
Share on other sites

almost done..... :shifty: :shifty: (w00t)

<?php
/*
 $Id$
 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com
 Copyright (c) 2010 osCommerce
 Released under the GNU General Public License
*/
 require('includes/application_top.php');
 require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_PRODUCT_INFO);
 $product_check_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
 $product_check = tep_db_fetch_array($product_check_query);
 require(DIR_WS_INCLUDES . 'template_top.php');
 /*** Begin Header Tags SEO ***/ 
 echo "<a name=\"\$header_tags_array['title']\"></a>";
 /*** End Header Tags SEO ***/

if ($product_check['total'] < 1) {
?>
<div class="contentContainer">
 <div class="contentText">
   <?php echo TEXT_PRODUCT_NOT_FOUND; ?>
 </div>
 <div style="float: right;">
   <?php echo tep_draw_button(IMAGE_BUTTON_CONTINUE, 'triangle-1-e', tep_href_link(FILENAME_DEFAULT)); ?>
 </div>
</div>
<?php
 } else {
   /*** Begin Header Tags SEO ***/
   $product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id, pd.products_head_sub_text from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
   /*** End Header Tags SEO ***/
   $product_info = tep_db_fetch_array($product_info_query);
   tep_db_query("update " . TABLE_PRODUCTS_DESCRIPTION . " set products_viewed = products_viewed+1 where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and language_id = '" . (int)$languages_id . "'");
   if ($new_price = tep_get_products_special_price($product_info['products_id'])) {
  $products_price = '<del>' . $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) . '</del> <span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info['products_tax_class_id'])) . '</span>';
   } else {
  $products_price = $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id']));
   }
   if (tep_not_null($product_info['products_model'])) {
  $products_name = $product_info['products_name'];
   } else {
  $products_name = $product_info['products_name'];
   }
?>

<?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?>
<div>

 <h1><?php echo $products_name; ?></h1>
</div>

<div class="contentContainer">
 <div class="contentText">

<table width="100%" border="0" cellspacing="5" cellpadding="5">
 <tr>
   <td width="52%" align="center"><table border="0" cellspacing="5" cellpadding="0">
 <tr>
   <td width="10%"><!--- qui ce la foto -->
<div>
<table border="0" align="center" cellpadding="0" cellspacing="0">
 <tr>
   <td><img src="/images/sx_alt.gif"></td>
   <td background="/images/linea_top.gif"></td>
   <td><img src="/images/dx_alt.gif"></td>
 </tr>
 <tr>
   <td background="/images/linea_up_sx.gif"></td>
   <td align="center">
   <table width="5%" border="0" cellspacing="0" cellpadding="0" align="right">
 <tr>
   <td align="center"><div id="piGal" style="float: right;">
  <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), null, null, 'hspace="5" vspace="5"') . '</a>'; ?>
   </div></td>
 </tr>
 <tr>
   <td align="center">
 <?php
  if ($product_check['total'] >= 1) {
  include (DIR_WS_INCLUDES . 'products_next_previous.php');
  }
  ?>
  </td>
 </tr>



</table></td>
   <td background="/images/linea_up_dx.gif"></td>
 </tr>
 <tr>
   <td><img src="/images/sx_bot.gif"></td>
   <td background="/images/linea_bot.gif"></td>
   <td><img src="/images/dx_bot.gif"></td>
 </tr>
</table>
</div>
<?php
  }
?>
<script type="text/javascript">
$("#piGal a[rel^='fancybox']").fancybox({
 cyclic: true
});
</script></td>
   <td align="center"></td>
 </tr>
</table>
</td>
   <td width="48%"><table width="100%"border="0" cellspacing="5" cellpadding="5">
 <tr>
   <td align="center"><div class="contentText">
 <br>
<div class="contentContainer">
 <div class="contentText">
<?php
   if (tep_not_null($product_info['products_image'])) {
  $pi_query = tep_db_query("select image, htmlcontent from " . TABLE_PRODUCTS_IMAGES . " where products_id = '" . (int)$product_info['products_id'] . "' order by sort_order");
  if (tep_db_num_rows($pi_query) > 0) {
?>
   <div id="piGal" style="float: right;">
  <ul>
<?php
    $pi_counter = 0;
    while ($pi = tep_db_fetch_array($pi_query)) {
	  $pi_counter++;
	  $pi_entry = '	    <li><a href="';
	  if (tep_not_null($pi['htmlcontent'])) {
	    $pi_entry .= '#piGalimg_' . $pi_counter;
	  } else {
	    $pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image']);
	  }
	  $pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';
	  if (tep_not_null($pi['htmlcontent'])) {
	    $pi_entry .= '<div style="display: none;"><div id="piGalimg_' . $pi_counter . '">' . $pi['htmlcontent'] . '</div></div>';
	  }
	  $pi_entry .= '</li>';
	  echo $pi_entry;
    }
?>
  </ul>
   </div>
<script type="text/javascript">
$('#piGal ul').bxGallery({
 maxwidth: 300,
 maxheight: 200,
 thumbwidth: <?php echo (($pi_counter > 1) ? '75' : '0'); ?>,
 thumbcontainer: 300,
 load_image: 'ext/jquery/bxGallery/spinner.gif'
});
</script>
<?php
  } else {
?>
<?php
   }
?>

<div style="float: left; font-size: 24px; font-weight: bold; color: green; padding: 15px 0px 10px 10px;"><?php echo $products_price; ?> </div>
<div style="float: left; width: 336px; height: 64px;  padding: 0px 0px 0px 0px; background-image: url(/images/add-to-cart-bg.png);">
<div style="float: left; font-size: 12px; font-weight: bold; padding: 24px 0px 0px 0px;"> Quantita'  <?php echo tep_draw_input_field('cart_quantity', '1', 'size=2'); ?></div>
<div style="float: left; width: 49px; height: 32px; padding: 0px 0px 20px 0px; background-image: url/images/backgrounds/qty-field-bg.png);">
<div style="float: left; width: 206px; height: 52px; padding: 9px 0px 0px 15px;"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('buy-button.png'); ?></div>
</div>
</div>



 <table width="100%" border="0" cellspacing="7" cellpadding="7">
   <tr>
  <td><div style="float: left; padding: 10px 2px 3px;"><?php echo tep_image(DIR_WS_IMAGES . '/downArrow.png');?></div>
   <div style="float: left; font-weight: bold; font-size: 12px; padding-top: 5px;">DESCRIZIONE</div></td>

   </tr>
   <tr><td><?php echo stripslashes($product_info['products_description']); ?></td></tr>
 </table>


 <table width="100%" border="0" cellspacing="5" cellpadding="5">
   <tr>
  <td width="34%"><?php
   $products_attributes_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "'");
   $products_attributes = tep_db_fetch_array($products_attributes_query);
   if ($products_attributes['total'] > 0) {
?>

   <p>
<?php
  $products_options_name_query = tep_db_query("select distinct popt.products_options_id, popt.products_options_name from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "' order by popt.products_options_name");
  while ($products_options_name = tep_db_fetch_array($products_options_name_query)) {
    $products_options_array = array();
    //<!-- AJAX Attribute Manager -->
    $products_options_query = tep_db_query("select pov.products_options_values_id, pov.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " pa, " . TABLE_PRODUCTS_OPTIONS_VALUES . " pov where pa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pa.options_id = '" . (int)$products_options_name['products_options_id'] . "' and pa.options_values_id = pov.products_options_values_id and pov.language_id = '" . (int)$languages_id . "' order by pa.products_options_sort_order");
//<!-- AJAX Attribute Manager end -->
    while ($products_options = tep_db_fetch_array($products_options_query)) {
	  $products_options_array[] = array('id' => $products_options['products_options_values_id'], 'text' => $products_options['products_options_values_name']);
	  if ($products_options['options_values_price'] != '0') {
	    $products_options_array[sizeof($products_options_array)-1]['text'] .= ' (' . $products_options['price_prefix'] . $currencies->display_price($products_options['options_values_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) .') ';
	  }
    }
    if (is_string($HTTP_GET_VARS['products_id']) && isset($cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']])) {
	  $selected_attribute = $cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']];
    } else {
	  $selected_attribute = false;
    }
?>
  <strong><?php echo $products_options_name['products_options_name'] . ':'; ?></strong><br /><?php echo tep_draw_pull_down_menu('id[' . $products_options_name['products_options_id'] . ']', $products_options_array, $selected_attribute); ?><br />
<?php
  }
?>
   </p>
<?php
   }
?></td>
  <td width="33%" align="center"><div style="float: left; padding: 10px 10px 0px;"><?php echo '<a href="' . tep_href_link(FILENAME_TELL_A_FRIEND, 'products_id=' . $HTTP_GET_VARS['products_id'], 'NONSSL') . '">' . tep_image(DIR_WS_IMAGES . '/tell a friend.jpg') . '</a>'; ?></div></td>
  <td width="33%" align="center"><div style="float: left; padding: 10px 10px 0px;"><?php
   echo '<a href="' . tep_href_link( 'pdf_datasheet.php', 'products_id=' . ( int )$_GET['products_id'] . '&language=' . $language ) . '" alt="' . TEXT_DOWNLOAD_PDF . '" title="' . TEXT_DOWNLOAD_PDF . '">' . tep_image( DIR_WS_ICONS . 'Print_Page-44x44.png', TEXT_DOWNLOAD_PDF ) . '</a>';
?></div></td>
   </tr>
 </table>
 <table width="100%" border="0" cellspacing="5" cellpadding="5">
 <tr>
   <td align="center"><?php echo tep_image(DIR_WS_IMAGES . '/stars_5.gif');?></td>
   <td align="center">
   <td align="center">    <?php
   // BOF Reviews at Product Page
   echo tep_draw_button(IMAGE_BUTTON_WRITE_REVIEW, 'comment', tep_href_link(FILENAME_PRODUCT_REVIEWS_WRITE, tep_get_all_get_params()), 'primary');
   // EOF Reviews at Product Page
   ?>
 </div>

  </td>
  </td>
   <td align="center"><?php echo '<span class="smallText">[' . $product_info['products_model'] . ']</span>';?></td>
 </tr>
</table>
</div>
<br>
   <div style="clear: both;"><span class="contentText"></span></div>
  <?php
  if ($product_info['products_quantity'] == 0) {
  if (tep_session_is_registered('customer_id')) {
  $check_query = tep_db_query("select count(*) as count from " . TABLE_PRODUCTS_NOTIFICATIONS . " where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and customers_id = '" . (int)$customer_id . "'");
  $check = tep_db_fetch_array($check_query);
  $notification_exists = (($check['count'] > 0) ? true : false);
  } else {
  $notification_exists = false;
  }
  echo sprintf(TEXT_DATE_AVAILABLE, tep_date_long($product_info['products_date_available'])),'<br><br>';
  if ($notification_exists == true) {
  echo '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=notify_remove', $request_type) . '">' . tep_image(DIR_WS_IMAGES . '/no_disponibile.jpg') . '</a>';
  } else {
  echo '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=notify', $request_type) . '">' . tep_image(DIR_WS_IMAGES . '/no_disponibile.jpg') . '</a>';
  }
  }  else {

  }	  ?>
  <BR>
<?php
   if ($product_info['products_date_available'] > date('Y-m-d H:i:s')) {
?>
<?php
   }
?>
 </div></td>
 </tr>
</table></td>
 </tr>
</table>
 <div class="buttonSet">
   <span class="buttonAction"></span>

 </div>
  <!--- BEGIN Header Tags SEO Social Bookmarks -->
  <?php
  if (tep_not_null($product_info['products_head_sub_text'])) {
	  echo '<div class="contentText" style="margin-top:5px; text-align:center;">' . $product_info['products_head_sub_text'] . '</div>';
  }
  ?>   
  <!--- BEGIN Header Tags SEO Social Bookmarks -->
  <?php
  if (HEADER_TAGS_DISPLAY_SOCIAL_BOOKMARKS == 'true') {
		    echo '<div style="margin-top:5px;">';
	 include(DIR_WS_MODULES . 'header_tags_social_bookmarks.php');
	 echo '</div>';
  }
  ?>
  <!--- END Header Tags SEO Social Bookmarks -->	 
<?php
   if ((USE_CACHE == 'true') && empty($SID)) {
  echo tep_cache_also_purchased(3600);
   } else {
  include(DIR_WS_MODULES . FILENAME_ALSO_PURCHASED_PRODUCTS);
   }
?>

   <?php
	    // BOF Reviews at Product Page
	    include(DIR_WS_MODULES . FILENAME_REVIEWS_FRONT);
	    // EOF Reviews at Product Page
 ?>
   <?php
 $reviews_query = tep_db_query("select count(*) as count from " . TABLE_REVIEWS . " where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and reviews_status = 1");
 $reviews = tep_db_fetch_array($reviews_query);
 ?>


  <?php /*** Begin Header Tags SEO ***/
  if (tep_not_null($product_info['products_head_sub_text'])) {
	  echo '<tr><td><table border="0" cellpadding="0"><tr><td class="hts_sub_text"><div>' . $product_info['products_head_sub_text'] . '</div></td></tr></table></td></tr>';
  }
  if (HEADER_TAGS_DISPLAY_CURRENTLY_VIEWING == 'true') {
	  echo '<tr><td>' . tep_draw_separator('pixel_trans.gif', '100%', '10') . '</td></tr>';
	  echo '<tr><td align="center"><table border="0" cellpadding="0"><tr><td class="smallText" align="center">' .TEXT_VIEWING . ' ';
	  if (! tep_not_null($header_tags_array['title'])) $header_tags_array['title'] = $product_info['products_name'];
	  echo '<a title="' . $header_tags_array['title'] . '" href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $product_info['products_id'], 'NONSSL') . '"/# ' . $header_tags_array['title'] . '">' . $header_tags_array['title'] . '</a>';
	  echo '</td></tr></table></td></tr>';
	  echo '<tr><td>' . tep_draw_separator('pixel_trans.gif', '100%', '10') . '</td></tr>';
  }
  /*** End Header Tags SEO ***/
  ?>
</div>

</form>
 <!-- Begin Sitemap SEO-->
 <script type='text/javascript' src='javascript/sitemap_seo.js'></script>
 <?php
 require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_SITEMAP_SEO);
 include(DIR_WS_MODULES . FILENAME_SITEMAP_SEO_PRODUCT);
 include(DIR_WS_MODULES . FILENAME_SITEMAP_SEO_CATEGORY);
 include(DIR_WS_MODULES . FILENAME_SITEMAP_SEO_MANUFACTURERS);
 ?>
  <br><br>
 <!-- End Sitemap SEO -->
<?php
 }
 require(DIR_WS_INCLUDES . 'template_bottom.php');
 require(DIR_WS_INCLUDES . 'application_bottom.php');
?>

Share this post


Link to post
Share on other sites

×