Jump to content

tementa

Members
  • Content count

    23
  • Joined

  • Last visited

  1. tementa

    [Contribution] STS v4

    Hi, How I can to display $languagebox in a drop-down menu? The file that makes the $languagebox display is includes/boxes/languages.php I tried this but I get no the right result <!-- languages //--> <tr> <td> <?php $info_box_contents = array(); $info_box_contents[] = array('text' => BOX_HEADING_LANGUAGES); new infoBoxHeading($info_box_contents, false, false); if (!isset($lng) || (isset($lng) && !is_object($lng))) { include(DIR_WS_CLASSES . 'language.php'); $lng = new language; } $languages_string = ''; reset($lng->catalog_languages); $languages_array = array(); while (list($key, $value) = each($lng->catalog_languages)) { $languages_array[] = array ('<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('language', 'currency')) . 'language=' . $key, $request_type) . '">' . tep_image(DIR_WS_LANGUAGES . $value['directory'] . '/images/' . $value['image'], $value['name']) . '</a>'); } $info_box_contents = array(); $info_box_contents[] = array('align' => 'center', 'text' => tep_draw_pull_down_menu('languages', $languages_string) . $hidden_get_variables . tep_hide_session_id()); new infoBox($info_box_contents); ?> </td> </tr> <!-- languages_eof //--> An the error that displays is this:
  2. tementa

    $languagebox drop-down menu

    I get this now <!-- languages //--> <tr> <td> <?php $info_box_contents = array(); $info_box_contents[] = array('text' => BOX_HEADING_LANGUAGES); new infoBoxHeading($info_box_contents, false, false); if (!isset($lng) || (isset($lng) && !is_object($lng))) { include(DIR_WS_CLASSES . 'language.php'); $lng = new language; } $languages_string = ''; reset($lng->catalog_languages); $languages_array = array(); while (list($key, $value) = each($lng->catalog_languages)) { $languages_array[] = array ('<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('language', 'currency')) . 'language=' . $key, $request_type) . '">' . tep_image(DIR_WS_LANGUAGES . $value['directory'] . '/images/' . $value['image'], $value['name']) . '</a>'); } $info_box_contents = array(); $info_box_contents[] = array('align' => 'center', 'text' => tep_draw_pull_down_menu('languages', $languages_string) . $hidden_get_variables . tep_hide_session_id()); new infoBox($info_box_contents); ?> </td> </tr> <!-- languages_eof //--> An the error that displays is this:
  3. Hi, How I can to display $languagebox in a drop-down menu? The file that makes the $languagebox display is includes/boxes/languages.php I tried this but I get no the right result <!-- languages //--> <tr> <td> <?php $info_box_contents = array(); $info_box_contents[] = array('text' => BOX_HEADING_LANGUAGES); new infoBoxHeading($info_box_contents, false, false); if (!isset($lng) || (isset($lng) && !is_object($lng))) { include(DIR_WS_CLASSES . 'language.php'); $lng = new language; } $languages_string = ''; reset($lng->catalog_languages); while (list($key, $value) = each($lng->catalog_languages)) { $languages_string .= '<option><a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('language', 'currency')) . 'language=' . $key, $request_type) . '">' . tep_image(DIR_WS_LANGUAGES . $value['directory'] . '/images/' . $value['image'], $value['name']) . '</a></option>'; } $info_box_contents = array(); $info_box_contents[] = array('align' => 'center', 'text' => $languages_string); new infoBox($info_box_contents); ?> </td> </tr> <!-- languages_eof //--> Please help Thanks in advance
  4. tementa

    [Contribution] STS v4

    Thanks a lot, Bill, it works perfect now!
  5. tementa

    [Contribution] STS v4

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

    [Contribution] STS v4

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

    [Contribution] STS v4

    Hi Bill, I notice that when i click on English button, all the texts turn into english. The problem is when i click on any Category box link, the category names turn into spanish again, the variable $languages_id=3 (spanish) instead $languages_id=5 (english) Where and what is needed to be modified in order to languages_id variable takes the right value? Thank you
  8. tementa

    [Contribution] STS v4

    You can see an example here: http://www.tutete.com/tienda_def/index.php? Category box is generated by dynamenu contrib. Some idea?, thak you
  9. tementa

    [Contribution] STS v4

    Hi! I've running STS and have been testing multilanguage functionality. When I click, for example in English, all the texts change to english, my problem is, after when I click in a category link or in a product link, the texts of Category box and the name of the products changes to the default language, but the other texts still remains in english. Some help, please.
  10. tementa

    STS and multilanguage

    Hi! I've running STS and have been testing multilanguage functionality. When I click, for example in English, all the texts change to english, my problem is, after when I click in a category link or in a product link, the texts of Category box and the name of the products changes to the default language, but the other texts still remains in english. Some help, please.
  11. Hi, I've installed Option Type Feature v1.6 (for osc 2.2 MS2). I'm trying to achieve that quantity and text values selected in the product info page will be reflecting in the shopping cart infobox, and when I'll click on the product text in the shopping cart infobox, the product info page shows the options previously selected. Do I have to install some update to OTF 1.6 or paste some new code? Thanks a lot
  12. tementa

    Option Type Feature 1.7

    Hi, I've installed STS v4.5.8 and option_type_feature-v1.5. I've created a Quantity radio button option, with 3, 6, and 9 values. The attirbutes has the following values Quantity Price 3 10.55€ 6 19.00€ 9 27.00€ When I add a product and select, for example Quantity 6 - Price 19.00 € the shopping_cart page shows a price of -8.45EUR. I've seen that something similar is achieved in the demo http://www.openstoresolutions.com/demos/catalog/index.php. If possible in this contribution to configure an option that allows to explained above, how is this achived? or should I use anothere contrib as Price_Break_Per_Products. Thanks a lot
  13. Hi, I've installed STS v4.5.8 and option_type_feature-v1.5. I've created a Quantity radio button option, with 3, 6, and 9 values. The attirbutes has the following values Quantity Price 3 10.55€ 6 19.00€ 9 27.00€ When I add a product and select, for example Quantity 6 - Price 19.00 € the shopping_cart page shows a price of -8.45EUR. If possible in this contribution to configure an option that allows to explained above, or should I use anothere contrib as Price_Break_Per_Products. Thanks a lot
  14. tementa

    [Contribution] STS v4

    Any experience with STS and Imprint text options contribution? I can't use the input text atributtes created with Imprint text options in my product info templates. Thanks
  15. tementa

    [Contribution] STS v4

    Hi Bill, I did what you say but it didn't work. I tried another thing, I copy the code generated by the add-on script (an input with a given name) and paste in a product template, it works. Then I paste this code in the rest of my product templates but didn't work, only works for one product_info template. Any idea to solve it? Thanks a lot
×