Jump to content
DiamondSea

[contribution] Simple Template System (sts)

Recommended Posts

hello again

I just got dynamenu worked. According to bill's post in the dynamenu thread.

 

Removing the "box" variable from the STS tag code.

 

Change this:

  $sts->restart_capture ('manufacturerbox', 'box');require(DIR_WS_BOXES . 'dm_categories.php');
 $sts->restart_capture('dmbox', 'box'); // Get Dynamenu Category box

 

To this:

  $sts->restart_capture ('manufacturerbox', 'box');require(DIR_WS_BOXES . 'dm_categories.php');
 $sts->restart_capture('dmbox'); // Get Dynamenu Category box

Share this post


Link to post
Share on other sites

what is the best way to center shop for STS?

I put a table in template.html then put the whole page inside the table. set a table width. set table backgound color to be different than website background.

is this good?

Share this post


Link to post
Share on other sites
Dear All, got few questions regarding the modification of template layout, please kindly help!

 

1. In Shopping Cart infobox, the line spacing between products were too tight, so I add a "line-height: 20px;" to CSS style "infoBoxContents", the line spacing is great after that, however, if the product name is too long then it will break into 2 lines, the line spacing for this product will then look so strange, what I can do to avoid this? I would like to keep some spacing for each product but not for a single product name.

 

2. how to change the color of the balck 1 pixel line over the price?

 

3. how to change the CSS for the price?

 

4. I would like to remove the box (blue area in my example) that surrounding the language flags, I asked the same question 2 days ago but I still couldn't figure out how to do that. I deleted everything except "$content" in infobox_languages.php.html, I also tried to add a css style to constraint the height and padding but didn't work. I am not sure if that "box" code is located at cataglue/includes/boxes/languages.php, I dont know scripting so I don't know how to modify it.

 

Please kindly help if you have any idea, thank you very much!!

 

All of this is done by editing your stylesheet. Look at my tip on how to find out what is what regarding CSS and table backgrounds:

http://forums.oscommerce.com/index.php?s=&...t&p=1213285


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites
Hi! thank you so much for your reply. I will go through your messages and try to find the solution. thanks!

 

Use the link that I provided and you will not have to search through all of the messages.

Hope this helped,


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites
Use the link that I provided and you will not have to search through all of the messages.

Hope this helped,

 

I am a bit confusing about the link.

 

When I click on that link you've gave me, I go to page 36 of "[Contribution] STS v4 by user rigadin2", I could see a lot of questions and replies but I don't know which one you are referring to...I've spent some time reading some of your replies but I think that's not a efficient way for me to find out my answer...

 

If I copy and paste your link to the browser, it goes to the top page of osCommerce Community Support Forums.

 

Please advise, thanks again.

Share this post


Link to post
Share on other sites
I am a bit confusing about the link.

 

When I click on that link you've gave me, I go to page 36 of "[Contribution] STS v4 by user rigadin2", I could see a lot of questions and replies but I don't know which one you are referring to...I've spent some time reading some of your replies but I think that's not a efficient way for me to find out my answer...

 

If I copy and paste your link to the browser, it goes to the top page of osCommerce Community Support Forums.

 

Please advise, thanks again.

 

