Guest Posted February 21, 2013 Posted February 21, 2013 Hi I have 2.3.3 and looking to make the content container slightly narrower, but for the life f me I can't find where this is done. I am also looking to make the left and right columns slightly wider. Any help would be greatly appreciated. Many thanks Grandpa
♥joli1811 Posted February 21, 2013 Posted February 21, 2013 Hi, includes/classes/osc_template.php This is a bit wider than normal 2 x 6 + 1 x 12 class oscTemplate { var $_title; var $_blocks = array(); var $_grid_container_width = 24; var $_grid_content_width = 12; var $_grid_column_width = 6; nice post http://www.oscommerce.com/forums/topic/369256-change-left-column-width/ Get you started :) regards Joli To improve is to change; to be perfect is to change often.
Guest Posted February 21, 2013 Posted February 21, 2013 Hi Thanks for that. I have already tried it, but not the result I'm looking for. Basically I want to increase the "gap" between the left column and the page content and also increase the "gap" between the right column and the page content.Thus making the Page Content a little narrower. (Hope that makes sense) Make the content a little narrower. I know there is somewhere where you can change the column widths by changing the pixels width ( I think) Many thanks for your help. Grandpa
burt Posted February 21, 2013 Posted February 21, 2013 /includes/template_top.php find: <div id="bodyContent" class="grid_<?php echo $oscTemplate->getGridContentWidth(); ?> <?php echo ($oscTemplate->hasBlocks('boxes_column_left') ? 'push_' . $oscTemplate->getGridColumnWidth() : ''); ?>"> change to: <div id="bodyContent" class="prefix_1 suffix_1 grid_<?php echo ($oscTemplate->getGridContentWidth()-2); ?> <?php echo ($oscTemplate->hasBlocks('boxes_column_left') ? 'push_' . $oscTemplate->getGridColumnWidth() : ''); ?>"> Lots more tips in the 233 design ebook. To change the width of the columns do exactly as @@joli1811 says.
ErikMM Posted February 21, 2013 Posted February 21, 2013 Hi Thanks for that. I have already tried it, but not the result I'm looking for. Basically I want to increase the "gap" between the left column and the page content and also increase the "gap" between the right column and the page content.Thus making the Page Content a little narrower. (Hope that makes sense) Make the content a little narrower. I know there is somewhere where you can change the column widths by changing the pixels width ( I think) Many thanks for your help. Grandpa you could just add padding as you want, it will make the page content narrower (as you want), and is the simplest solution: catalog/stylesheet.css .contentContainer { padding-bottom: 10px; padding-left: 10px; padding-right: 10px; } change px # as you wish it won't change or move the page or content headings/titles, they will stay as they are a-how-to-road-map 2.3.x road-map-for-the-newbies design basics how to make a horrible osC site ssl-how to updated-security-thread Web Developer, Firebug, and Notepad++ are powerful free tools for web design.
♥joli1811 Posted February 21, 2013 Posted February 21, 2013 @@burt Hi, I can only say to anyone interested in osc whether amateur or profi who would like to tweak the design a bit do take a look at the http://oscbooks.com/oscommerce-ebooks/designing_oscommerce_23x.php Not sure if I am allowed to post links does cost a tenner (£10) best money I spent in a long time <div id="bodyContent" class="prefix_1 suffix_1 grid_<?php echo ($oscTemplate->getGridContentWidth()-2); Just wondering what is the -2 ( maybe minus x 2 columns) because of the prefix/suffix ??? Regards Joli To improve is to change; to be perfect is to change often.
burt Posted February 21, 2013 Posted February 21, 2013 @@joli1811 Yes, exactly. So, take into account your first post as an example: var $_grid_content_width = 12; which is in the template class. We can now use this as so: $oscTemplate->getGridContentWidth() Instead, I say $oscTemplate->getGridContentWidth()-2 now, in this place only, the width is 10 (aka 12 less 2). However, we know that the width has to be 12, as this is set in the class, and the grid will break otherwise. So, taking what we know from the eBook, we can add suffix_1 prefix_1 to center align the 10 grid in a 12 grid space. Makes sense ?
♥joli1811 Posted February 21, 2013 Posted February 21, 2013 @@burt Yes bit like going back to school again but funny enough I do understand exactly what you are saying hehe. Took me about 2 x hours to understand the basics, after reading the e book / explanation about the grid in osCommerce very well written Like I said best money spent in a long time Guess I really do owe you a beer :thumbsup: regards Joli To improve is to change; to be perfect is to change often.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.