Ignore:
Timestamp:
Feb 20, 2014 3:03:59 AM (10 years ago)
Author:
anonymous
Message:

Completed integrating /branches/eli_branch into /trunk. Changes include:

  • Removed closing ?> from end of files
  • Upgrade old-style contructor methods to use construct() instead.
  • Class properties and methods defined as public, private, static or protected
  • Ensure code runs under E_ALL with only mysql_* deprecated warnings
  • Search for the '@' symbol anywhere it might be used to supress runtime errors, then replace with proper error recovery.
  • Run the php cli -l option to check files for syntax errors.
  • Bring tests up-to-date with latest version and methods of PHPUnit
Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/lib/TemplateGlue.inc.php

    r407 r468  
    44 * For details visit the project site: <http://trac.strangecode.com/codebase/>
    55 * Copyright 2001-2012 Strangecode, LLC
    6  * 
     6 *
    77 * This file is part of The Strangecode Codebase.
    88 *
     
    1111 * Free Software Foundation, either version 3 of the License, or (at your option)
    1212 * any later version.
    13  * 
     13 *
    1414 * The Strangecode Codebase is distributed in the hope that it will be useful, but
    1515 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1616 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
    1717 * details.
    18  * 
     18 *
    1919 * You should have received a copy of the GNU General Public License along with
    2020 * The Strangecode Codebase. If not, see <http://www.gnu.org/licenses/>.
     
    2424 * TemplateGlue.inc.php
    2525 */
    26 
    27 /**
    28  * Print URL to download file with BBEdit/Interarchy. "USER" must be a pre-set
    29  * environment variable. Files must reside within and be relative to env "DOCUMENT_ROOT".
    30  *
    31  * @access  public
    32  * @param   mixed   $file   File path relative to DOCUMENT_ROOT (i.e. '/_templates/index.ihtml').
    33  * @return  string  <a> with file basename as text.
    34  */
    35 function bbftp($file)
    36 {
    37     return sprintf('<a href="bbftp://%s@%s:%s%s" title="%s" style="text-decoration: none; border-bottom: blue 1px dotted;">%s</a>', $_SERVER['USER'], $_SERVER['HTTP_HOST'], $_SERVER['DOCUMENT_ROOT'], $file, $file, basename($file));
    38 }
    3926
    4027/**
     
    8976    $app =& App::getInstance();
    9077    $db =& DB::getInstance();
    91    
     78
    9279    $qid = $db->query("SHOW COLUMNS FROM " . $db->escapeString($db_table) . " LIKE '" . $db->escapeString($db_col) . "'",false);
    9380
     
    9582    if (preg_match('/^enum|^set/i', $row[1]) && preg_match_all("/'([^']*)'/", $row[1], $enum)) {
    9683        if ($sort) {
    97             natsort($enum[1]);           
     84            natsort($enum[1]);
    9885        }
    9986        return $enum[1];
     
    329316{
    330317    $db =& DB::getInstance();
    331    
     318
    332319    // Sometimes preselected comes as a comma list.
    333320    if (!is_array($preselected)) {
     
    373360{
    374361    $db =& DB::getInstance();
    375    
     362
    376363    // Sometimes preselected comes as a comma list.
    377364    if (!is_array($preselected)) {
     
    501488    }
    502489}
    503 
    504 ?>
Note: See TracChangeset for help on using the changeset viewer.