Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] STS v4


Guest

Recommended Posts

Ive got strange problem i cant figure out

 

for some reason with a STSv4.5.8 install on RC2a only the default sts_template.html is loading and product_info.php.html wont load

 

I have the products_info module in the admin enabled:

 

Product info templates and content templates (v2.1.0)

 

Use template for product info page

true

 

Enable STS3 compatibility mode

false

 

Files for normal template

sts_user_code.php;product_info.php;header_tags.php

 

Files for content template

sts_user_code.php;product_info.php;header_tags.php

 

am i missing something here?

 

i have a products_info.php .html file in the template folder

 

 

on product_info.php/cPath/2_20/products_id/23?sts_debug=debug

 

i have the debug switched on and it reports:

 

STS_VERSION=[4.5.5]

 

OSC_VERSION=[Loaded AU pr4]

STS_TEMPLATE=[includes/sts_templates/full/sts_template.html]

STS_MODULE=[sts_default]

STS_INC_MODULES=[general.php - sts_user_code.php - headertags.php - ]

Edited by alba
Link to comment
Share on other sites

I was looking for a way to hide empty Categories and Sub-Categories in the $catmenu to avoid having the user click on a Category only for it to say "No products found". I ran across this contrib: http://addons.oscommerce.com/info/5475 and just "borrowed" the if-statement and it seems to work just fine. So here it is:

 

In the sts_user_code.php file, in the Category Menu Code:

 

Find:

