Jump to content

Stephan (VS)

  • Content count

  • Joined

  • Last visited

Reputation Activity

  1. Like
    Stephan (VS) got a reaction from ronrrico in FCK WYSIWYG HTML editor   
    I'm having the same issue on my one site wil post if I find it but that's not a priority now...

    2.7's been the latest one for a while, I think they renamed FCK Editor to CKEditor or somethin, but anyway,
    Your using this Contribution Right?
    Check your "images" directory permissions are set to 777,
    Check fck's config.php file, (Elmer Fudd Voice) <- This is veeeery importan, I'd start here.
    Make sure it's in "catalog/admin/fckeditor" and remember to change your admin folder later for security,
    Alter "/admin/categories.php" to change the Textarea
    Check /admin/includes/functions/html_output.php
    and the tips:
    in catalog/admin/fckeditor/fckconfig.js
    change line 153 from:
    FCKConfig.FontSizes = 'smaller;larger;xx-small;x-small;small;medium;large;x-large;xx-large' ;
    FCKConfig.FontSizes = '8;10;12;14;16;18;20;24;28;32;36;42;50;58;66;smaller;larger;xx-small;x-small;small;medium;large;x-large;xx-large' ;
    To add extra, but still standard fonts, change line 152 from:
    FCKConfig.FontNames = 'Arial;Comic Sans MS;Courier New;Tahoma;Times New Roman;Verdana' ;
    FCKConfig.FontNames = 'Arial;Arial Black;Comic Sans MS;Courier New;Tahoma;Times New Roman;Verdana;Georgia;Impact;Palatino Linotype;Trebuchet MS' ;
  2. Like
    Stephan (VS) reacted to spooks in Simple Multi Image Add-on (Un-Limited) with FancyBox Popups   
    Complete the install as detailed!!
  3. Like
    Stephan (VS) reacted to Anono in Warning: Mysql_fetch_array(): Supplied Argument Is Not A Valid Mysql Result Resource In Includes/functions/database.php On Line 99?   
    Here is help for the following error:
    Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /var/www/html/oscommerce/includes/functions/database.php on line 99
    Line 98-100 of my database.php file contained:

    function tep_db_fetch_array($db_query) { return mysql_fetch_array($db_query, MYSQL_ASSOC); }
    Clearly, somewhere in my code I had a call to tep_db_fetch_array, in which I was passing an invalid resource. The proper way to call tep_deb_fetch_array is to first prepare a select statement using tep_db_query, as shown below:

    $my_select_statement = 'Select * from ' . TABLE_CATEGORIES; $my_query = tep_db_query($my_select_statement); while ($my_result_row = tep_db_fetch_array($my_query)) { $my_cat_id = $my_result_row['categories_id']; .... }
    The function tep_db_query returns an resource of type 'mysql result'. If $my_query had been an invalid resource (eg not defined, or null, containing a string or numeric value, or containing anything at all other than a properly formed 'mysql result' resource), then it would have caused warning message I saw.
    One way of testing your code is to call mysql_query directly, bypassing all the osc wrappers, like so:

    $my_select_statement = 'Select * from ' . TABLE_CATEGORIES; $qr1 = mysql_query ($my_select_statement) or die ("Query failed: " . mysql_error() . " Actual query: " . $my_select_statement);
    In my case, I got this warning message after making a mistake in installing Linda McGrath's very nice addon Attributes Sorter and Copier (http://www.oscommerce.com/community/contributions,772) version 5.1b. It concerned some tricky merging of code in the file catalog\admin\categories.php, tricky because I had already edited that section of code with other addons (Additional Images and New Attribute Manager). I had the line:

    while ($new_images = tep_db_fetch_array($images_product)) {
    But $images_product was undefined because I had overwritten the code that defined it.
    The tricky section of code in file catalog\admin\categories.php started with:

    default: if ($rows > 0) { if (isset($cInfo) && is_object($cInfo)) {
    and ended with:

    } else { // create category/product info $heading[] = array('text' => '<b>' . EMPTY_CATEGORY . '</b>'); $contents[] = array('text' => TEXT_NO_CHILD_CATEGORIES_OR_PRODUCTS); } break; }
    By reinstalling this section of code from my backup, and then more carefully installing the Attributes Sorter and Copier addon, I was able to fix the problem.