Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] STS v4


Guest

Recommended Posts

I have the same issue with a blank dynamic_site page (right and left column, header and footer ok). Running STS Plus 4. i, however, do not have my right_column commented out on dynamic_sitemap.php. i uploaded an untouched version. anyone have a fix for this? i also tried including it in admin/modules/sts with no success.

 

Worked it out!

 

I'm a muppet and the copy of dynamic_sitemap.php had the right column commented out - doh!!

Put that back in and it works fine!

What would you do if you knew you could not fail?

Link to comment
Share on other sites

i'm curious, when you log into the affiliate as a member and go to the summary page, there are tiny ? marks to click that supposed to pop up in a new window with information. Right now, when I click on those ? marks, the pop up window displays my STS template and not the information.

 

That goes for all of my pop ups under catalog and header EXCEPT for the pop up images which work fine.

 

I remember having this issue with previous versions of STS and there are even posts that gave me a fix that worked. BUT with version 4.2 the files for STS are located in different places than before and contain different info. Basically I don't know how to fix it under 4.2. Any suggestions?

 

@itnchans

you can start in /catalog/includes/sts_templates/ folder. There you have two templates, Test and Full, but first you have to enable the shop to use templates, from the Administration side, by going to Modules -> STS -> Default -> Install. You can set it up to use the Test template for starters, and then start modifying the way sts_template.html looks (found in the includes/sts_templates/test/ folder). And also read the documentation, because there are lots of usefull informations there too... (STS4.doc, found in the sts4.1 archive)

 

@contrib developers

I thought of a feature that is not present in the contribution and some people might find usefull...

For example, I had to modify the templates so they wouldn't show some boxes and informations when an affiliate is loged in, so I had to design a template for each page (and for the affiliate there are about 20 or so files) that can show up when an affiliate is logged in. It's basically the same html, but with different names... affiliate_banners.php.html, affiliate_clicks.php.html, etc...

Wouldn't it be a nice ideea to have a feature somewhere in the administration panel where you could say something like "I want to use <this> template for the following pages: <script1>,<script2>..." ? Or is there another way in the present to do this ? Because in this case, the different affiliate files are not like cathegories or products where you could just pass an ID or smth... it would be very good to have something like that, cause in that way you could design a single html and modify it easily so it would show in all cases, instead of copying the file for each script, each time you modify it :)

 

Best of luck for everybody...

 

