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

Procedural File: trax.php

Source Location: /trax.php



Page Details:

Create Trax application work area

(PHP 5)




Tags:

filesource:  Source Code for this file
author:  Walt Haas <haas@xmission.com>
version:  $Id$
copyright:  (c) Walter O. Haas 2006
license:  GNU Public License







SOURCE_DIR [line 23]

SOURCE_DIR = "@DATA-DIR@/PHPonTrax/data/"
Define where to find files to copy to the work area

Set automatically by the Pear installer when you install Trax with the pear install command. If you are prevented from using pear install, change "@DATA-DIR@/PHPonTrax" by hand to the full filesystem path of the location where you installed the Trax distribution



[ Top ]




copy_dir [line 95]

boolean copy_dir( string $src_path, string $dst_path)

Copy a directory with all its contents

When a file whose filename ends '.log' is created, its permissions are set to be world writable.




Tags:

return:  true=>success, false=>failure.


Parameters

string   $src_path   Path to source directory
string   $dst_path   Path to destination directory
[ Top ]



copy_file [line 229]

boolean copy_file( string $src_path, string $dst_path)

Copy a Trax file into user's work area, substituting @TRAX-...@



Tags:

return:  true=>success, false=>failure.


Parameters

string   $src_path   Path to source file
string   $dst_path   Path to destination file
[ Top ]



create_dir [line 189]

boolean create_dir( string $dst_dir)

Create a directory if it doesn't exist



Tags:

return:  true=>success, false=>failed


Parameters

string   $dst_dir   Path of directory to create
[ Top ]



trax [line 48]

void trax( )

Symbol substitution tables

$search and $replace below are used to perform substitutions of symbols in a file being copied. $search is an array of Perl-compatible regular expressions, and $replace is a congruent array of replacements for RE matches. So everywhere that the RE in, for example, $search[3] is matched in a file, the matching string is replaced by the contents of $replace[3].




[ Top ]



usage [line 249]

void usage( )

Output a Usage message and exit



[ Top ]



Documentation generated on Thu, 04 May 2006 19:47:55 -0600 by phpDocumentor 1.3.0RC4