Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[contribution] Simple Template System (sts)


DiamondSea

Recommended Posts

I am not quite understanding how the banner is defined. I duplicated the banner module so I could run two seperate sets of banners on the site but I cannot seem to get it defined as $banner2 . It does not seem to follow the same process as the pages and boxes.

 

Any help or ideas would be great.

 

Thanks

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

hi guys!

 

I experienced a problem with the popup image from the product_info.php...

 

...when using the sts-template, the popup doesn't work - i went through a whole bunch of pages with posts from people with similar problems - but none of their solutions would fix my problem...

 

i think it's somewhere over here: (in the sts_display_output.php)

 

// Trying to set the variable for product info pages
$scriptname = $_SERVER['PHP_SELF'];
//$scriptname = getenv('SCRIPT_NAME');
$scriptbasename = substr($scriptname, strrpos($scriptname, '/') + 1);

// Override if we need to show a pop-up window
$scriptname = $_SERVER['PHP_SELF'];
$scriptname = strstr($scriptname, "popup");
$scriptname2 = strstr($scriptname, "info_shopping_cart");
// 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
if ($scriptname != false || $scriptname2 != false) {
$display_normal_output = 1;
$display_template_output = 0;
}

 

 

any suggestions?

 

 

it seems that the $display_normal_output = 1; cannot be set when its on "popup"...

 

...somehow?

Link to comment
Share on other sites

Is it possible to use the Specials box with this contribution?

 

When I put the $specialsbox code in my template it does not work.

you will have to set it in column_left.php

 

  // STS: ADD
 $sts_block_name = 'specialsbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 

and also in your sts_display_output.php (like other boxes)

 

and then place it in your template.html...

 

;)

Link to comment
Share on other sites

After I added the STS contribution, while viewing individual items, my link for "Click to Enlarge" is no longer there. Anyone know how I can display the link and make the link go to a larger picture when viewing a product?

 

When I looked at the product_info.php.html file, I did not see a variable for "Click to Enlarge". Do I need to do something to install the link manually?

Link to comment
Share on other sites

After I added the STS contribution, while viewing individual items, my link for "Click to Enlarge" is no longer there. Anyone know how I can display the link and make the link go to a larger picture when viewing a product?

 

When I looked at the product_info.php.html file, I did not see a variable for "Click to Enlarge". Do I need to do something to install the link manually?

I have a similar Problem - I think the answer is to be found somewhere over here:

 

STS_display_output.php:

// Trying to set the variable for product info pages
$scriptname = $_SERVER['PHP_SELF'];
//$scriptname = getenv('SCRIPT_NAME');
$scriptbasename = substr($scriptname, strrpos($scriptname, '/') + 1);

// Override if we need to show a pop-up window
$scriptname = $_SERVER['PHP_SELF'];
$scriptname = strstr($scriptname, "popup");
$scriptname2 = strstr($scriptname, "info_shopping_cart");
// 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
if ($scriptname != false || $scriptname2 != false) {
$display_normal_output = 1;
$display_template_output = 0;
}

 

 

In my case I got the Code right there - but when I click the picture or the link nothing happens... but it also calls for the popup_image.php

 

for exemple:

 

java script:popupWindow('http://192.168.10.102/osc/popup_image.php?pID=8&osCsid=a7d9ba8596cd87433679edd75a085202')

 

don't know whats wrong there... :blink:

Link to comment
Share on other sites

I just found out that all popup windows don't work anymore since I installed STS...

 

...even the "help" in advanced search cannot pop-up...

 

whats wrong there? please help!

Link to comment
Share on other sites

I just found out that all popup windows don't work anymore since I installed STS...

 

...even the "help" in advanced search cannot pop-up...

 

whats wrong there? please help!

Try uncommenting this line in sts_display_output.php and see if it helps:

 

Change:

 

//$scriptname = getenv('SCRIPT_NAME');

 

to

 

$scriptname = getenv('SCRIPT_NAME');

 

Are you running on a Windows server?

 

- Brian

Edited by DiamondSea

Simple Template System (STS)

Layout your site with 1 (or more) HTML file!

