Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Davelaar

Pioneers
  • Posts

    26
  • Joined

  • Last visited

Posts posted by Davelaar

  1. function validNumeric(inputtext)
    {
       var text = inputtext.value;
       var Char;
       var newtext = '';
       var newtext1 = '';
       var newtext2 = '';
       var j =0;
       var i;
       var is_decimal = false;
    
       for (i = 0; i < text.length ; i++)
       {
        Char = text.charAt(i);
        if( (Char != '0') || (newtext.length >0) )
        {
    	    if((! isNaN(Char) && Char != ' ') || (Char == '.'))
    	    {
    		    newtext +=  Char;
    	    }
        }
       }
    
       for (i = (newtext.length -1) ; i >=0; i--)
       {
        Char = newtext.charAt(i);
        if( Char != '.' || ((Char == '.') && (is_decimal == false) && (newtext1.length > 0)) )
        {
    	    newtext1 =  Char + newtext1;
    	    if(Char == '.')
    		    is_decimal = true;
        }
       }
    
       var begin = newtext1.length -1 ;
       var varend = '';
       var k = newtext1.indexOf('.');
    
       if(k != -1)
       {
        for(i = k;i < newtext.length;i++)
    	    varend +=  newtext1.charAt(i);
    
        begin = k-1;
       }
    
       j = 0;
       for(i = begin ;i>=0;i--)
       {
        Char = newtext1.charAt(i);
        newtext2 = Char + newtext2;
        j++;
        if((j==3) && (i>0))
        {
    	    newtext2 = newtext2 + newtext2;
    	    j = 0;
        } 
       }
    
       if(newtext2.length == 0)
        newtext2 = '0';
    
       newtext2 += varend;
       inputtext.value = newtext2;
    }
    

  2. Well, with very much thanks to multimixer I've got it working :D . But when I put an value in the Bid price it co'pies the last three digit and adds that to the bid. By example: I want to bid €1400 but when I click on "BID" it bids €1400400. What can be the cause of that?

    <script type="text/javascript">
     function post_bibs(){
      var max_price = 99999999999999999;
      $('#msg_error').hide();
      $('#msg_success').hide();
      var price_bib = $('#bid_price').val();
      var auction_id = $('#auction_id').val();
      if(parseInt(price_bib)>max_price){
       return false;
      }
      if(price_bib>0){
       $('#auction_bid_waitting').show();
       $.post('http://www.davelaarscooters.nl/auctions_api.php', {p_auctions_id: auction_id, p_price_bib: price_bib}, function(data) {				   
     switch(data.flag_return.code)
     {						   
      case 1:
       $('#msg_success').html(data.flag_return.message);
       $('#msg_success').show();
       $('span#show_total_bids').html(data.data_renew.bids);
       $('span#price_curent_bid').html(data.data_renew.price_show);
       $('#bidder').html(data.data_renew.customers_firstname);
       $('span#price_greater').html(data.data_renew.min_next_price_show);								   
       break;
      case 2:
       $('#msg_success').html(data.flag_return.message);
       $('#msg_success').show();
       break;
      default:
       $('#msg_error').html(data.flag_return.message);
       $('#msg_error').show();
     };
     var $container = $("#tbody_list_bids");
     $container.load('http://www.davelaarscooters.nl/auctions_get_list_bids.php?aID=29');
     $('#auction_bid_waitting').hide();					   
       }, "json");				   
      }
     }		   
     function change_page_bid(auction_id, page){
      $.get('http://www.davelaarscooters.nl/auctions_get_list_bids.php',{page: page, aID: auction_id}, function(data) {				   
       $('#tbody_list_bids').html(data);
      },"html");				 
     }
     function change_page(page, div_id){
      $('#'+div_id).html('<img src="images/auctions/opc-ajax-loader.gif" border="0"/>'); 
      $.post('http://www.davelaarscooters.nl/auctions_get_auctions_api.php',{p_page: page, p_div_id: div_id}, function(data) {				   
       $('#'+div_id).html(data.flag_return.message);
      }, "json"); 
    
     }
     $(function() {
      $( "#tabs" ).tabs({
       ajaxOptions: {
     error: function( xhr, status, index, anchor ) {
      $( anchor.hash ).html(
      "Couldn't load this tab. We'll try to fix this as soon as possible. " +
       "If this wouldn't be a demo." );
     }
       }
      });
     });		   
    </script>
    <!-- EOF: Auction css and js -->
    

  3. Well, with very much thanks to multimixer I've got it working :D . But when I put an value in the Bid price it co'pies the last three digit and adds that to the bid. By example: I want to bid €1400 but when I click on "BID" it bids €1400400. What can be the cause of that?

  4. Here is the complete contri attached. I've changed the referral from jquery and no difference. The contri was designed for 2.3.1.

    I thougt it should be working though I really can't find why I get this error. Fatal error: Class 'splitPageResultsAuctions' not found in /home/davelaarscooters.nl/public_html/davelaar/auctions.php on line 48

     

  5. Hello, I've installed osc 2.3.3 and installed various contribs. Now yesterday I've installed auction_free for osc 2.3.1 and I have the Idea that there is a compatibility issue with osc. 2.3.1 OR with MTS template system. Of course it's possible that I installed it wrong but after two times installing it the only thing I've found is the next line that differs. Installation instructions ask for the next line: <script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.8.6.min.js"></script> but I have this line: <script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.8.22.min.js"></script> My error on may auctions page on the catalog side is: Fatal error: Class 'splitPageResultsAuctions' not found in....../auctions.php on line 48

  6. Aha, well now it also changes the looks a bit. Sorry to bother you this much, I now how to read and change line, but don't understand the most of what I read in php. Now I'm going to edit the design and check for functionality. I hope I don't have to come back here for this thing... By the way, Is there a layout scheme for IOSC, what says wich value to change or just sort it out? Are there any templates available?

  7. Did you run the complete sql script in installation step 1?:

    1.- run this sql script in your database:

    INSERT INTO `configuration_group` (`configuration_group_id`, `configuration_group_title`, `configuration_group_description`, `sort_order`, `visible`) VALUES ('6128', 'Mobile Site', 'Configuration values for mobile site', '160', '1');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Enable Mobile Site?', 'MOBILE_SITE', 'True', 'Do you want to enable the mobile version of the site?', '6128', '1', NULL, '', NULL, 'tep_cfg_select_option(array(''True'', ''False''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Image Width', 'MOBILE_IMAGE_WIDTH', '80', 'The pixel width of mobile images', '6128', '2', NULL, '', NULL, NULL);
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Image Height', 'MOBILE_IMAGE_HEIGHT', '80', 'The pixel height of mobile images', '6128', '3', NULL, '', NULL, NULL);
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Product Name Length', 'MOBILE_PRODUCT_NAME_LENGTH', '55', 'The max length of product names shown in product listing', '6128', '4', NULL, '', NULL, NULL);
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Debug Mode', 'MOBILE_DEBUG', 'false', 'Mobile debug mode: leave false for live shops', '6128', '5', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Enable Ajax', 'AJAX_ENABLED', 'false', 'Ajax enabled', '6128', '6', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Compatibility Mode', 'COMPATIBILITY_MODE', 'false', 'Enable compatibility mode for testing purpose, leave false for live shops', '6128', '7', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Footer Date', 'FOOTER_DATE_ENABLED', 'true', 'Show the date in the mobile footer.', '6128', '8', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Mobile Footer Statistics', 'FOOTER_SITE_STATS_ENABLED', 'true', 'Show the statistics in the mobile footer.', '6128', '9', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Manufacturers in Advanced Mobile Search', 'SHOW_MANUFACTURERS_SEARCH_MENU', 'true', 'Show the manufacturers drop down menu in the advanced mobile search page.', '6128', '10', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Categories in Advanced Mobile Search', 'SHOW_CATEGORIES_SEARCH_MENU', 'true', 'Show the categories drop down menu in the advanced mobile search page.', '6128', '11', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Price range in Advanced Mobile Search', 'SHOW_SEARCH_BY_PRICE_RANGE', 'true', 'Show the price range option in the advanced mobile search page.', '6128', '12', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES (NULL, 'Date range in Advanced Mobile Search', 'SHOW_SEARCH_BY_DATE_RANGE', 'true', 'Show the date range option in the advanced mobile search page.', '6128', '13', NULL, '', NULL, 'tep_cfg_select_option(array(''true'', ''false''), ');
    

     

    this adds a Configuration Group for the mobile site to Admin: Configuration.

    Well I've put back the old database now and run the query again, just because I thougt I saw an error. Wel I run the query again and there was indeed an error:

    SQL-query:

    INSERT INTO `configuration` ( `configuration_id` , `configuration_title` , `configuration_key` , `configuration_value` , `configuration_description` , `configuration_group_id` , `sort_order` , `last_modified` , `date_added` , `use_function` , `set_function` )

    VALUES (

    NULL
    ,
    'Mobile Image Width'
    ,
    'MOBILE_IMAGE_WIDTH'
    ,
    '80'
    ,
    'The pixel width of mobile images'
    ,
    '6128'
    ,
    '2'
    ,
    NULL
    ,
    ''
    ,
    NULL
    ,
    NULL

    );

     

     

    MySQL retourneerde: b_help.png

    #1048 - Column 'set_function' cannot be null

  8. Ok after installing seo urls it works now, thnks so far. But in the instructions from the installation you are talking about this: in: Admin/Configuration/Mobile Site

    ***adjust the image size you wish for the product images shown

    in mobile_catalogue.php (mobile/includes/modules/product.php), mobile_product_info.php, mobile_also_purchased_products.php here:

    Mobile Image Width

    Mobile Image Height

    ***Adjust the max. product name length you wish for mobile catalogue.php here:

    define ('MOBILE_PRODUCT_NAME_LENGTH', 55);

    ***If you wish to show todays date in the mobile-footer, set it here to true:

    define ('FOOTER_DATE_ENABLED', false);

    define ('FOOTER_SITE_STATS_ENABLED', false);

    ***If you wish to show the stats of your shop in the mobile-footer, set it here to true:

    ***Adjust the advanced mobile search options to your need:

    Note: If you set all advanced mobile search options to 'false',

    the button in 'search.php' which links to the advanced search page

    will not be shown, and the redirect link from the advanced search page

    of the 'classic' site will redirect to 'mobile_search.php' instead of 'mobile_advanced_search.php'.

    Note: Ajax is not working in this iosc version, leave the setting in "false" I don't have any configuration options in admin/configuration/mobile site just true or false for mobile site on or off. I have this message with all of my products: Warning: substr()expects parameter 3 to be long, string give in ...../mobile/includes/modules/products.php on line 36. In my mobile_catalogue there is no define ('MOBILE_PRODUCT_NAME_LENGTH', 55); anywhere

  9. O.K. you have SEO URLs installed in your shop.

    You need to download and install the mobile support:

    Contribution support 1.0 for iOSC 5.x

     

    There is support included for

     

    - ULTIMATE Seo Urls 5 - by FWR Media

    http://addons.oscommerce.com/info/6768

     

    and

     

    - Ultimate SEO 2-2.2d-12 - by chemo

    http://addons.oscommerce.com/info/2823

     

    regards

    Rainer

    I'll give it a shot, thanks in advance

  10. It sounds like you replaced the whole lines in mobile_redirect.php instead of only "split"

     

    It should look like this:

    function redirect() {
    global $mobile_site;
    if(isset($mobile_site)) {
    $path = explode("/" ,$mobile_site);
    $file = $path[sizeof($path)-1];
    } else {
    $path = explode("/" , $_SERVER['SCRIPT_NAME']);
    $filename = $path[sizeof($path)-1];
    $file = $this->mobileDir . $filename;
    }
    $qstring = $_SERVER['QUERY_STRING'];
    $SSL = ($_SERVER['HTTPS']) ? "SSL" : "NONSSL";
    tep_redirect(tep_href_link($file, $qstring, $SSL, false, false));
    }
    

     

    If it's not this please post the code of your changes and the url of your shop.

     

    rainer

    function redirect() {
    global $mobile_site;
    if(isset($mobile_site)) {
    $path = explode("/" ,$mobile_site);
    $file = $path[sizeof($path)-1];
    } else {
    $path = explode("/" , $_SERVER['SCRIPT_NAME']);
    $filename = $path[sizeof($path)-1];
    $file = $this->mobileDir . $filename;
    }
    $qstring = $_SERVER['QUERY_STRING'];
    $SSL = ($_SERVER['HTTPS']) ? "SSL" : "NONSSL";
    tep_redirect(tep_href_link($file, $qstring, $SSL, false, false));
    }
    }
    

    It looks he same, the url of my website is www.davelaarscooters.nl I turned the mobile site function of since its not working now. I also noticed there are no cinfiguration options in my admin see attachment

  11. Hello, I'm trying to install iosc for osc 2.3.3. I still get the following error even after disabling my output_buffering and checking al the modified files for empty rules: Deprecated: Function split() is deprecated in .../mobile/includes/classes/mobile_redirect.php on line 43 Warning: Cannot modify header_information - headers already sent by (output started at .../includes/functions/general.php on line 49

  12. I've put this script on my website to create a feed for Leguide.com. It works well, but the special prices are displayed without tax. The normal prices are displayed including tax. How can I change this. I've put the code here. I'm using OSC 2.3.3 I've also put the whole .php script as an attachment.

    // Détection des discount price.
    $special_query = tep_db_query ('SELECT specials_new_products_price FROM ' . TABLE_SPECIALS . ' WHERE products_id = \'' . $products['products_id'] . '\' AND status = \'1\' ;') ;
    if (!$special_result = tep_db_fetch_array ($special_query))
    $special_result['specials_new_products_price'] = '' ;
    
    // Calcul des prix.
    $regular_price = tep_add_tax ($products['products_price'], tep_get_tax_rate ($products['products_tax_class_id'])) ;
    $regular_price = round ($regular_price, 2) ;
    if ($special_result['specials_new_products_price'] == '' ) {
    $discount_price = '' ;
    $sales = 0 ;
    } else { //Le produit est en promotion.
    $discount_price = round ($special_result['specials_new_products_price'], 2) ;
    $sales = 0 ; //Si les promotions sont des soldes, modifiez cette valeur par 1 pour la 1ère démarque, 2 pour la 2ème démarque.
    

  13. Write /home/davelaarscooters.nl/public_html/davelaar/sitemapproducts.xmlGenerated Google Product Sitemap Successfully
    Write /home/davelaarscooters.nl/public_html/davelaar/sitemapcategories.xmlGenerated Google Category Sitemap Successfully
    Write /home/davelaarscooters.nl/public_html/davelaar/sitemapmanufacturers.xmlGenerated Google Manufacturers Sitemap Successfully
    Write /home/davelaarscooters.nl/public_html/davelaar/sitemapspecials.xmlGenerated Google Specials Sitemap Successfully
    ERROR: Google Pages Sitemap Generation FAILED!
    Write /home/davelaarscooters.nl/public_html/davelaar/sitemapindex.xmlGenerated Google Sitemap Index Successfully
    Array
    (
       [QUERY] => Array
        (
    	    [PRODUCTS] => Array
    		    (
    			    [sTATUS] => success
    			    [NUM_ROWS] => 123
    		    )
    	    [CATEOGRY] => Array
    		    (
    			    [sTATUS] => success
    			    [NUM_ROWS] => 35
    		    )
    	    [MANUFACTURERS] => Array
    		    (
    			    [sTATUS] => success
    			    [NUM_ROWS] => 24
    		    )
    	    [sPECIALS] => Array
    		    (
    			    [sTATUS] => success
    			    [NUM_ROWS] => 11
    		    )
        )
       [sAVE_FILE_XML] => Array
        (
    	    [0] => Array
    		    (
    			    [file] => /home/davelaarscooters.nl/public_html/davelaar/sitemapproducts.xml
    			    [status] => success
    			    [file_exists] => true
    		    )
    	    [1] => Array
    		    (
    			    [file] => /home/davelaarscooters.nl/public_html/davelaar/sitemapcategories.xml
    			    [status] => success
    			    [file_exists] => true
    		    )
    	    [2] => Array
    		    (
    			    [file] => /home/davelaarscooters.nl/public_html/davelaar/sitemapmanufacturers.xml
    			    [status] => success
    			    [file_exists] => true
    		    )
    	    [3] => Array
    		    (
    			    [file] => /home/davelaarscooters.nl/public_html/davelaar/sitemapspecials.xml
    			    [status] => success
    			    [file_exists] => true
    		    )
    	    [4] => Array
    		    (
    			    [file] => /home/davelaarscooters.nl/public_html/davelaar/sitemapindex.xml
    			    [status] => success
    			    [file_exists] => true
    		    )
        )
    )
    
    

    My sitemaps work most of it excluding the "pages". What can be the problem?

  14. and my includes/configure.php

    <?php
     define('HTTP_SERVER', 'http://www.davelaarscooters.nl');
     define('HTTPS_SERVER', 'http://www.davelaarscooters.nl');
     define('ENABLE_SSL', false);
     define('HTTP_COOKIE_DOMAIN', '');
     define('HTTPS_COOKIE_DOMAIN', '');
     define('HTTP_COOKIE_PATH', '/');
     define('HTTPS_COOKIE_PATH', '/');
     define('DIR_WS_HTTP_CATALOG', '/');
     define('DIR_WS_HTTPS_CATALOG', '/');
     define('DIR_WS_IMAGES', 'images/');
     define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
     define('DIR_WS_INCLUDES', 'includes/');
     define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
     define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
     define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
     define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
     define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
     define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');
     define('DIR_FS_CATALOG', '/');
     define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
     define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
     define('DB_SERVER', '127.0.0.1');
     define('DB_SERVER_USERNAME', '*****');
     define('DB_SERVER_PASSWORD', '*****'');
     define('DB_DATABASE', '*****'');
     define('USE_PCONNECT', 'false');
     define('STORE_SESSIONS', 'mysql');
    ?>
    

×
×
  • Create New...