Jump to content

npn2531

Members
  • Content count

    1,159
  • Joined

  • Last visited

  • Days Won

    11

Everything posted by npn2531

  1. npn2531

    OSC to CSS v2

    Okay, I see you are using the cssinfobox class, you were just posting what you rewrote.
  2. npn2531

    OSC to CSS v2

    Your rewrite is fine, almost. I have it posted on the demo at www dot css-oscommerce dot com/ninesixty and it's good. What I have done is taken your code with the ordered list, removed the <div class="clear"></div>, and most importantly put the back the -> new cssinfoBox($info_box_contents);<- back in. Here is what I have on the demo. $info_box_contents = array(); if ($notification_exists == true) { $info_box_contents[] = array('text' => '<ol><li><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 . 'box_products_notifications_remove.gif', IMAGE_BUTTON_REMOVE_NOTIFICATIONS) . '</a> <a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=notify_remove', $request_type) . '">' . sprintf(BOX_NOTIFICATIONS_NOTIFY_REMOVE, tep_get_products_name($HTTP_GET_VARS['products_id'])) .'</a></li></ol>'); } else { $info_box_contents[] = array('text' => '<ol><li><a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=notify', $request_type) . '">' . tep_image(DIR_WS_IMAGES . 'box_products_notifications.gif', IMAGE_BUTTON_NOTIFICATIONS) . '</a><p><a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=notify', $request_type) . '">' . sprintf(BOX_NOTIFICATIONS_NOTIFY, tep_get_products_name($HTTP_GET_VARS['products_id'])) .'</a></p></li></ol>'); } new cssinfoBox($info_box_contents); } ?>
  3. npn2531

    OSC to CSS v2

    Post your section of the code from that box that follows: $info_box_contents = array(); I suspect all you have to do it remove a single div. When you rewrite that box the divs with the classes infobox_header, infobox and infoboxcontents are added by the programming and do not need to be in the infobox file itself. (that's what the "new cssinfoBox($info_box_contents); " is for)
  4. npn2531

    OSC to CSS v2

    I see where your trouble may be in rewriting the infoboxes. On the infoboxes, don't add any div classes within the box itself, those are added by the functions in includes/classes/boxes.php. For example in converting these to ordered lists as you are attempting above, just write it like this: $info_box_contents = array(); $info_box_contents[] = array('text' => '<ol><li><a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a></li>' . '<li><a href="' . tep_href_link('faqs.php') . '">' . 'Faqs' . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a></li></ol>');
  5. npn2531

    OSC to CSS v2

    PS - I already have img.infobox-cart{ padding-left:10px; } in styles.css in the infobox section
  6. npn2531

    OSC to CSS v2

    see if this works: // $customer_orders_string = '<table class="infobox">'; $products_query = tep_db_query("select products_id, products_name from " . TABLE_PRODUCTS_DESCRIPTION . " where products_id in (" . $product_ids . ") and language_id = '" . (int)$languages_id . "' order by products_name"); while ($products = tep_db_fetch_array($products_query)) { $customer_orders_string .= ' ' . ' <ol><li><a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products['products_id']) . '">' . $products['products_name'] . '</a>' . ' <a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=cust_order&pid=' . $products['products_id']) . '">' . tep_image(DIR_WS_ICONS . 'cart.gif','infobox cart','','',ICON_CART,'infobox-cart') . '</a></li></ol>' . ' '; } // $customer_orders_string .= '</table>'; $customer_orders_string .= '<div class="clear"></div>'; It on the demo like this now. Note also the image has a class, . infobox-cart Go to www dot css-oscommerce dot com/vtwo and you can see what the infoboxes look like a bit wider, but only one column. Those infoboxes are a bit narrow for something like order_history. If you sign on with a test account and place a couple of orders, you can see how that infobox looks like on account.php where I think it would be more useful anyway. img src="images/icons/cart.gif" class="infobox-cart" border="0" alt="infobox cart" title=" infobox cart " width="16" height="17" In Cart> and if you create a selector in the styles.css, img.infobox-cart you may be able to get that image to line up better.
  7. npn2531

    OSC to CSS v2

    They look good. Put these selectors in styles.css and you can override the default settings for ordered lists that is in text.css, with styling unique for the infoboxes. I took a bit of the left margin out, but there's still a bit between the number and the text. #column_left ol, #column_right ol { margin: 0.5em 0.5em 0.5em 1.5em; } #column_left li, #column_right li{ padding:0.0em; }
  8. npn2531

    OSC to CSS v2

    I appreciate you doing all this editing. When the smoke clears in a few days, I will repost the contribution with all these corrections.
  9. npn2531

    OSC to CSS v2

    This should fix the validation of includes/modules/cat-navbar.php and also includes/boxes/ul_categories.php. (cat-navbar.php is the horizontal version of ul_categories so the fix is the same in both files. in either file: change: // Close off nested lists for ($nest = 0; $nest <= $GLOBALS['this_level']; $nest++) { $output .= '</ul>'; } to this: // Close off nested lists for ($nest = 1; $nest <= $GLOBALS['this_level']; $nest++) { //closing tags for entire list $output .= '</ul></li></ul>'; }
  10. npn2531

    OSC to CSS v2

    I see the problem. I'm working on it.
  11. npn2531

    OSC to CSS v2

    cat-navbar: Are you sure there is an error? I have checked the demo, it works fine and there is a closing </li> everyplace it should be. Looking at the source code of your site, both the superfish and the categories infobox look good, and have all there closing </li>'s That cat-navbar is a direct adaptation from this contribution: http://addons.oscommerce.com/info/4201 and everything matches up against the original as well.
  12. npn2531

    OSC to CSS v2

    bestsellers list: Converting it to an ordered list from tables is a good idea, and it looks better on your site that it does on the demo. There is only one column in that table, so why not? However, note the information box is an unordered list. It would create visual consistency and cut down on the number of CSS selectors if those two boxes had identical classes and list types. (order_history, product_notifications and whats_new are other infoboxes that should match as well). Those are simple one or two column boxes similar to the bestsellers. I have converted a couple to divs, but now you have brought it up, I think they would be easier to work with if there was a consistent class, and an ordered or unordered list across this group. If you work on this and get them looking nice, post what you do.
  13. npn2531

    OSC to CSS v2

    XHTML Strict: using the higher standard will cut down on the IE discrepancies. Getting the border="0" out of the inline styling of the image is a good idea. It can be done for the entire shop in one place, includes/functions/html_output.php. About line 75 find the function, function tep_image, and down a few lines delete border="0" . In fact if you open up reset.css you can see that the border for 'img' (and everything else) is already set to '0' so deleting this should not affect anything at all. There is no need to add a new CSS selector border_0. The class for the image is a separate variable in that same function, and allows you to add a class directly in the image itself, and thus is quite useful. Look at the top of nearly all the catalog pages for this: <?php echo tep_image(DIR_WS_IMAGES . 'table_background_account.gif', HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT,'','stock-image'); ?> By adding 'stock-image' directly into the image, that image on that page acquires a class of 'stock-image'. In styles.css I have this selector: .stock-image{ display:none; } That's why none of the cartoonish stock images are showing up. OSCommerce is really a well written cart.
  14. npn2531

    OSC to CSS v2

    If you have to change anything to get this to validate to higher standards, post the change, I like to see it if can't be incorporated. Tables in manufacturers_info.php : I have left tables in where the shop presents data. A list of manufacturers with varying widths of names that wrap around in a short column in a chart with several columns, is one thing a table handles better than floating divs. The shopping cart is another example. You will see the CSS for styling these tables in the styles.css Currencies: Good catch. The currencies box I have posted is lacking the form. To fix it do two things: In styles.css change: #header .infobox_heading{ margin:-10px 0px 0px 0px; } to this: #header .infobox_heading{ margin:0px 0px 0px 0px; font-weight: normal; } and in includes/boxes/currencies.php just paste the following over everything in the box beneath the comments. This is the entire and correct code for the currencies box: if (isset($currencies) && is_object($currencies)) { ?> <!-- currencies --> <?php $info_box_contents = array(); $info_box_contents[] = array('text' => BOX_HEADING_CURRENCIES); new cssinfoBoxHeading($info_box_contents, false, false); reset($currencies->currencies); $currencies_array = array(); while (list($key, $value) = each($currencies->currencies)) { $currencies_array[] = array('id' => $key, 'text' => $value['title']); } $hidden_get_variables = ''; reset($HTTP_GET_VARS); while (list($key, $value) = each($HTTP_GET_VARS)) { if ( ($key != 'currency') && ($key != tep_session_name()) && ($key != 'x') && ($key != 'y') ) { $hidden_get_variables .= tep_draw_hidden_field($key, $value); } } $info_box_contents = array(); $info_box_contents[] = array('form' => tep_draw_form('currencies', tep_href_link(basename($PHP_SELF), '', $request_type, false), 'get'), 'text' => tep_draw_pull_down_menu('currency', $currencies_array, $currency, 'onChange="this.form.submit();" style="width: 80%"') . $hidden_get_variables . tep_hide_session_id()); new cssinfoBox($info_box_contents); } ?>
  15. npn2531

    OSC to CSS v2

    I noticed you had a successful w3 validation as well. Note that there is a single column (left or right) version about ready.
  16. npn2531

    OSC to CSS v2

    Whew! Thanks for working on this and spotting the issue. I'll get this fix posted on the contribution.
  17. npn2531

    OSC to CSS v2

    the demo site at ninesixty should look fine on your end now. I have changed the unordered list to line breaks.
  18. npn2531

    OSC to CSS v2

    On the information box includes/boxes/information.php, There is a typo. The closing /ul is missing the final >. If that doesn't fix it then just change the unordered list to just line breaks. There is a large default left margin on unordered lists. ie change this: '<div class="clear"></div><ul><li><a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a></li>' . '<li><a href="' . tep_href_link('faqs.php') . '">' . 'Faqs' . '</a></li>' . '<li><a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a></li></ul'); to this: '<div class="clear"></div><a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' . '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a><br>' . '<a href="' . tep_href_link('faqs.php') . '">' . 'Faqs' . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>');
  19. npn2531

    OSC to CSS v2

    We are crossing posts, I'll focus on infoboxes.
  20. npn2531

    OSC to CSS v2

    Before I get started, are you seeing this issue on all the pages, some of the pages, or just the index? try adding this to your stylesheet: .divider-tall{ clear:both; } That's left over from the old version and I see I didn't get them all, at least on the index page. That has been replaced by two selectors: .clear and .spacer In others words, class="divider-tall" should be class="clear spacer"
  21. npn2531

    OSC to CSS v2

    The grid 960 system has strict rules on about adding borders, margins, padding to the left and right. It only takes one pixel to stack things up. The fix will be finding the offending selector one of the stylesheets, most likely in styles.css. On one or maybe two selectors a left or right border, padding, margin, or a pixel too much width has been added where it shouldn't be. I will start working through styles.css and see if I can't find it. The technique will simply be to work down the stylesheet removing borders then, padding, margins or finally widths from the selectors and see what fixes it. Most likely a border. It is also not beyond the realm of possibility that the problem is in one of the stylesheets for the JQuery elements, but not likely. However, don't touch the 960.css stylesheet. It is the pure unadulterated stylesheet from 960.gs site.
  22. npn2531

    OSC to CSS v2

    In includes/classes/boxes.php the place to change is here, about line 76 class cssinfoBoxHeading extends csstableBox { function cssinfoBoxHeading($contents, $left_corner = true, $right_corner = true, $right_arrow = false) { $this->table_parameters = 'class="grid_2 alpha" '; if ($right_arrow == true) { $right_arrow = '<a href="' . $right_arrow . '">' . tep_image(DIR_WS_IMAGES . '../images/cssv2-arrow-right.png','arrow right','','',ICON_ARROW_RIGHT,'right_arrow') . '</a>'; } else { $right_arrow = ''; } : change the class="grid_2 alpha" to class="grid_4 alpha", or class="grid_3 alpha" This line below is not the place to change : $this->table_parameters = 'class="infobox"';
  23. npn2531

    OSC to CSS v2

    Each column is written to be 2 grid 'units' wide and the center column is 8 'units' wide. The enter site is 12 'units' Remove the right column, and the left and center are still 2 and 8 wide. You can easily change the width of the left column by doing the following: 1) open template_bottom.php, and as you have done comment out or remove the right column. However be sure you also comment out or remove the containing grid_2 div, ie remove all this: <div class="grid_2" id="column_right"> <?php require(DIR_WS_INCLUDES . 'column_right.php'); ?> </div><!--close column right--> 2) open template_top.php and change the class="grid_2" paired with the id-"column_left" to class="grid_4" ie it should end up looking like this: <div class="grid_4" id="column_left"> <?php require(DIR_WS_INCLUDES . 'column_left.php'); ?> </div> 3) finally you need to expand the infoboxes. Open up includes/classes/boxes.php find this about line 78: $this->table_parameters = 'class="grid_2 alpha" '; change to: $this->table_parameters = 'class="grid_4 alpha" '; This will give you a pretty wide left column. Not ideal proportions. To make the the column_left 3 units wide use 3 instead of 4 in the above instructions. Now, unfortunately, the center column is still 8 units wide. You will need to go through each catalog and module page and change each row of divs to be a combination of 9 units wide instead of 8 units wide. ( and in template_top.php change <div class="grid_8" id="content"> to <div class="grid_9" id="content">) I will be releasing a left_column (or right_column) grid_3, center section grid_9 version in about a week for those, like myself, who prefer only one column.
  24. npn2531

    OSC to CSS v2

    You can do what web developers have done since the dark ages. Isolate the situation and write a special rule in the stylesheet for IE that fixes that one glitch. In other words a CSS rule that all other browsers ignore. It is not really difficult to do. Here is a website that walks you through it: http://www.positioniseverything.net/articles/cc-plus.html or google 'IE' 'conditional statements' or similar. If you describe the problem and how I can observe it, I will see if I can't come up with something.
  25. npn2531

    OSC to CSS v2

    Change the doctype in application_top.php to : <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> That should help resolve the IE issue. It may nudge a header down a few pixels, though, and you may have to play with top padding in some of the header elements. Breadcrumbs: If you go to includes/header.php and give the breadcrumbs more room they may stop wrapping around. ie change: <!--Breadcrumbs --> <div class="grid_6 alpha"> to <!--Breadcrumbs --> <div class="grid_8 alpha"> and <!--currencies/manufacturers in header--> <div class="grid_3 push_3 omega"> to: <!--currencies/manufacturers in header--> <div class="grid_2 push_2 omega"> I see that you have the JQuery features working fine. That's a relief.
×