Download STS: http://www.oscommerce.com/community/contributions,1524

Support: http://www.oscommerce.com/forums/index.php?showtopic=58541

Link to comment
Share on other sites

After I added the STS contribution, while viewing individual items, my link for "Click to Enlarge" is no longer there. Anyone know how I can display the link and make the link go to a larger picture when viewing a product?

 

When I looked at the product_info.php.html file, I did not see a variable for "Click to Enlarge". Do I need to do something to install the link manually?

For some reason sts does not always pickup the javascript for the pop ups, on some installs there is no problem. I have tried to figure out what the difference was without much luck. I do however have a fix. Put the javascript code directly between the <head> tags in the sts_template file so it looks like this.

 

<head>

<!--$headcontent-->

<script language="javascript"><!--

function popupWindow(url) {

window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res

izable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,le

ft=150')

}

//--></script>

<link rel="stylesheet" type="text/css" href="stylesheet.css">

</head>

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

Try uncommenting this line in sts_display_output.php and see if it helps:

 

Change:

 

//$scriptname = getenv('SCRIPT_NAME');

 

to

 

$scriptname = getenv('SCRIPT_NAME');

 

Are you running on a Windows server?

 

- Brian

Uncommenting that line doesn't help...

 

I'm running a Windows Apache:

 

Server Information

 

MySQL 4.0.15-max-debug

Apache/2.0.48 (Win32) PHP/4.3.4

PHP 4.3.4 (Zend: 1.3.0)

 

 

 

It's very strange ... I'm mean the pop-up link seems to be right, in IE the JavaScript debugger opens and says that object couldn't be found...

 

 

 

Another thing that I found funny about STS was, that I couldn't link a stylesheet in the template - I had to put the whole one in the header... - but thats no problem - just wanted to mention that...

 

 

... I hope I'll get those popups to work as soon as possible because the deadline for the project is next Monday... so if you have any further Ideas it would be great!

 

 

 

/////////////////////////////////////EDIT

 

strange - when i put the popupscript in the head - same as the stylesheet, then it works...

 

... but thats fine!

 

BIG BIG THX! great contrib! especially for use with the contrib infobox customizer - together with that you can change the whole design of you site! - I'll post the link when it's done, so that everybody can see what can be accomplished with STS and the Infobox Customization!

Edited by iveo
Link to comment
Share on other sites

Is there anyway I could have a front page outside of the catalog with specials or whats new using sts, so the content changes the front page every time content in store changes, or is this not possible.

If it is could someone explain how plz?

 

This is the test site I am working on and I would like a page outside of catalog. This is a splash page with just lizard images and specials or whats new 1 box thats all.

 

http://www.elwyndesignedit.co.uk/testing/cat/

 

This site uses sts1.8, the theme when I have completed it will be release for all to use.

Link to comment
Share on other sites

Forgot the most important, this is a great contribution it make things very easy to play with from a design point of view.

 

Great work...

Link to comment
Share on other sites

Running STS and Ultra Image contributions

 

I run STS which is a great solution for designing the shop

and Ultra Image to have more product-pictures and easily

editing the product descriptions.

 

Now I?d like to edit the product_info.php.html.

 

But how to integrate the Ultra-Image Pictures into the Template Tags?

Can anybody tell me how to do that (if not for Ultra Image, then in general?)

 

 

Unfortunately I didn?t find any answer to my problem in the

previous posts.

 

 

Thanks for any answer and kind regards from sunny Germany!

 

:-)) NewToon

_______________________

 

everyday?s a zididada day

Link to comment
Share on other sites

STS Problem

 

So I have gotten STS installed edited sts_template.html and all that works fine. However if I make the folder /catalog/includes/sts_templates and place anything in it the pages do not render correctly. Close as I can tell is the stylesheet is not being seen. I have changed the path with no luck http://www.domain.com/catalog/stylesheet.css. All the fonts are incorrect, no box outlines or color and no color in breadcrumb. I dought if I'm that speacial so I figure someone has figured this one out already. So what am I not seeing here.

 

Thanks

 

Paul G

Link to comment
Share on other sites

