Changeset 1755

Show
Ignore:
Timestamp:
09/20/2008 09:11:09 PM (4 months ago)
Author:
jeena
Message:

Added some TODOs, thoughts and comments

Location:
branches/1.5
Files:
1 removed
11 modified

Legend:

Unmodified
Added
Removed
  • branches/1.5/lib/Jlog/Db.php

    r1754 r1755  
    1717        // select our database 
    1818        $select = @mysql_select_db(JLOG_DB); 
     19        // FIXME: we already do have this lines, see line 13 in this file, isn't it? 
    1920        if ($connect == FALSE) { 
    2021          mail(JLOG_EMAIL, $l->_('admin.e_db'), $l->_('admin.e_db_is')."\n".mysql_error()); 
     
    3435    // escape input for mysql 
    3536    function escape($_data) { 
    36         if (is_array($_data)) foreach($_data as $key => $val) $_data[$key] = escape_for_mysql($val); 
     37        // FIXME: shouldn't we  use mysql_real_escape*() here? (Jeena) 
     38        if (is_array($_data)) foreach($_data as $key => $val) { 
     39            $_data[$key] = escape_for_mysql($val); 
     40        } 
    3741        else $_data = mysql_escape_string($_data); 
    3842        return $_data; 
  • branches/1.5/lib/Jlog/Feeds.php

    r1754 r1755  
    77     *  
    88     * Returns boolean true if all operations were executed successfully  
    9      * or returns an array with error information otherwise.           
     9     * or returns an array with error information otherwise. 
     10     * 
     11     * TODO: (Jeena) I don't really like the Idea of returning different types 
     12     * we should return true or false and store the errors within the Feeds-Object. 
    1013     *           
    1114     * @access public      
     
    123126        /** 
    124127         * TODO: get $plugins object, seems to be undefined here! 
     128         * (Jeena) I think because $plugin is not global here? 
    125129         **/ 
    126130        if (isset($plugins) and is_object($plugins)) { 
  • branches/1.5/lib/Jlog/Functions.php

    r1754 r1755  
    155155    } 
    156156 
     157    // TODO: (Jeena) Remove it, we never used it anyway 
    157158    function my_serialize_cfg($arg) {    
    158159        if(is_string($arg)) return "'".preg_replace("/'/","\\'",$arg)."'"; 
  • branches/1.5/lib/Jlog/Language.php

    r1754 r1755  
    1818            if ($res === false) { 
    1919                // TODO: Think about something prettier than die 
     20                // (Jeena) We could write something like a Exception or Error class 
    2021                die ('Fatal Error: Jlog could not found the language files it was configured to use.'); 
    2122            } 
  • branches/1.5/lib/Jlog/Template.php

    r1749 r1755  
    121121$body = $plugins->callHook('body', $body, $jlogTemplateTags); 
    122122 
    123 /* // we don't need it yet, but perhaps later 
    124  
    125   function ensureUTF8($str) { 
    126     $pattern = '~([\\xC2-\\xDF][\\x80-\\xBF]| #utf8-2 
    127                   \\xE0[\\xA0-\\xBF][\\x80-\\xBF]|[\\xE1-\\xEC][\\x80-\\xBF]{2}| #utf8-3 
    128                   \\xED[\\x80-\\x9F][\\x80-\\xBF]|[\\xEE-\\xEF][\\x80-\\xBF]{2}| #utf8-3                   
    129                   \\xF0[\\x90-\\xBF][\\x80-\\xBF]{2}|[\\xF1-\\xF3][\\x80-\\xBF]{3}| #utf8-4 
    130                   \\xF4[\\x80-\\x8F][\\x80-\\xBF]{2}) #utf8-4 
    131                   |([^\\x00-\\x7F])~x'; 
    132     return preg_replace_callback($pattern, 'ensureUTF8CharCallback', $str); 
    133   } 
    134  
    135   function ensureUTF8CharCallback($charmatch) { 
    136     if (isset($charmatch[2]) && $charmatch[2] != '') { 
    137       return chr(0xC0|ord($charmatch[2])>>6).chr(0x80|ord($charmatch[2])&0x3F); 
    138     } else { 
    139      return $charmatch[0]; 
    140    } 
    141   } 
    142 */ 
    143 ?> 
     123// eof 
  • branches/1.5/lib/Jlog/Update/110To111.php

    r1738 r1755  
    11<?php 
    22 
     3// TODO: (Jeena) I think we should not bother the user with the update-script 
     4// when it is not necessary. 
    35class JlogUpdate_110To111 
    46{ 
  • branches/1.5/lib/Jlog/Update/Example.php

    r1738 r1755  
    1919     
    2020    /** 
    21      * This function shoul prepare parts of the form for the update 
     21     * This function should prepare parts of the form for the update 
    2222     *  
    2323     * It gets the language array as the first parameter and 
  • branches/1.5/lib/Jlog/Validate/Url.php

    r1753 r1755  
    11<?php 
     2 
     3// TODO: I'm not shure we really need this. It was a part of the 
     4// Stringparser class, but it is too old and doesn't cover all 
     5// the new domains, etc. 
    26 
    37class Jlog_Validate_Url 
  • branches/1.5/lib/Pear/HttpRequest.php

    r1754 r1755  
    11<?php 
     2// TODO: (Jeena) replace it with the easier version of get_remote_file() from 
     3// http://jeenaparadies.net/weblog/2007/jan/get_remote_file or something. 
     4// We really just need it for getting Pingback resources. 
     5 
    26 /** 
    37  * PEAR, HTTP_Request, Net_Socket, Net_URL in one file for Jlog 
  • branches/1.5/lib/bootstrap.php

    r1754 r1755  
    2525 
    2626// define path to library folder 
    27 error_reporting(E_ALL ^ E_NOTICE); 
     27error_reporting(E_ALL ^ E_NOTICE);  // TODO: We should remove this line now 
    2828define ('JLOG_LIBPATH', dirname(__FILE__)); 
    2929set_include_path(JLOG_LIBPATH . PATH_SEPARATOR . get_include_path()); 
  • branches/1.5/themes/default/javascripts.js

    r1748 r1755  
     1// TODO: I'd like to have an extra "js" directory for all JavaScripts 
     2// a theme needs. 
     3 
    14function jlog_bbcode_insert(aTag, eTag, completeText) { 
    25  var input = document.forms['entryform'].elements['content'];