while ($categories = tep_db_fetch_array($categories_query)) {

...and ADD this below it:

// Begin Hide Empty Categories and Sub Categories
if (tep_count_products_in_category($categories['categories_id']) > 0) {
// End Hide Empty Categories and Sub Categories

Then you need to close out the if-statement so find:

$category_tree_array = tep_get_category_tree($categories['categories_id'], $spacing . '   ', $exclude, $category_tree_array);

And just ADD this below it:

// Begin Hide Empty Categories and Sub Categories
}
// End Hide Empty Categories and Sub Categories

 

Again, I totally snatched the code from the above mentioned, very fine contribution. This is just how you apply it to the sts_user_code.php file.

Link to comment
Share on other sites

I want to add STS in order to get the dynamic headings for my site. Problem is I have already installed many cntributions including meta tags, HTC, easy populate, stock status, etc. I am afraid that one or more of the contributions will prevent me from installing the STS v4 properly. Can anyone give me some idea of what I might be facing if I do this. Any help would be appreciated.

 

Also if anyone wouldn't mind dropping by and giving me an assessment of my site, pro's & con's???

 

Thanks Alot

 

Jada

 

www.ganydirect.com

Jada

 

The codes of the many, outweigh the codes of the few. Live long and Prosper.

Link to comment
Share on other sites

Is there a way to display parts of STS outside of of osC? For instance on my site osC is located at mysite.com/store, I would like to be able to display a feature product as well as the Checkout, My Account and Shopping Cart Items through out my whole site not just in the osC area. I have a section set-up already in my template for this just in case this is possible.

Powered By osC 2.2RC2a STS 4.5.8 - HTC 2.6.3 - FP 1.5.9 - BCH 1.0.0

Link to comment
Share on other sites

I was looking for a way to hide empty Categories and Sub-Categories in the $catmenu to avoid having the user click on a Category only for it to say "No products found". I ran across this contrib: http://addons.oscommerce.com/info/5475 and just "borrowed" the if-statement and it seems to work just fine. So here it is:

 

In the sts_user_code.php file, in the Category Menu Code:

 

Find:

while ($categories = tep_db_fetch_array($categories_query)) {

...and ADD this below it:

// Begin Hide Empty Categories and Sub Categories
if (tep_count_products_in_category($categories['categories_id']) > 0) {
// End Hide Empty Categories and Sub Categories

Then you need to close out the if-statement so find:

$category_tree_array = tep_get_category_tree($categories['categories_id'], $spacing . '   ', $exclude, $category_tree_array);

And just ADD this below it:

// Begin Hide Empty Categories and Sub Categories
}
// End Hide Empty Categories and Sub Categories

 

Again, I totally snatched the code from the above mentioned, very fine contribution. This is just how you apply it to the sts_user_code.php file.

 

Pat,

Don't sell yourself short...this is a great addon for STS. I suggest that you add it to the STSv4 Power Pack site, a sight dedicated to STS addons, tips, etc. (link in my signature below).

 

I'm sure this little gem would get lost in this long thread. :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

Pat,

Don't sell yourself short...this is a great addon for STS. I suggest that you add it to the STSv4 Power Pack site, a sight dedicated to STS addons, tips, etc. (link in my signature below).

 

I'm sure this little gem would get lost in this long thread. :thumbsup:

 

Sure thing, I've added it to the list of goodies. I have a few more that I'll package together and upload as well.

Link to comment
Share on other sites

Hi,

I've just come to install the latest STS and am currently working a 100% CSS based template, the problem is, infobox' it appears that when I use my custom infobox.php.html, whilst it uses it, it seems that elements within STS cause it to not render correctly, more on that in a moment, however here is my infobox.php.html file ...

 

<fieldset>
<legend>$headertext</legend>
$content
</fieldset>

 

As you can see it's fairly trim in content :-)

 

The problem I'm having stems from STS putting it all in a TABLE, which I do NOT want ...

 

<!-- start categorybox //-->

<fieldset>
<legend><table border="0" width="100%" cellspacing="0" cellpadding="0">
 <tr>

<td width="100%" class="infoBoxHeading">Categories</td>
 </tr>
</table>
</legend>
<table border="0" width="100%" cellspacing="0" cellpadding="3" class="infoBoxContents">
 <tr>
<td><img src="includes/sts_templates/TAPFS/images/pixel_trans.gif" border="0" alt="" width="100%" height="1"></td>
 </tr>
 <tr>

<td class="boxText"><a href="XXXXXXXXXXXXXXXXXXXX/index.php?cPath=21">Clothing</a> (14)<br><a href="XXXXXXXXXXXXXXXXXXXX/index.php?cPath=22">DVDs</a> (2)<br><a href="XXXXXXXXXXXXXXXXXXXX/index.php?cPath=23">Music</a> (1)<br></td>
 </tr>
 <tr>
<td><img src="includes/sts_templates/TAPFS/images/pixel_trans.gif" border="0" alt="" width="100%" height="1"></td>
 </tr>
</table>

</fieldset>			
<!-- end categorybox //-->

 

Looking at boxes.php the infobox class, adds the tablebox function, er... how can I get it to NOT use the tablebox?

 

  class infoBox extends tableBox {
function infoBox($contents) {

$info_box_contents = array();
$info_box_contents[] = array('text' => $this->infoBoxContents($contents));
$this->table_cellpadding = '1';
$this->table_parameters = 'class="infoBox"';


  // START  STS
  global $sts;
  if ($sts->infobox_enabled == true) {
	  $this->infoboxtemplate($this->infoBoxContents($contents));
  } else {
	  $this->tableBox($info_box_contents, true);
  }
  // END STS

 }

 

Thanks in advance... BTW this is a HUGE deal to me so if someone can offer any advice I'd appreciate it.

 

Cheers,

 

Stewart

Link to comment
Share on other sites

Can Anyone help please

Hey Guys, I am new to this. I am trying to add loginbox 5.7 to a new install of STSv4.5.8

I have followed instructions but when I try to add file to the column_left of sts_column left.php files, it breaks my table spacing.

This is even before I try to Add this code to sts_user_code.php

I have reverted back to the original STS without loginbox but desperately need it.

I am a novice at this and desperatley need help to install this.

 

Regards

Macca

Link to comment
Share on other sites

Hi Bill,

 

I am still getting the non-secure error. I have trolled through code but found nothing. The error is for places like inlcudes/languages/english/images/buttons/button_continue.gif and images/table_background.gif

 

It is happening on all the cart pages. Are you able to help or do you want code, I could PM you the site if you want to take a look. I know this is not your 'specialty' but you are very knowledgable!

 

Thanks in advance,

Denise

 

I don't think it's a STS issue. The way you can check for certain is to login to your Admin, turn OFF STS in the Modules, reload a SSL encrypted page and see if the problem persists. If it does persist, then you know it's not related to STS.

 

I was having the same issue and here's what I did to fix it (now, this is assuming your configure.php files are all correct):

 

My "production" server is on a shared hosting platform with a shared SSL cert. The domain for the SSL server is different from my domain. This creates some problems when flipping over to SSL mode. In your catalog/includes/application_top.php file, there is a line like so:

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

Try changing it to something like this:

$request_type = (stristr(getenv('HTTP_X_FORWARDED_HOST'), ".nameofyourssldomain.com")) ? 'SSL' : 'NONSSL';

...where nameofyourssldomain.com is the actual name of your SSL domain. It should match the one in your catalog/includes/configure.php file where it says this:

define('HTTPS_SERVER', 'https://yourdomain.nameofyourssldomain.com');

Give it a try and see what happens.

 

PS. I got this from the most excellent (and should be required reading for any OsC developer) "The SSL In OsCommerce Guide For The Innocent" as found here: http://www.oscommerce.com/forums/index.php?showtopic=151162

Link to comment
Share on other sites

I've installed Ultra Pics, I've used the lightbox for STS users to get this too work - http://www.oscommerce.com/community/contri...ch,lightbox+sts

 

the problem I have, is I've managed to get it working for the main image but the extra images no longer pop up. Any suggestions?

 

OK, I got this working - you also have to edit the additional_images.php.

Link to comment
Share on other sites

Like many others I want to thank you for making my job easier by providing such an easy tool for someone like myself to implement.

 

I have been tasked with displaying all of the categories on our store in the left column (there will not be many). In addition, I need to present five sub-categories beneath them in an unordered list.

 

Something like this:

 

Category 1

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

Category 2

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

Category 3

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

 

There are different display requirements for the category and sub-categories but I guess I should just see if something like this is possible first.

 

 

Thank you so much for your help.

Link to comment
Share on other sites

Hi could Bill or someone reply to my post above, this is quite urgent thanks...

 

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

 

Stewart, take a look at this:

http://www.oscommerce.com/community/contributions,3980

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

Like many others I want to thank you for making my job easier by providing such an easy tool for someone like myself to implement.

 

I have been tasked with displaying all of the categories on our store in the left column (there will not be many). In addition, I need to present five sub-categories beneath them in an unordered list.

 

Something like this:

 

Category 1

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

Category 2

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

Category 3

> sub-category 1

> sub-category 2

> sub-category 3

> sub-category 4

> sub-category 5

 

 

There are different display requirements for the category and sub-categories but I guess I should just see if something like this is possible first.

 

 

Thank you so much for your help.

Bruce,

If you are good with CSS, then I would highly recommend the "Nested unordered list" contribution that basically takes the category box and renders it as a nested unorderd list so that you can very easily mod it out using CSS.

 

You can find it here:

http://www.oscommerce.com/community/contributions,4201

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

Is there a way to display parts of STS outside of of osC? For instance on my site osC is located at mysite.com/store, I would like to be able to display a feature product as well as the Checkout, My Account and Shopping Cart Items through out my whole site not just in the osC area. I have a section set-up already in my template for this just in case this is possible.

 

Take a look at this:

http://www.oscommerce.com/community/contributions,4581

 

Also:

http://www.oscommerce.com/community/contributions,294

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

 

That's actually where I've started my base template from, but OSC seems to still add all the table stuff around the infobox calls, and this appears to be done within the actual infobox.php, or am I just getting bogus results?

Link to comment
Share on other sites

I want to add STS in order to get the dynamic headings for my site. Problem is I have already installed many cntributions including meta tags, HTC, easy populate, stock status, etc. I am afraid that one or more of the contributions will prevent me from installing the STS v4 properly. Can anyone give me some idea of what I might be facing if I do this. Any help would be appreciated.

 

Also if anyone wouldn't mind dropping by and giving me an assessment of my site, pro's & con's???

 

Thanks Alot

 

Jada

 

www.ganydirect.com

 

Can anyone help me with this? It is very urgent.

 

Thanks,

 

Jada

 

www.ganydirect.com

Jada

 

The codes of the many, outweigh the codes of the few. Live long and Prosper.

Link to comment
Share on other sites

Am I the only one who's OsCID gets blown away by the $catmenu? I'm trying it on just a stock install and each time I select something from the $catmenu drop down, the OsCID gets lost. The $manufacturerbox dropdown works fine. Just wondering if there's a problem on my side or if it's a universal thing. Thanks in advance...

 

No you're not! I have the same problem with both catmenu and manufacturers. I just wanted to ask if there is a solution? I couldn't find anything ...

 

Datse

Link to comment
Share on other sites

No you're not! I have the same problem with both catmenu and manufacturers. I just wanted to ask if there is a solution? I couldn't find anything ...

 

Datse

This IS NOT a global problem with STS. It is either how you are creating your templates or some bogus code from a separate contribution that you have installed. "Out of the box", STS catmenu and manufacturer drop down keeps the SID.

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

No you're not! I have the same problem with both catmenu and manufacturers. I just wanted to ask if there is a solution? I couldn't find anything ...

 

Datse

 

I'm not sure what the root of the problem is, but I can safely say it's not due to a template malfunction or another contribution. The reason I say this is because I'm having the problem on my localhost, but when I uploaded everything to my production host, the problem went away.

 

So it's more likely due to a server compatibility issue. Since I discovered it worked fine in production, I didn't have the wherewithall to compare every server config option between my local and production to see what might be causing it. Or maybe it's a config setting in the OsC admin - I really don't know. All I can say is, if you're testing on your localhost and haven't tried uploading it to your production server, might be worth a shot.

Link to comment
Share on other sites

I'm not sure what the root of the problem is, but I can safely say it's not due to a template malfunction or another contribution. The reason I say this is because I'm having the problem on my localhost, but when I uploaded everything to my production host, the problem went away.

 

So it's more likely due to a server compatibility issue. Since I discovered it worked fine in production, I didn't have the wherewithall to compare every server config option between my local and production to see what might be causing it. Or maybe it's a config setting in the OsC admin - I really don't know. All I can say is, if you're testing on your localhost and haven't tried uploading it to your production server, might be worth a shot.

Pat may be on to something here since this is the second time I have seen this happen. Server PHP settings are usually more strict on a localhost and more moderate on a host's server.

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

Pat may be on to something here since this is the second time I have seen this happen. Server PHP settings are usually more strict on a localhost and more moderate on a host's server.

 

Hmmm, I was actually hoping it would be a problem with STS, since I couldn't find anything elsewhere in the forums. Loosing the session ID at some point seems to be a common problem though. Unfortunately I do not really know anything about php etc ...

 

I am on a shared server and everything seemed to be fine while installing and setting up the shop. Then I moved the shop from the catalog dir to the root to make it available. Now I have these lost sessions and maybe more I have not discovered yet.

 

Any idea where I should look? Would it maybe help to replace the two menus by another contribution?

 

Thanks for your help!!!

 

Datse

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