This is all very interesting reading, and I am learning so much, but am having trouble finding the answer I came looking for.

 

I have downloaded the STS file, and would like to test it out... but,

WHERE do I put it exactly?? And do I remove the old index or something???

Link to comment
Share on other sites

This is all very interesting reading, and I am learning so much, but am having trouble finding the answer I came looking for.

 

I have downloaded the STS file, and would like to test it out... but,

WHERE do I put it exactly??  And do I remove the old index or something???

STS Quickie:

 

Get OSC MS2.2 running first, then just copy the STS files into your /catalog/includes directory, copy the STS lines at the bottom of configure-SAMPLE.php into your configure.php. That completes the basic install. No need to modify any other OSC files.

 

Then just modify the /catalog/includes/sts_template.html file just as you would any other HTML file to change the look of the site. Just move or remove the $variable tags to control what appears where.

 

You can't use STS to change what appears in the place of the $content variable. You have to make your changes the old fashioned way for that.

 

- Brian

Simple Template System (STS)

Layout your site with 1 (or more) HTML file!

Download STS: http://www.oscommerce.com/community/contributions,1524

Support: http://www.oscommerce.com/forums/index.php?showtopic=58541

Link to comment
Share on other sites

I will try this again since most igored the question..

 

How do you change the title on the page in STS?

 

I have <TITLE>MY site's name</TITLE> in the main STS HTM file but when luanching it off the server it reverts to "OsCommerce".

 

How do you change this!!??

Link to comment
Share on other sites

I will try this again since most igored the question..

 

How do you change the title on the page in STS?

 

I have <TITLE>MY site's name</TITLE> in the main STS HTM file but when luanching it off the server it reverts to "OsCommerce".

 

How do you change this!!??

Same title across the site: Just change the <title> tag in your sts_template.html file.

 

Different ones by product, use the Header Tag Controller contribution.

 

- Brian

Simple Template System (STS)

Layout your site with 1 (or more) HTML file!

Download STS: http://www.oscommerce.com/community/contributions,1524

Support: http://www.oscommerce.com/forums/index.php?showtopic=58541

Link to comment
Share on other sites

Is there anyway I could have a front page outside of the catalog with specials or whats new using sts, so the content changes the front page every time content in store changes, or is this not possible.

If it is could someone explain how plz?

 

This is the test site I am working on and I would like a page outside of catalog. This is a splash page with just lizard images and specials or whats new 1 box thats all.

 

http://www.elwyndesignedit.co.uk/testing/cat/

 

This site uses sts1.8, the theme when I have completed it will be release for all to use.

I would like to know if it just possible yea or nah, whatever so I dont carry on wasting any more time searching.

 

Thx :D

Link to comment
Share on other sites

Hi people :D

 

My senario is like this: I would like to have the "my account", "check out" and the "cart contents" in graphical buttons instead of text links. Support for multiple languages is a must.

I'm about to insert the buttons into the sts_template file using tables or layers, if that's possible when using diffrent buttons for diffrent languages?!?

Since I'm not a php-programmer I don?t know how to do this <_<

Any ideas anyone? :unsure:

Link to comment
Share on other sites

How to add new Template Tags into product_info ?

 

Does anybody know how to add new Template Tags into

the product_info.php.htm? Where do they have to be defined?

 

For example I?d like to add an addidtional picture in case there?s

one in the database for the product. Let?s call it $addpicture.

Where do I have to define it that I can add it to the product_info.php.htm ?

 

 

Thanks a lot for your answeres !

 

:-) NewToon

Link to comment
Share on other sites

So I have this issue. I find myself with this hosting service that I find poor at best. I have had huge problems with FTP just to start. My client went with them before I got involved. Oh they charge $350 a year with no dedicated IP or even multiple email adrresses. So I built a beta version on my host while the whole FTP thing got cleared up. I used STS to build pages. So I have been moving pages and a new issue. On the beta site click to enlarge image works on this other host it does not. Host is claiming it needs java support and wants to charge me to fix it. Yet the same page works on my site with my host. Is this a line of crap from a loser? Should I dump them? I would love to actually. So please answer.

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...