PS: I have STS 4.1 and HTC 2.5.9 and they work great together. Before, I had STS 3 and HTC 2.5.5, but the HTC didn't work ok. I didn't update to get to the new versions, instead I removed the old versions completelly and then reinstalled the new ones. Maybe some of you would say that it's too difficult to remove them, but I had installed other contributions in the meanwhile, so I know how it is, but still it's the best way to make sure the instalation works fine... (when you install HTC, don't modify the files from the catalog, just copy the new ones, and in the admin side remember to specify at the STS module that "Files for normal template" would have to use sts_user_code.php;headertags.php)

What would you do if you knew you could not fail?

Link to comment
Share on other sites

i'm curious, when you log into the affiliate as a member and go to the summary page, there are tiny ? marks to click that supposed to pop up in a new window with information. Right now, when I click on those ? marks, the pop up window displays my STS template and not the information.

 

That goes for all of my pop ups under catalog and header EXCEPT for the pop up images which work fine.

 

I remember having this issue with previous versions of STS and there are even posts that gave me a fix that worked. BUT with version 4.2 the files for STS are located in different places than before and contain different info. Basically I don't know how to fix it under 4.2. Any suggestions?

When the pop-up image in your cart is coming up as a template page instead of the larger image ... Check to see if you have Use Search-Engine Safe URLs (still in development) turned on in the MY STORE page of Configuring Your Catalog. THIS SHOULD BE TURNED OFF.

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

Hi Guys,

 

Complete newb to OS Commerce, but not to CMS or HTML and that. Here is a plain HTML type start on a site I am doing:

 

http://www.gorgeousthings.ie/test/

 

Just a few questions - As you can see their are some graphics here, the first one contains the logo, the second an empty rectangle type thing under each other. If I want to build a site with these graphics on all pages and say the $catmenu ,$categorybox, $manufacturerbox etc down the left under the graphics - What file / files need I edit? Is it the /sts_template.html in the test folder only? Do I physically adjust the table structure of this file to accomodate these graphics? Do I place the actual HTML pointing at the location of these two graphics into this file also OR somewhere else? I suppose I might ask is the sts_template.html file just for place holders OR can it also contain all the HTML one needs also like code used to insert an image etc?

 

Cheers

aidan

Link to comment
Share on other sites

Hi Guys,

 

Complete newb to OS Commerce, but not to CMS or HTML and that. Here is a plain HTML type start on a site I am doing:

 

http://www.gorgeousthings.ie/test/

 

Just a few questions - As you can see their are some graphics here, the first one contains the logo, the second an empty rectangle type thing under each other. If I want to build a site with these graphics on all pages and say the $catmenu ,$categorybox, $manufacturerbox etc down the left under the graphics - What file / files need I edit? Is it the /sts_template.html in the test folder only? Do I physically adjust the table structure of this file to accomodate these graphics? Do I place the actual HTML pointing at the location of these two graphics into this file also OR somewhere else? I suppose I might ask is the sts_template.html file just for place holders OR can it also contain all the HTML one needs also like code used to insert an image etc?

 

Cheers

aidan

 

If you alter the tables in sts_template.html to include the images your reference, then they will show up on all pages. I would suggest making minor alterations to the tables in sts_template.html and then seeing what impact they have on your site and all the various pages. You can hard-code any images in the template file. You only need one template file for your whole site, unless you want different layouts on specific pages, in which case you make a specific template page for each page your want to be different as discussed in the user manual for STS.

----------------------------------------------------

Link to comment
Share on other sites

If you alter the tables in sts_template.html to include the images your reference, then they will show up on all pages. I would suggest making minor alterations to the tables in sts_template.html and then seeing what impact they have on your site and all the various pages. You can hard-code any images in the template file. You only need one template file for your whole site, unless you want different layouts on specific pages, in which case you make a specific template page for each page your want to be different as discussed in the user manual for STS.

 

Thank you Vines,

 

One other question I forgot to ask - does it matter where you put the images OR is it best to keep them in the sts_templates/test folder with the html file?

Link to comment
Share on other sites

Yeah, I checked that but it's set to false. I remember having to do more than that though. But as I said the last time I had to do that it was on a previous version of STS.

 

Thanks

 

When the pop-up image in your cart is coming up as a template page instead of the larger image ... Check to see if you have Use Search-Engine Safe URLs (still in development) turned on in the MY STORE page of Configuring Your Catalog. THIS SHOULD BE TURNED OFF.

What would you do if you knew you could not fail?

Link to comment
Share on other sites

I am sooo confused. I installed the STS v4 with Header Tags and Infoboxes for STS v4. I have tried using the sts_template that came with STS v4, the one that another member contributed for cleaner code, and the one that came with the Infoboxes for STS v4. All three give me the same error when I try to view my store:

 

(empty image here)Languages

 

Error!

 

Unable to Determine the Page Link!

 

Now- if I go back into my Admin and turn OFF the STS Templates (under Default), then the page shows up, at least the center content area does, but the left and right side columns all have errors like this:

 

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

 

 

I am at a complete loss here. If I go to the server (via FTP) all of the files referenced above do exist. Is this possibly a problem being caused by the fact that I am not using a "catalog" folder, I just have osCommerce installed on the root?

 

Thanks for any help you can offer - I'm getting tired of completely removing osCommerce off the server and then re-installing it and the contributions I'd like to use in an attempt to get it working :(

 

Tracy

~Tracy
 

Link to comment
Share on other sites

I must be going crazy. I looked through the forum some more and found my own post from Jan 06.:

 

STS Affiliate Pop-Up issue

 

I had the same problem and have a solution. (That works for me, hope it will work for you as well)

 

In the file named sts_display_output.php it states that:

// If script name contains "popup" then turn off templates and display the normal output

 

So, looking at the two files that need to pop up for the affiliate 'create a link' pages (category and products)

 

affiliate_validcats.php & affiliate_validproducts.php

 

They do not have the word 'popup' in their names.

 

So I renamed them:

 

popup_affiliate_validcats.php & popup_affiliate_validproducts.php

 

Then i opened the file - includes/affiliate_application_top.php

 

i changed the file names to match the new ones.

 

Hope this helps.

 

http://www.oscommerce.com/forums/index.php?sho...;p=775921

 

Yeah, I checked that but it's set to false. I remember having to do more than that though. But as I said the last time I had to do that it was on a previous version of STS.

 

Thanks

What would you do if you knew you could not fail?

Link to comment
Share on other sites

I am sooo confused. I installed the STS v4 with Header Tags and Infoboxes for STS v4. I have tried using the sts_template that came with STS v4, the one that another member contributed for cleaner code, and the one that came with the Infoboxes for STS v4. All three give me the same error when I try to view my store:

 

(empty image here)Languages

 

Error!

 

Unable to Determine the Page Link!

 

Now- if I go back into my Admin and turn OFF the STS Templates (under Default), then the page shows up, at least the center content area does, but the left and right side columns all have errors like this:

 

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox_header.php.html]Template file does not exist: [sTS_TEMPLATE_DIRboxes/infobox.php.html]

I am at a complete loss here. If I go to the server (via FTP) all of the files referenced above do exist. Is this possibly a problem being caused by the fact that I am not using a "catalog" folder, I just have osCommerce installed on the root?

 

Thanks for any help you can offer - I'm getting tired of completely removing osCommerce off the server and then re-installing it and the contributions I'd like to use in an attempt to get it working :(

 

Tracy

 

PS - If I disable both the STS and the Infobox contributions I do get the generic osCommerce page for the homepage - but at the bottom it does still say:

 

Error!

 

Unable to Determine the Page Links!

 

If I click on one of the categories on the left I get a blank page with this error:

 

No Input File Specified

 

 

I really hope somebody has some idea as to what is happening here. This is my first time ever utilizing osCommerce and I am at a complete loss :(

 

Back to reading through installation manuals and the knowledge base again :(

 

Tracy

~Tracy
 

Link to comment
Share on other sites

I must be going crazy. I looked through the forum some more and found my own post from Jan 06.:

 

STS Affiliate Pop-Up issue

 

I had the same problem and have a solution. (That works for me, hope it will work for you as well)

 

In the file named sts_display_output.php it states that:

// If script name contains "popup" then turn off templates and display the normal output

 

So, looking at the two files that need to pop up for the affiliate 'create a link' pages (category and products)

 

affiliate_validcats.php & affiliate_validproducts.php

 

They do not have the word 'popup' in their names.

 

So I renamed them:

 

popup_affiliate_validcats.php & popup_affiliate_validproducts.php

 

Then i opened the file - includes/affiliate_application_top.php

 

i changed the file names to match the new ones.

 

Hope this helps.

 

http://www.oscommerce.com/forums/index.php?sho...;p=775921

Yes, this would be the correct thing to do. Keep in mind, STS works sort of like how "includes" work in HTML pages. Instead of "includes", you use placeholders such as "$content$" and "$catlogo$". With an HTML includes file, you have a link to the file or page that you want to "include" in the page. In STS, the placeholder is the "include" link that goes out and brings in the PHP file or content that needs to be in your page.

 

So...yes, it would cause some problems having files that are named the same as any of the placeholders because STS would naturally "include" those files when the placeholder is called upon.

 

Well, the good news is that you figured it out rather quickly. :thumbsup:

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

I really hope somebody has some idea as to what is happening here. This is my first time ever utilizing osCommerce and I am at a complete loss :(

 

Back to reading through installation manuals and the knowledge base again :(

 

Tracy

Tracy, I have responded to both of your emails. I hope what I have sent you has helped you through your problems.

 

By the way, do you have the option to install two copies of osCommerce on your server? This would allow you to use one for your live shop and the other for your "test" enviroment. This method should help you from going through the re-installation of osCommerce when a contribution installation or edit goes bad. :thumbsup:

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

Could anyone tell me how difficult it would be to create a placeholder for a contrib? I would like to use FAQDesk on a site with STS. FAQDesk creates it's own infobox.

 

Any help would be appreciated!

How to create a STS tag to link to a php file:

 

Look for the PHP code that links to the PHP file that you want to make a tag for.

 

For example, let's make a STS tag the PHP file "account.php".

In this case, we want to make a tag for account.php. This link is defined in the includes/header.php file:

 

<?php echo '<a href="' . tep_href_link(FILENAME_ACCOUNT, '', 'SSL') . '">' . tep_image(DIR_WS_IMAGES . 'header_account.gif', HEADER_TITLE_MY_ACCOUNT) .

 

 

In the above, a graphic file "header_account.gif" is used for the link. The actual url link to account.php would be:

 

tep_href_link(FILENAME_ACCOUNT, '', 'SSL')

 

So, you create the tag for the url link to account.php as so:

 

 

$sts->template['urlmyaccountlogo'] = tep_href_link(FILENAME_ACCOUNT, '', 'SSL');

 

The tag is defined as: $urlmyaccountlogo

 

 

You now need to save the code that you have created in the includes/modules/sts_inc/sts_user_code.php file. Once you have done this, the tag is now ready for use in your template. :thumbsup:

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

I have installed this mod on my site ( it is in demo mode ) and I am activated the template system using the standard full template that is included. I can see the site with the template from the computer at my day job, but not from my computer at home.

 

any ideas?

 

If deactivate sts, I can see the site at my house.

Link to comment
Share on other sites

I must be going crazy. I looked through the forum some more and found my own post from Jan 06.:

 

STS Affiliate Pop-Up issue

 

I had the same problem and have a solution. (That works for me, hope it will work for you as well)

 

In the file named sts_display_output.php it states that:

// If script name contains "popup" then turn off templates and display the normal output

 

So, looking at the two files that need to pop up for the affiliate 'create a link' pages (category and products)

 

affiliate_validcats.php & affiliate_validproducts.php

 

They do not have the word 'popup' in their names.

 

So I renamed them:

 

popup_affiliate_validcats.php & popup_affiliate_validproducts.php

 

Then i opened the file - includes/affiliate_application_top.php

 

i changed the file names to match the new ones.

 

Hope this helps.

 

http://www.oscommerce.com/forums/index.php?sho...;p=775921

Actually, the file is located at catalog/includes/classes/sts.php.

 

There is a better way of doing the above. If you have a popup file that you need STS to ignore, create a module called sts_mypagename.php that returns an empty string as template filename, it will automatically switch off STS for this page. Your popups should work then.

 

Otherwise, you could try this method:

 

In catalog/includes/classes/sts.php, find the following code:

 

 

  // If script name contains "popup" then turn off templates and display the normal output
 // This is required to prevent display of standard page elements (header, footer, etc) from the template and allow javascript code to run properly
 // Do not add pages here unless it is from the standard osC and really should be there. If you have a special page that you don't want with template,
 // Create a module sts_mypagename.php that returns an empty string as template filename, it will automatically switch off STS for this page.
if (strstr($scriptbasename, "popup")|| strstr($scriptbasename, "info_shopping_cart")) {
  $this->display_template_output = false;
  return;
}

 

Add the additional scriptname that you need STS to ingore so it will not add the header, footer, etc. For example: Your code would end up looking like this if you had the Affiliate contribution installed:

 

 

if (strstr($scriptbasename, "popup")|| strstr($scriptbasename, "affiliate_help")|| strstr($scriptbasename, "info_shopping_cart")) {
  $this->display_template_output = false;
  return;
}

You can also add any other filenames if needed. The first method is the preferred method.

Hope this has helped,

Bill Kellum

Edited by bkellum

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

Hi all,

 

I'm not new to OSC, but am to STS. It's already proven to be a FABULOUS help to me! :D

 

According to the STS User Manual, the $content tag is created in the file:

catalog/includes/modules/sts_inc/column_right.php

 

I think I'm losing it, because that file is not there! HELP ME! :blink:

 

Heather

Link to comment
Share on other sites

Hi all,

 

I'm not new to OSC, but am to STS. It's already proven to be a FABULOUS help to me! :D

 

According to the STS User Manual, the $content tag is created in the file:

catalog/includes/modules/sts_inc/column_right.php

 

I think I'm losing it, because that file is not there! HELP ME! :blink:

 

Heather

That is a typo in the manual

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

Nevermind. It should say index.php, right? LOL! Can you tell I've been looking at this too long today? :wacko:
Actually, it is broken down like so:

 

In STS, the idea is to send the html code to a buffer instead of to the browser. This buffer is an array with many elements, each representing a part of the page. At the end, a piece of code replaces the placeholders of your template by the corresponding elements of the buffer.

 

The $content tag is the piece of html generated between the end of column_left.php and the beginning of column.right.php. Take a look at these two files to get a better idea on how this works. In STS, the output you see in your browser is generated by a file named sts_display_output.php.

Edited by bkellum

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

STS is now the ranked 4th in total osCommerce contribution downloads, moving ahead of the Header Tags Controller contribution and up two spots on BTS. :D

 

Thanks to all who have helped develop and support this great contribution. :thumbsup:

 

The Simple Template System should be included in the stock release of osCommerce. :-

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

I have a problem with tabs though.

 

I tried to include the Nav Bar with On/Off tabs contrib but couldn't figure out how to get it to display using STS. . . So, then I tried to incorporate similar code from my Wordpress Blog so that the header would be the same across osC and Wordpress.

 

For the heck of it, I just copy/pasted the corresponding code from wordpress to my STS template file and osC stylesheet.

 

To my surprise, it actually works in Internet Explorer but does not work in Firefox. Obviously, IE can interpret my poor code, but it's not quite "right" because Firefox doesn't show it.

 

I solved my own problem here, and of course it was something simple. Turns out my <div> code and CSS code were fine. The problem with Firefox not interpreting <div> and CSS properly with STS is related to the included STS_template.html file. The first line in this file is:

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

 

For whatever reason I didn't care to research too deeply, this line should specify a version and should in fact read this way:

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

 

Making this very minor change did the trick. Unfortunately, only after several hours of failed attempts to get Firefox to display <div> properly.

----------------------------------------------------

Link to comment
Share on other sites

I solved my own problem here, and of course it was something simple. Turns out my <div> code and CSS code were fine. The problem with Firefox not interpreting <div> and CSS properly with STS is related to the included STS_template.html file. The first line in this file is:

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

 

For whatever reason I didn't care to research too deeply, this line should specify a version and should in fact read this way:

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

 

Making this very minor change did the trick. Unfortunately, only after several hours of failed attempts to get Firefox to display <div> properly.

This is a web standard issue. The doctype specified in the template is for standard HTML. You will need to specify your own doctype according the the web standards. You can learn more about doctypes and why they are important at the following web site:

 

http://alistapart.com/stories/doctype/

 

http://www.htmlhelp.com/tools/validator/doctype.html

 

http://www.w3.org/QA/Tips/Doctype

 

Hope this helps,

 

Bill Kellum

Bill Kellum

 

Sounds Good Productions

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

Link to comment
Share on other sites

Hi, I have 2 questions

 

1. I am having trouble with the imagelarge tag - it is just showing the thumbnail size. Has anyone else had this problem?

 

2. Is there any way I can create a product content template for a particular category?

 

Any help greatly appreciated. Thanks

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...