TaniPHP
[ class tree: TaniPHP ] [ index: TaniPHP ] [ all elements ]

Class: Framework

Source Location: /backup.php

Class Overview


Framework class that holds helper methods


Author(s):

  • Dumitru Postoronca

Methods



Class Details

[line 394]
Framework class that holds helper methods

Framework class that holds helper methods




Tags:

author:  Dumitru Postoronca


[ Top ]


Class Methods


constructor Framework [line 400]

Framework Framework( )

Class constructor that actually disallows creating instances of the class

Class constructor that actually disallows creating instances of the class




[ Top ]

method croak [line 637]

void croak( string $message, [mixed $die = true], string $sql, string $error)

Display a nicely formatted error

Display a nicely formatted error




Tags:

static:  


Parameters:

string   $message   A message to display
string   $sql   Optional SQL query
string   $error  

[ Top ]

method forward [line 621]

void forward( string $controller, string $action)

Forwards request to another Controller/Action

Forwards request to another Controller/Action




Tags:

static:  


Parameters:

string   $controller   Controller to forward to
string   $action   Action to pass to

[ Top ]

method getConfiguration [line 513]

mixed getConfiguration( string $section, [string $var = null])

Returns a configuration setting.

Returns a configuration setting. If $var is not set, will return a whole section. If the requested configuration is not found, null is returned.




Tags:

staticvar:  array $config: Caches the configuration file in memory
static:  


Parameters:

string   $section   The INI-file section
string   $var   (optional) The variable to return

[ Top ]

method getControllerClassName [line 419]

string getControllerClassName( string $controller)

Generates a controller class name

Generates a controller class name

  1. <?php
  2. // will return Default_Controller
  3. Framework::getControllerClassName("dEfAuLt")
  4. ?>




Tags:

return:  The controller class name
static:  


Parameters:

string   $controller   URL-like controller name

[ Top ]

method getControllerPath [line 431]

string getControllerPath( string $controller)

Generates a full path to the controller file

Generates a full path to the controller file




Tags:

return:  Path to controller
static:  


Parameters:

string   $controller   URL-like controller name

[ Top ]

method getDatabaseConnection [line 554]

object PEAR::DB getDatabaseConnection( )

(Singleton) Returns a database connection

(Singleton) Returns a database connection




Tags:

return:  database connection object
staticvar:  object $conn: Holds the database connection object
static:  


[ Top ]

method getModelClassName [line 483]

string getModelClassName( string $model)

Generates a Model class name

Generates a Model class name

  1. <?php
  2. // will return Post
  3. Framework::getModelClassName("PoSt")
  4. ?>




Tags:

return:  View class name
static:  


Parameters:

string   $model   The model name

[ Top ]

method getModelPath [line 495]

string getModelPath( string $model)

Generates a full path to the model file

Generates a full path to the model file




Tags:

return:  Path to model
static:  


Parameters:

string   $model   The model

[ Top ]

method getViewClassName [line 450]

string getViewClassName( string $view)

Generates a View Handler class name

Generates a View Handler class name

  1. <?php
  2. // will return Php_View
  3. Framework::getViewClassName("PhP")
  4. ?>




Tags:

return:  View class name
static:  


Parameters:

string   $view   The view handler as set in the configuration file

[ Top ]

method getViewPath [line 463]

string getViewPath( string $view)

Generates a full path to the view handler file

Generates a full path to the view handler file




Tags:

return:  Path to view
static:  


Parameters:

string   $view   The view as set in configuration file

[ Top ]

method pluralize [line 712]

string pluralize( string $word)

Returns the plural version of a string

Returns the plural version of a string




Tags:

static:  


Parameters:

string   $word   A substantive to pluralize

[ Top ]

method redirect [line 594]

void redirect( [string $controller = ""], [string $action = ""])

HTML-Redirects to another URL and ends execution of current code.

HTML-Redirects to another URL and ends execution of current code. If no controller/action is set, will redirect to default values set in config.ini.php




Tags:

static:  


Parameters:

string   $controller  
string   $action  

[ Top ]

method singularize [line 660]

string singularize( $word $word)

Returns the singular version of a string

Returns the singular version of a string




Tags:

return:  The singlular form of the substantive
static:  


Parameters:

$word   $word   string A substantive to singularize

[ Top ]


Documentation generated on Wed, 21 Dec 2005 17:03:00 +0200 by phpDocumentor 1.3.0RC4