Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] STS v4


Guest

Recommended Posts

I think I have encounterd a serious problem.

 

When I have STS active I can't add products to my shopping cart. When I disable STS I can add them easily and don't have problems at all.

 

I am using STS4.5.8 on MS2.2 also using 'Featured Products 161 with STS 453 instructions'

 

Sorry for double posting... I wanted to edit the post above to add the following:

 

I want to edit the category overview. But in the list posted by bkellum I can't find the proper filename. Is this doable and if-so which file I need to create and edit? To don't confuse anybody, I want to make a same template for all categories so products aren't listed under each other.

Edited by Toyz
Link to comment
Share on other sites

I think I have encounterd a serious problem.

 

When I have STS active I can't add products to my shopping cart. When I disable STS I can add them easily and don't have problems at all.

 

I am using STS4.5.8 on MS2.2 also using 'Featured Products 161 with STS 453 instructions'

 

The only way this could be related to STS is if you did not install STS correctly. Check your sites files and folders against the files from the contribution using a good file comparison utility such as Beyond Compare or WinMerge.

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

The only way this could be related to STS is if you did not install STS correctly. Check your sites files and folders against the files from the contribution using a good file comparison utility such as Beyond Compare or WinMerge.

 

Thank you. I gonna try this. It would be strange if this is the reason why I have this problem, because I installed STS onto my clean osC before adding other contribs.

Link to comment
Share on other sites

// Edit ... again doublepost sorry

I used Beyond Compare to noticed that I got some missing code thanks to adding a component named Graphical Borders. I gonna check if I can fix it otherwise compare the conponent I have installed are included in some powerpack. STS is working more then just fine. Don't wanna turn it down.

Link to comment
Share on other sites

Hello,

I have ask the same question in the coolmenu post, but nobody reply...

Does anyone successfully install coolmenu in STS?

I follow the install manual and add some more codes for my OSC2rc2 with STS

But It shows nothing. (The coolmenu works when I disable the STS.)

Here is what I did:

 

in \includes\sts_templates\myoriginal\sts_template.html

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

<head>

SCRIPT LANGUAGE="JavaScript1.2" SRC="includes/menu_animation.js"></SCRIPT>

<!--$headcontent-->

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

</head>

 

 

in includes\modules\sts_inc\sts_column_left.php

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

if ((USE_CACHE == 'true') && empty($SID)) {

echo tep_cache_categories_box();

} else {

include(DIR_WS_BOXES . 'coolmenu.php');

}

$sts->restart_capture ('categorybox', 'box');

 

Is there anything wrong or missing?

Thank you!

Link to comment
Share on other sites

hi, Rigadin

 

I m using oscommerce 2.2, while installing sts v4.5.8 i m gettin following error & not able to install sts

 

 

Fatal error: Call to undefined function osc_draw_input_field() in C:\wamp\www\oscommerce-2.2rc2a\catalog\install\templates\pages\install.php on line 123

 

please help

 

Thanx

Edited by rashmisharmamca
Link to comment
Share on other sites

// Edit ... again doublepost sorry

I used Beyond Compare to noticed that I got some missing code thanks to adding a component named Graphical Borders. I gonna check if I can fix it otherwise compare the conponent I have installed are included in some powerpack. STS is working more then just fine. Don't wanna turn it down.

 

I just started a clean osC MS2.2 install and installed STS (4.5.8) on the clean install. I tested my template which I made earlier and again I can't add products to my shopping cart. When I switch it to the included 'full' folder the button works. The strange thing is, I edited the included product_info_26 file from the 'full' folder to my own folder, so it should work I recon.

 

I am confused now what to do...

 

//EDIT

Again I compared my product_info.php with the included product_info.php_26 from the full folder and the only things different are the div tags I included to make up my layout.

Edited by Toyz
Link to comment
Share on other sites

Check the following tutorial just to be sure your cart is configured correctly for the extra languages:

