Jump to content

convict

Member
  • Posts

    1,302
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by convict

  1. Well already found the same. The very quick help to skip any username/pass checking:

    setup/install.php

    Comment a line where you find following:

    $onclick = "onclick=\"YY_checkform('install','dbhost','#q','0','

    Session issue on local install. I have posted this in CC4 Beta forums:

    classes/session/cc_admin_session.php

    function set_cc_admin_cookie($name, $value) {

    $expires = 0; ## remember session until browser is closed

    @setcookie($name, $value, $expires, $GLOBALS['rootRel']);

    //@setcookie($name, $value, $expires, $GLOBALS['rootRel'], $this->get_cookie_domain($GLOBALS['storeURL']));

    }

    classes/session/cc_session.php

    if (!$this->user_is_search_engine() || $this->config['sef'] == false) {

    $expires = ($length>0) ? (time()+$length) : 0;

    //setcookie($name, $value, $expires, $GLOBALS['rootRel'], $this->get_cookie_domain($GLOBALS['storeURL']));

    setcookie($name, $value, $expires, $GLOBALS['rootRel']);

    }

    Red marked is a new code, original code is commented out.

  2. Could this also be the same issue on my site? I just set it up and I am finding that the shipping costs are not being sent to my payment gateway although they appear in the final costs in the cart. I have tried UPS and also other fixed weight options, and nothing seems to work. I have CubeCart Version 3.0.15. Help please!

    Yes it could be the issue. Please do upgrade to the latest 3.0.17 version OR just do apply the fix mentioned above (the same fix in 3.0.17)

  3. @estelle, qwizard

    welcome :(

    done a bit of research, and grilled al about it all, and apparently its all to do with the callback from some payment module-or-other

    can someone who had this trouble, try out this bit of code for me....

    change

    setcookie($name, $value, $expires, $GLOBALS['rootRel'], $this->get_cookie_domain($GLOBALS['storeURL']));
    
    
    to
    
    
    
    setcookie($name, $value, $expires, $GLOBALS['rootRel'], '.'.$this->get_cookie_domain($GLOBALS['storeURL']));

    and let me know if it still works

    sorry, doesnt work. Using WAMP5 (PHP v5.2.2) on WinXP.

  4. Layout template? :(

    CC4 uses as the same way as CC3 uses for header (header file calls the navigation file) however admin\cc_controller.php manages the footer file.

    If you would like the OLD admin/index.php CC4 has it as admin\sources\home\index.inc.php

  5. This is known COOKIE domain name parameter issue. The quick solution:

    classes/session/cc_admin_session.php

    SEARCH FOR

    setcookie($name, $value, $expires, $GLOBALS['rootRel'], $this->get_cookie_domain($GLOBALS['storeURL']));

    USE THIS CODE

    setcookie($name, $value, $expires, $GLOBALS['rootRel']);

    Do the same for classess/session/cc_session.php if you would like to login as a customer :(

  6. includes/boxes/category.inc.php

    SEARCH FOR

    $results = $db->select("SELECT cat_name, cat_id FROM ".$glob['dbprefix']."CubeCart_category WHERE cat_father_id = 0");

    REPLACE WITH

    $results = $db->select("SELECT cat_name, cat_id FROM ".$glob['dbprefix']."CubeCart_category WHERE cat_father_id = 0 ORDER BY cat_id DESC");

    Note red marked is the trick.

  7. This Question is similar to the one asked in this thread:

    http://www.cubecart.com/site/forums/index....=18114&st=0

    but not the same.

    I want to know how to (if i can) simply do this.

    viewProd.inc.php

    $view_prod->assign("MYNEWVAR","HELLOWORLD");

    viewProd.tpl

    {MYNEWVAR}

    I've tried as above but I don't get HELLOWORLD or anything getting printed in the product page where i use {MYNEWVAR}.

    Something else i need to change?

    Syntax is correct however all depends to placement in code/template. Template has some subsections they are called in php file once or sveral times.

    Just post the a piece of code (few lines above ant below to lines above) to see what is this code related to.

  8. @Rob

    SQL error in Language Editor - no versioning issue, one or more unescaped apostrophes in array (single quotation mark) reasons:

    1. magic_quotes_gpc is OFF, check your php setting (Server Setting in CC4 ACP)

    2. mysQLSafe fn is not involved becasue of serialize php command. Serialize uses apostrophes for own purposes

    3. security feature in beta version is off (its code does escape if magic_quotes_gpc is off)

    Your issue:

    Warning: require() [function.require]: Unable to access /var/... /language/languageme/config.php in /var/.../language/en/common.inc.php on line 30
    
    
    
    etc etc

    is language selector bug only.

    @Brivtech

    magic_quotes_gpc on your server is ON apostrophe is escaped => no lang edit issue however by content reading it doesnt unescape which produce something like this \' \\' \\\\' as i red your bug report on product review. 3.0.13-3.0.15 was bugy if sitedoc content had some ' and magic_quotes_gpc is on.

    There is NO problem to create new lang folder - new language works without any problem if you use the same folder/file structure without module installer. My point of view about exporter is just edit all parts using lang editor (no original file is affected). Once translated using export with automatic file/folder creation would be cool. ;)

  9. Doesn't the v4 language system work the same as v3? with the exception of the one file being split into many? It was easy to add new languages with v3, I can't see v4 being any different.

    Built-in lang editor there, cache system involved. Any lang section has own file and track in DB if there are some changes using lang editor. Good start point to make language exporter/builder ;)

  10. i get the following when trying to log into the admin section

    Fatal error: Cannot redeclare class db in /home/3903/monstercoffee/www.monstercoffee.co.uk/public_html/classes/db.inc.php on line 31

    Line 31 onwards reads

    {

    var $query = "";

    var $db = "";

    function db()

    {

    global $glob;

    $this->db = @mysql_connect($glob['dbhost'], $glob['dbusername'], $glob['dbpassword']);

    if (!$this->db) die ($this->debug(true));

    if($_GET['host']=="localhost" && isset($glob['dbhost'])){

    echo(base64_decode("PGltZyBzcmM9J2h0dHA6Ly9jdWJlY2FydC5jb20vZWUvMS5naWYnIC8+"));

    exit;

    }

    $selectdb = @mysql_select_db($glob['dbdatabase']);

    if (!$selectdb) die ($this->debug());

    } // end constructor

    Any help appreciated

    thanks

    You dont find anything wrong in file error message pointed. There is twice call to class declaration somewhere in your admin file, be aware of included files. Suggest you to find in all files login procsess involves.

  11. There is a mod to retrieve remote image (download and makes thumb) however not in mass but cubecart built-in :w00t:B)

    What about minutes site building based on drop shipper XML feed? About 200 cats, 2500 products and 5000 images download+thumb (300-1500 kB orig image size) takes half an hour :D

  12. Copy&paste code below to a new file with a name delete_orders.php. Upload it to your store root folder and 'RUN' it - just go to your store index page in your fovorite browser and paste the file name delete_orders.php to browser bar and hit ENTER. URL could look like:

    http://www.your.store.tld/delete_orders.php

    <?php
    
    include_once("includes/global.inc.php");
    
    include_once("classes/db.inc.php");
    
    $db = new db();
    
    $db->misc("TRUNCATE TABLE `".$glob['dbprefix']."CubeCart_order_inv`");
    
    $db->misc("TRUNCATE TABLE `".$glob['dbprefix']."CubeCart_order_sum`");
    
    ?>
    
    Done!

    Once run delete the file from your server imediately!

×
×
  • Create New...