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

Procedural File: vcl.inc.php

Source Location: /vcl.inc.php



Page Details:

This file is part of the VCL for PHP project

Copyright (c) 2004-2008 qadram software S.L. <support@qadram.com>

Checkout AUTHORS file for more information on the developers

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA




Includes:

require_once("acl.inc.php") [line 40]





VCL_FS_PATH [line 66]

VCL_FS_PATH = $fs_path
Filesystem path to the VCL


[ Top ]



VCL_HTTP_PATH [line 72]

VCL_HTTP_PATH = $http_path
Webserver path to the VCL


[ Top ]



VCL_VERSION [line 38]

VCL_VERSION = VCL_VERSION_MAJOR.'.'.VCL_VERSION_MINOR
Version of the VCL, use this define to make work your components between VCL versions


[ Top ]



VCL_VERSION_MAJOR [line 29]

VCL_VERSION_MAJOR = 2
Major version of the VCL


[ Top ]



VCL_VERSION_MINOR [line 33]

VCL_VERSION_MINOR = 0
Minor version of the VCL


[ Top ]




register_startup_function [line 178]

void register_startup_function( string $function)

Registers a function to be called just before the session is started by Application

This function can be used to perform any processing that must be done before start the session. It can be useful to integrate packages like Zend framework, which doesn't allow a session to be registered before.

It doesn't perform any check to know if your function has been already registered, so be sure you call it only once, or your function will be called multiple times.

  1.  <?php
  2.     function MyStartup()
  3.     {
  4.          //My custom session start
  5.          session_start();
  6.     }
  7.     register_startup_function("MyStartup");
  8.  ?>




Parameters

string   $function   Name of the function to be called
[ Top ]



relativePath [line 85]

string relativePath( string $path, string $root, [string $separator = '/'])

Returns a relative path

This function calculates the relative path of an input path to allow you point to the right one even if you move scripts. This is for internal VCL for PHP use




Tags:

return:  Relative path


Parameters

string   $path   Base path
string   $root   Path to adapt
string   $separator   Separator to be used
[ Top ]



use_unit [line 141]

void use_unit( string $path)

Includes an VCL unit

This function uses the VCL for PHP path to include a unit that resides on the VCL folder, so you don't have to worry about VCL for PHP library location if you use this function. Included units are included require_once so you will get an error if required units doesn't exists and double inclusions won't be performed.

  1.  <?php
  2.     use_unit("controls.inc.php");
  3.     use_unit("subpath/myfunctions.inc.php");
  4.  ?>




Tags:



Parameters

string   $path   Relative to VCL root path
[ Top ]



Documentation generated on Sat, 13 Jun 2009 10:52:13 -0700 by phpDocumentor 1.4.1