http://www.oscommerce.info/kb/osCommerce/A...ocalization/163

 

 

Finally, I've found the solution, the problem was that in functions/general.php is declared the function function tep_get_category_name. In that function is declared global $languages_id;, if you eliminate that part of code, multilanguage functionality works properly.

 

 

function tep_get_category_name($cat_o_subcat, $language = ''){
global $languages_id;
 if (empty($language)) $language = $languages_id;
 $category_name_query = tep_db_query("select categories_name from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . $cat_o_subcat . "' and language_id = '" . (int)$language . "'");
 $category_name = tep_db_fetch_array($category_name_query);
 return $category_name['categories_name'];
}

$cat_y_subcat=tep_get_product_path($HTTP_GET_VARS['products_id']);

$id_subcategoria=substr (strchr($cat_y_subcat,"_"),1);

$id_categoria=substr($cat_y_subcat,0,-(strlen($id_subcategoria))-1);


$nombre_categoria=tep_get_category_name($id_categoria);
$nombre_subcategoria=tep_get_category_name($id_subcategoria);

 

 

 

Hope that this it'll be useful for someone.

Best Regards

Link to comment
Share on other sites

see the demo at: www.bluegreenenterprises.com

 

New OSC Bundle package comming soon:

 

give it a try and let me know what you think...

 

Google Checkout (v1.4.5a).

STS v4.5.8.

Web Mobile Thumbnails - in POPUP IMAGE.

Dynamenu (Gone Nuts Bonkers) - Multiple Flyout Menu System.

Extra Admin links to New Add-Ons.

Admin - Multi Product Update - Weight, Prices and QTY.

Hide Empty Categories (Dynamenu also hides empty Categories).

Admin->modules->shipping - Individual Product Shipping Prices.

STS Articles

Link to comment
Share on other sites

Finally, I've found the solution, the problem was that in functions/general.php is declared the function function tep_get_category_name. In that function is declared global $languages_id;, if you eliminate that part of code, multilanguage functionality works properly.

 

 

function tep_get_category_name($cat_o_subcat, $language = ''){
global $languages_id;
 if (empty($language)) $language = $languages_id;
 $category_name_query = tep_db_query("select categories_name from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . $cat_o_subcat . "' and language_id = '" . (int)$language . "'");
 $category_name = tep_db_fetch_array($category_name_query);
 return $category_name['categories_name'];
}

$cat_y_subcat=tep_get_product_path($HTTP_GET_VARS['products_id']);

$id_subcategoria=substr (strchr($cat_y_subcat,"_"),1);

$id_categoria=substr($cat_y_subcat,0,-(strlen($id_subcategoria))-1);


$nombre_categoria=tep_get_category_name($id_categoria);
$nombre_subcategoria=tep_get_category_name($id_subcategoria);

 

 

 

Hope that this it'll be useful for someone.

Best Regards

 

I have to admit that I have not had the time to follow your posts in detail but I have to make this simple comment:

The multi-language function works perfectly in a stock osC shop with only STS added to it. No code changes are required.

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 just started a clean osC MS2.2 install and installed STS (4.5.8) on the clean install. I tested my template which I made earlier and again I can't add products to my shopping cart. When I switch it to the included 'full' folder the button works. The strange thing is, I edited the included product_info_26 file from the 'full' folder to my own folder, so it should work I recon.

 

I am confused now what to do...

 

//EDIT

Again I compared my product_info.php with the included product_info.php_26 from the full folder and the only things different are the div tags I included to make up my layout.

 

You make it difficult to help you when you assume we all know what you are talking about. I will try though.

After reading your posts, it appears shoppers can not add products to their shopping cart if STS is activated. However, upon a clean install of osCommerce and STSv4.5.8, you found that everything works fine. Then, you decided to add your customized template and that is when the problem showed up again. Am I understanding you correctly?

 

If so, then it is obvious where the problem lies. It has to do with your custom template. You said you compared your custom template with product_info.php. Why would you do that? That is not going to tell us anything regarding your issue.

 

Here is what I think is going on...

 

I think you are trying to create a product_info "content" template, "content" being the key word here.

 

  1. You may not have turned on the Product Info Module in the admin and that is causing the problem, or...
  2. You may not have placed your custom product_info.php.html file in the correct folder. It should be located in includes/sts_templates/*your template folder*/content/product_info.php.html.
  3. You may not have included the start form and end form tags in your content template.

Take a look at the above and see if that helps you work out your issue.

 

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

Link to comment
Share on other sites

hi, Rigadin

 

I m using oscommerce 2.2, while installing sts v4.5.8 i m gettin following error & not able to install sts

 

 

Fatal error: Call to undefined function osc_draw_input_field() in C:\wamp\www\oscommerce-2.2rc2a\catalog\install\templates\pages\install.php on line 123

 

please help

 

Thanx

Rigadin has not been around here for quite some time.

 

Your issue does not have anything to do with STS but rather how you have your server configured or how you uploaded osCommerce.

 

The error is pointing to the osCommerce installation folder so you may have your "catalog" path set incorrectly in your configure.php files. Could also be related to a badly coded .htaccess file as well.

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

You make it difficult to help you when you assume we all know what you are talking about. I will try though.

After reading your posts, it appears shoppers can not add products to their shopping cart if STS is activated. However, upon a clean install of osCommerce and STSv4.5.8, you found that everything works fine. Then, you decided to add your customized template and that is when the problem showed up again. Am I understanding you correctly?

 

If so, then it is obvious where the problem lies. It has to do with your custom template. You said you compared your custom template with product_info.php. Why would you do that? That is not going to tell us anything regarding your issue.

 

Here is what I think is going on...

 

I think you are trying to create a product_info "content" template, "content" being the key word here.

 

  1. You may not have turned on the Product Info Module in the admin and that is causing the problem, or...
  2. You may not have placed your custom product_info.php.html file in the correct folder. It should be located in includes/sts_templates/*your template folder*/content/product_info.php.html.
  3. You may not have included the start form and end form tags in your content template.

Take a look at the above and see if that helps you work out your issue.

 

Hope this helped,

 

Hello,

I have copied the product_info template from the full folder which is included in a clean install of STS4.5.8. When I got STS active and instead of my own template I put the full folder active the product_info template is able to add items to the shopping cart. With my own product_info template which is a modified version of the included product_info from the full folder I can't add products to my shopping cart.

 

I have checked my settings and they work fine with the included product_info template.

Link to comment
Share on other sites

Hello,

I have copied the product_info template from the full folder which is included in a clean install of STS4.5.8. When I got STS active and instead of my own template I put the full folder active the product_info template is able to add items to the shopping cart. With my own product_info template which is a modified version of the included product_info from the full folder I can't add products to my shopping cart.

 

I have checked my settings and they work fine with the included product_info template.

 

OK. Then this has to be isolated to your custom template then.

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

Rigadin has not been around here for quite some time.

 

Your issue does not have anything to do with STS but rather how you have your server configured or how you uploaded osCommerce.

 

The error is pointing to the osCommerce installation folder so you may have your "catalog" path set incorrectly in your configure.php files. Could also be related to a badly coded .htaccess file as well.

 

Hey Bill...I am replying through someone else's thread because I'm wondering if the problems I'm encountering (which started ever since I transferred my site over) is related to this other guy's problem (above). By the way, I recognize my last post was loaded with questions and your probably very busy, so no rush if you can't get around to it any time soon. Besides, I have a feeling alot of these issues will be resolved if I figure this one thing out.

 

Anyway, you told me to check out my configurations in the 2 configure.php files. I thought it was pointed correctly, but perhaps there is something wrong. I did notice that on my old site, it would go as follows: www.mysitename/catalog/whatever_file _'m looking_at. Is it supposed to be in that order? Because this time around, it goes: www.foxysally.com//whatever_file_I'm looking_at...and for some reason, it does have 2 slashes after foxysally.com. Could this have something to do with the fact that my buttons aren't showing up and why some of my images are broken as well? Perhaps I installed the site wrong?

 

-Leah

Link to comment
Share on other sites

Hey Bill...I am replying through someone else's thread because I'm wondering if the problems I'm encountering (which started ever since I transferred my site over) is related to this other guy's problem (above). By the way, I recognize my last post was loaded with questions and your probably very busy, so no rush if you can't get around to it any time soon. Besides, I have a feeling alot of these issues will be resolved if I figure this one thing out.

 

Anyway, you told me to check out my configurations in the 2 configure.php files. I thought it was pointed correctly, but perhaps there is something wrong. I did notice that on my old site, it would go as follows: www.mysitename/catalog/whatever_file _'m looking_at. Is it supposed to be in that order? Because this time around, it goes: www.foxysally.com//whatever_file_I'm looking_at...and for some reason, it does have 2 slashes after foxysally.com. Could this have something to do with the fact that my buttons aren't showing up and why some of my images are broken as well? Perhaps I installed the site wrong?

 

-Leah

 

Leah,

Yes, that does have something to do with your issue. You need to correct the catalog path in your configure.php files.

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

Hello guys,

 

I have a question about product_info.php

 

I'm using osCommerce newest package, modernrc2a template with STS v4.5.8..

 

I dont think (remember) that I ever had a product info template working..

My goal is simply to show same graphics as the infoboxes for starters, but I would like to style it individually, most preferrably through a .css

 

Have I overwritten some data since its not showing?

Can you help me in making these changes?

 

Please refer to www.markstrange.dk/shop - any product shown will do..

 

Thanks!

Link to comment
Share on other sites

I am using STS with a custom, no frills template I designed but when the customer visits the site and a session id is generated and they add an item to cart. Next, they click a category name on the left (hard coded into template with URL - not generated from osc), the code is the url of the parent category so if a customer clicks that, they lose the session and it empties the cart. Any suggestions?

 

I tried adding ?$sid after the url and it seems to keep item into cart until I click button I created that is calling $cartcontents, then the cart is empty again and a new sid is created.

 

Thanks!

Link to comment
Share on other sites

I am using STS with a custom, no frills template I designed but when the customer visits the site and a session id is generated and they add an item to cart. Next, they click a category name on the left (hard coded into template with URL - not generated from osc), the code is the url of the parent category so if a customer clicks that, they lose the session and it empties the cart. Any suggestions?

 

I tried adding ?$sid after the url and it seems to keep item into cart until I click button I created that is calling $cartcontents, then the cart is empty again and a new sid is created.

 

Thanks!

Make your "hard coded" links as so in order to keep the session ID:

 

STS Link to a category:

 

<a href="<?php echo tep_href_link('index.php', 'cPath=21&', 'NONSSL'); ?>">Category Name Here</a>

STS Link to a product:

<a href="<?php echo tep_href_link('product_info.php', 'products_id=53&', 'NONSSL'); ?>">Product Name Here</a>

You can use the links above to create your menus.

Hope this helped,

 

 

Take a look at what the code is saying (or doing for that matter).

 

<a href="<?php echo tep_href_link('index.php', 'cPath=21&', 'NONSSL'); ?>">Category Name Here</a>

 

This code snippit is linking to category ID 21 which is named "Category Name Here". This should be modified to the ID of the category that you are linking to and the name can be whatever you want to name that particular category.

 

Regarding how to find the category ID numbers is very simple. View your store in your browser and either place your curser over a category or click on it. If you click on it you will see something like this in the address bar:

[url="http://soundsgoodpro.com/eshop/index.php?cPath=26"]http://soundsgoodpro.com/eshop/index.php?cPath=26[/url]

The cPath=26 is the category ID.

 

The product ID is the same way. If you click on a product in that category you will see something like this in the address bar:

[url="http://soundsgoodpro.com/eshop/product_inf...;products_id=58"]http://soundsgoodpro.com/eshop/product_inf...;products_id=58[/url]

The products id=58 is the Product ID.

 

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

Link to comment
Share on other sites

I am using STS with a custom, no frills template I designed but when the customer visits the site and a session id is generated and they add an item to cart. Next, they click a category name on the left (hard coded into template with URL - not generated from osc), the code is the url of the parent category so if a customer clicks that, they lose the session and it empties the cart. Any suggestions?

 

I tried adding ?$sid after the url and it seems to keep item into cart until I click button I created that is calling $cartcontents, then the cart is empty again and a new sid is created.

 

Thanks!

 

One other tip...Be sure to setup your shop to save the session in MySQL (database). Also, be sure you have your configure.php files set to save the session in MySQL as well. This may be the reason your cart is emptied upon clicking on $cartcontents.

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

PERFECT!! Thank you.

 

One question regarding non-category/products links:

 

If a url is like this: <li class="bg_list"><a href="/allmanufacturers.php?">BRANDS</a></li>

 

would I input it like this....?

 

<li class="bg_list"><a href="<?php echo tep_href_link('index.php', 'allmanufacturers.php&', 'NONSSL'); ?>">BRANDS</a></li>

Link to comment
Share on other sites

Hey guys,

 

I'm sure I'm forgetting something here - for some reason I think I've been down this road before :blush:

 

I am trying to run php in the template for the home page. I need it to check and see which customer ID is logged in and display a message accordingly. For some reason - the PHP is being ignored.

 

Here is what I am trying to run:

<?php 
// BOF Separate Price per Customer
if(!tep_session_is_registered('sppc_customer_group_id')) {
$customer_group_id = '0';
} else {
$customer_group_id = $sppc_customer_group_id;
}
// EOF Separate Price per Customer

if ($customer_group_id != 1) { 
?>
  <h3 align="center">Retail Special!!</h3> 
  <p><strong>Entire month of December - receive 10% off your order (before shipping) by using coupon code RTSLE1208 during checkout!</strong></p> 
 <?php
} 
 ?>

 

The section between BOF and EOF Separate Pricing per Customer is on the catalog/index.php page (as well as all pages in the catalog directory and most of the pages in the other folders). So I technically shouldn't need it on the index template - but gave it a shot since it was ignoring the check for customer_group_id.

 

How do I get this running on my index.php_0.html template?

 

Thanks ;)

~Tracy
 

Link to comment
Share on other sites

Hi!

 

I'm trying to install country_state_selector_ajax1.5.5 contrib. I've STS ialready installed.

 

The problem is that the functions of the ajax.js.php are not imported. I've installed this contribution in a clean OsCommerce installation and it works.

Installation instructions says that the way to invoke that functions is:

 

<?php
// +Country-State Selector
require('includes/form_check.js.php');
require('includes/ajax.js.php');
// -Country-State Selector
?>

 

I've that files included in that path.

 

When comparing both source codes i've notice these differences:

 

Working installation - It has the functions of ajax.js.php embebed in the HEAD of create_account.php

Broken installation - It hasn´t the functions of ajax.js.php embebed in the HEAD. By firebug I realize that ajax.js.php file is externally called by create_account.php and even I can see the functions needed to work. but these function are not executed. It gets an error

 

getStates is not defined
[Break on this error] getStates(this.value, "states");

 

 

That is, the function is called and I can see in Firebug, but it's not executed. In STS templates can't be included php code, however the functions included in form_check.js.php, are been executed.

 

What is the proper way to include the functions in the ajax.js.php file and that they'll be executed?

 

Thanks in advance

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.
Note: Your post will require moderator approval before it will be visible.

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