Simply click on the link (don't copy/paste) and it will take you to post # 3549 which describes a tool to use in your browser when viewing your osCommerce site to tell what CSS styles are being used for whatever you need to edit.

 

Firefox actually has the same tool but it also allows you to edit the CSS "live" and then afterwards copy and paste the resulting CSS edits into your osCommerce stylesheet to upload to your site.


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites

I have 4.5.8 & Header Tag Seo installed. I want to change category page heading.

 

FROM THIS

2h4essw.jpg

 

TO THIS:

31681f9.jpg

 

 

All these are inside of $content so I don't know what to do.

Should I do this in STS or edit some code of index.php or other files?

 

Thanks in advance for any help.

Edited by nudylady

Share this post


Link to post
Share on other sites

Hi bkellum, thank you for your help!!

 

I don't know why I couldn't see the post #3549, but anyway I installed the firefox CSS plugin, and it is a great tool.

 

I still have questions that I don't know how to solve, I tried to find solutions myself but failed, please see if you can offer me some help.

 

question2.jpg

 

1. In Shopping cart infobox, I assigned a line-height property for products in the cart, but in case of long product name (eg. SWAT 3: Close Quarters Battle), the name will break into 2 lines, the gap is too big for one single product name. I tried to make the line-height smaller and apply a bottom-margin for space between product names, but I couldn't make it, just wonder if there is any CSS property that can solve this problem.

 

2. In Shopping cart infobox, the "total price" has the same CSS property (.boxtext) with the quantity number of categories infobox, I would like to know how to assign a specific CSS for the "total price " field.

 

3. For language infobox, I could change the blue box to white by CSS but that's not what I want, I want to take away the blue box thing, I just want to have 2 flags in the layout.

 

4. For "$content" of index page (New Products For September box), is it possible to edit this part by STS? Are those related script located at index.php? Since I don't know scripting, I just don't know how to modify the layout of it. I tried to remove the $content and insert my html layout into the index template, but all products become not functioning.

 

5. I installed "additional images" and "lightbox effect" for the product info page, and I found that I can't use these 2 functions if I use a STS layout for the product info page, is there any solution for that?

 

My english is not so good, hope you understand what I mean. Thank you for your kindly help!

Share this post


Link to post
Share on other sites

Hello,

 

I'm trying to get this store up and running soon. I have looked for this everywhere and everyone's suggestions don't seem to help. Does anyone know how I can get this to work.

 

My product images are not showing up: http://www.letsjustprint.com/index.php

 

Under login.php - There is no button for a user to register for an account.

 

Under shopping_cart.php - There is no Check Out button

 

If anyone could please help me out I would greatly appreciate it!

 

Thank you!

 

define('HTTP_SERVER', 'http://www.letsjustprint.com');
 define('HTTP_CATALOG_SERVER', 'http://www.letsjustprint.com');
 define('HTTPS_CATALOG_SERVER', 'https://www.letsjustprint.com');
 define('ENABLE_SSL_CATALOG', 'true');
 define('DIR_FS_DOCUMENT_ROOT', '/');
 define('DIR_WS_ADMIN', '/admin/');
 define('DIR_FS_ADMIN', '/home/letsjust/public_html/admin/');
 define('DIR_WS_CATALOG', '/');
 define('DIR_FS_CATALOG', '/home/letsjust/public_html/');
 define('DIR_WS_IMAGES', 'images/');
 define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
 define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
 define('DIR_WS_INCLUDES', 'includes/');
 define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
 define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
 define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
 define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
 define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
 define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
 define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
 define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

 

 

I have tried all of the following:

 

My buttons seem to be at this location: (https://www.letsjustprint.com/includes/sts_templates/carbon-blue/images/english/buttons/button_login.gif)

 

Setting Permissions on Folders - Images - 775 English - 775 Buttons - 775 button_login.gif - 644

 

I tried deleting the .htacess in the includes folder.

 

Someone suggested: in includes/application_top.php

Before:

$request_type = (getenv('HTTPS') == 'on') ? 'SSL' : 'NONSSL';

 

After:

$request_type = (getenv('HTTPS') == 'off') ? 'SSL' : 'NONSSL';

 

That didn't work so I switched it back to "on"

 

 

As far as seeing this pictures in the admin section; I can def. see them and upload them. The only problem is in the actual online store.

 

Product image name and file format is like this: For the buttons: button_checkout.gif (this button does not show): button_continue.gif (this button does show) and for the products I use bizcards.jpg

 

includes/configure.php

define('HTTP_SERVER', 'http://www.letsjustprint.com');
 define('HTTPS_SERVER', 'https://www.letsjustprint.com');
 define('ENABLE_SSL', true);
 define('HTTP_COOKIE_DOMAIN', 'www.letsjustprint.com');
 define('HTTPS_COOKIE_DOMAIN', 'www.letsjustprint.com');
 define('HTTP_COOKIE_PATH', '/');
 define('HTTPS_COOKIE_PATH', '/');
 define('DIR_WS_HTTP_CATALOG', '/');
 define('DIR_WS_HTTPS_CATALOG', '/');
 define('DIR_WS_IMAGES', 'images/');
 define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
 define('DIR_WS_INCLUDES', 'includes/');
 define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
 define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
 define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
 define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
 define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

 define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');
 define('DIR_FS_CATALOG', '/home/letsjust/public_html/');
 define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
 define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

 

admin/includes/configure.php

  define('HTTP_SERVER', 'http://www.letsjustprint.com');
 define('HTTP_CATALOG_SERVER', 'http://www.letsjustprint.com');
 define('HTTPS_CATALOG_SERVER', 'https://www.letsjustprint.com');
 define('ENABLE_SSL_CATALOG', 'true');
 define('DIR_FS_DOCUMENT_ROOT', '/home/letsjust/public_html/');
 define('DIR_WS_ADMIN', '/admin/');
 define('DIR_FS_ADMIN', '/home/letsjust/public_html/admin/');
 define('DIR_WS_CATALOG', '/');
 define('DIR_FS_CATALOG', '/home/letsjust/public_html/');
 define('DIR_WS_IMAGES', 'images/');
 define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
 define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
 define('DIR_WS_INCLUDES', 'includes/');
 define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
 define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
 define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
 define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
 define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
 define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
 define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
 define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

 

 

Hope this information helps!

 

Thank you in advance!

Share this post


Link to post
Share on other sites

for the above Post #5243.

1. line-height: 1.0em;

3. For language infobox, blue box is background color, you can delete background: #color; in css.

5. I tried lightbox before. together with STS is not good.

Edited by nudylady

Share this post


Link to post
Share on other sites

Hi everyone,

 

I was adviced to have a look at STS with my problem and I'm glad that I've done it but..

I still can't manage something. Let me show you what I'm trying to do.

I've got a website with existing database (which can be easly rebuild for OSC). Website has three vertical divs. Middle one is of course for the content, but that's not a problem (yet:P). First problem is that on the left I've got a div with category list. On the right there's a div where shopping cart and search engine meant to be. Both side divs have different sizes. Problem is with making everything look like I want to. But when I'll change infobox for category list, that it's ruining shopping basket. I can't use percentage tables. How to assign different styles to those divs? I'm a noob, I know, but it's important for me as I'm still learning and once I'll see how something is working, then it's easy.

 

Other problem is with displaying product lists. I can see, that there's a product_info for detailed information about the product, but my client doesn't want to have it. He rather want to have the list of the products and "Add to basket" button. The question is how to add a module and edit it my way? I've read the manual, but there's no information for noobs like me. Probably the same will be with viewing basket and checkout page.

 

Oh and one more thing. It there a way to not require from users to register? It's a shop where you honestly won't go back too soon..

 

Thanks for your help.

 

PS.

I've searched the topic, but there are too many posts and it's really hard to find a solution..

Share this post


Link to post
Share on other sites
for the above Post #5243.

1. line-height: 1.0em;

3. For language infobox, blue box is background color, you can delete background: #color; in css.

5. I tried lightbox before. together with STS is not good.

 

 

STS and Lightbox work perfectly well together. As with all things, you have to understand the principal of how lightbox works in order to configure it correctly.


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites

Hello,

 

I'm totally lost....

Can anybody help me to get rid of the left and right tablecell in the box-headers?

For explanation see image.

 

forum-image.jpg

 

Many many thanks in return for the one who can help me with this!

 

Greetz,

Joop

Share this post


Link to post
Share on other sites
Hello,

 

I'm totally lost....

Can anybody help me to get rid of the left and right tablecell in the box-headers?

For explanation see image.

 

forum-image.jpg

 

Many many thanks in return for the one who can help me with this!

 

Greetz,

Joop

 

Well, that depends. Are you using the Infobox template feature in STS? If so, then read up on the following posts:

http://forums.oscommerce.com/index.php?sho...p;#entry1227769

 

Also, the following posts may be of use to you in the future:

Important Posts for the STS newbie:

 

Post #3755: http://forums.oscommerce.com/index.php?sho...p;#entry1226986

 

Post #4326: http://forums.oscommerce.com/index.php?sho...p;#entry1303555

 

Post #4974: http://forums.oscommerce.com/index.php?sho...p;#entry1361366

 

Post #3772: http://forums.oscommerce.com/index.php?sho...p;#entry1227769

 

Post #3757: http://forums.oscommerce.com/index.php?sho...p;#entry1227006

 

Please review the above for insight on how the Simple Template System allows you to make templates for pages, categories, home page, products and infoboxes.

 

Hope this was helpful,


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites
Hello,

 

I'm totally lost....

Can anybody help me to get rid of the left and right tablecell in the box-headers?

For explanation see image.

 

Many many thanks in return for the one who can help me with this!

 

Greetz,

Joop

 

you find a file pixel_trans.gif in images\. Rename it to corner_left.gif,corner_right.gif,corner_right_left.gif,arrow_right.gif. put the 4 files in catalog\images\infobox

Share this post


Link to post
Share on other sites
Well, that depends. Are you using the Infobox template feature in STS? If so, then read up on the following posts:

http://forums.oscommerce.com/index.php?sho...p;#entry1227769

.....

 

Hope this was helpful,

 

Hi Bill,

 

Thanks for your reply, but I can't figure out how to do it... (I know I'm an *ss)

I've started with the full template, and use the template for infoboxes.

After that I deleted the left and right TD's in the infobox.php.html

Still those two TD's show up.....

What am i doing wrong here.

 

Greetz,

Joop (a total n00b)

Share this post


Link to post
Share on other sites

Extra Images don't show up in product_info.php.html but they do show up in the default.

 

Is there something I need to add/edit somewhere to get it to show up when using product_info.php.html?

 

Or can you tell me how to edit the ugly default product layout that does show the Extra Images?

 

Thank you.

 

Kathy

Share this post


Link to post
Share on other sites
Now if you want to place the welcome string in your STS Template where you want the $greeting string (that is called in general.php) just add the following TO YOUR TEMPLATE PAGE:

 

 

<td class="main"><?php echo tep_customer_greeting(); ?></td>

 

Note: The above is within a table cell (td) so you can modify that to however you want.

 

Also: You will need to modify the HTML Table tags above to meet your needs in your template.

 

NOTE: Since version 4, STS Templates can now include PHP coding that is why I suggested commenting the tag in index.php and relocating it in your template if you wanted to. You could have also created a new STS tag for the welcome text in the sts_user_code.php file but it is just as easy to place it in your template directly.

 

Hope this was useful,

 

hello bill

How to create a STS tag for welcome text in the sts_user_code.php?

I only have template for new placeholder for a box. But this time it is line of text with customer name if logged in. I am lost.

Edited by nudylady

Share this post


Link to post
Share on other sites
If your layout is a purchased template for osCommerce, see the following step by step guied on how to convert to a STS template:

http://forums.oscommerce.com/index.php?sho...p;#entry1131089

 

Hi Bill

 

A while back you posted this link and I would like to read up on how to integrate a "bought" template into STS - however the link doesn't seem to lead to the right place -

 

Can you please re-post the link to the guide?

 

TIA

Sol

Share this post


Link to post
Share on other sites

Hi Everyone. I want to edit the $content of the index page by STS, I asked the same question in my previous message but I got no reply, I did tried to find solution myself but failed, I really need to get the layout fixed for the deadline, please help me if you have any clues for that, Thank you very much.

 

question3.jpg

Share this post


Link to post
Share on other sites

for the contribution: rss feed 2.2 - http://addons.oscommerce.com/info/1513

the install.txt says that i have to put this code in every pages of the catalog, befote the </head>

 

where should i put this code to sts?

 

	<?php
  if (!isset($lng) || (isset($lng) && !is_object($lng))) {
    include_once(DIR_WS_CLASSES . 'language.php');
    $lng = new language;
  }

  reset($lng->catalog_languages);
  while (list($key, $value) = each($lng->catalog_languages)) {
?>
        <link rel="alternate" type="application/rss+xml" title="<?php echo STORE_NAME . ' - ' . BOX_INFORMATION_RSS; ?>" href="<?php echo FILENAME_RSS, '?language=' . $key.((isset($_GET['cPath']))?'&cPath='.$_GET['cPath']:'').((isset($_GET['manufacturers_id']))?'&manufacturers_id='.$_GET['manufacturers_id']:''); ?>">
         <?php
         }
         ?>

 

thanks!

Share this post


Link to post
Share on other sites
5. I installed "additional images" and "lightbox effect" for the product info page, and I found that I can't use these 2 functions if I use a STS layout for the product info page, is there any solution for that?

 

You can use both very well, you just need to have the right tags defined and of course you need to place them into your product_info template.

What exactly is the problem?

Share this post


Link to post
Share on other sites
Hi Everyone. I want to edit the $content of the index page by STS, I asked the same question in my previous message but I got no reply, I did tried to find solution myself but failed, I really need to get the layout fixed for the deadline, please help me if you have any clues for that, Thank you very much.

 

question3.jpg

 

Depends on what you want to do. If it is about changing the way the items are getting listed, then maybe you should try a product listing contribution. If you want to do something else, then can you say what?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×