Changeset 629

Show
Ignore:
Timestamp:
05/06/07 04:59:58 (6 years ago)
Author:
lmajano
Message:

Ticket #142
Modified Application Template.

Location:
coldbox/trunk/ApplicationTemplate
Files:
1 added
3 modified

Legend:

Unmodified
Added
Removed
  • coldbox/trunk/ApplicationTemplate/build.xml

    r515 r629  
    99                 
    1010     The task will generate a new application template for you in a  
    11      directory named GENERATEDAPP. You can change the name of the generated 
    12      folder if you want below. 
     11     directory of your choice, full path. 
    1312     ====================================================================== --> 
    1413<project name="coldbox.newapplication" default="generate" basedir=".">   
    1514        <!--Properties--> 
    16         <property name="destination"            value="GENERATEDAPP" /> 
    1715        <property name="src.dir"                        value="." /> 
    1816     
     
    2321                <input message="What is the name of your application: (Ex:blog,forum)?" 
    2422                       addproperty="app.name"/> 
     23                <input message="What is the destination directory: (Ex:/data/webroot)?"  
     24                       addproperty="destination" /> 
    2525        </target> 
    2626 
     
    5959                        <replacetoken>Your App Name here</replacetoken> 
    6060                </replace> 
     61                <!--Replace AppName in eclipse project --> 
     62                <replace file="${destination}/${app.name}/.project" value="${app.name}" summary="yes"> 
     63                        <replacetoken>@appname@</replacetoken> 
     64                </replace> 
    6165                <!--Delete Header File--> 
    6266                <delete file="header.txt" /> 
  • coldbox/trunk/ApplicationTemplate/config/config.xml.cfm

    r569 r629  
    88                <Setting name="DebugMode"                                       value="true" /> 
    99                <!--The Debug Password to use in order to activate/deactivate debugmode,activated by url actions --> 
    10                 <Setting name="DebugPassword"                           value="Coldbox"/> 
     10                <Setting name="DebugPassword"                           value=""/> 
    1111                <!--The fwreinit password to use in order to reinitialize the framework and application.Optional, else leave blank --> 
    1212                <Setting name="ReinitPassword"                          value=""/> 
     
    2222                <Setting name="DefaultEvent"                            value="ehGeneral.dspHello"/> 
    2323                <!--Event Handler to run on the start of a request, leave blank if not used. Emulates the Application.cfc onRequestStart method --> 
    24                 <Setting name="RequestStartHandler"             value=""/> 
     24                <Setting name="RequestStartHandler"             value="ehMain.onRequestStart"/> 
    2525                <!--Event Handler to run at end of all requests, leave blank if not used. Emulates the Application.cfc onRequestEnd method--> 
    26                 <Setting name="RequestEndHandler"                       value=""/> 
     26                <Setting name="RequestEndHandler"                       value="ehMain.onRequestEnd"/> 
    2727                <!--Event Handler to run at the start of an application, leave blank if not used. Emulates the Application.cfc onApplicationStart method        --> 
    28                 <Setting name="ApplicationStartHandler"         value=""/> 
     28                <Setting name="ApplicationStartHandler"         value="ehMain.onAppInit"/> 
    2929                <!--The Email address from which all outgoing framework emails will be sent. --> 
    3030                <Setting name="OwnerEmail"                                      value="myemail@gmail.com" /> 
     
    3636                <Setting name="ExceptionHandler"                        value="" /> 
    3737                <!--What event to fire when an invalid event is detected--> 
    38                 <Setting name="onInvalidEvent"                          value="ehGeneral.dspHello" /> 
     38                <Setting name="onInvalidEvent"                          value="" /> 
    3939                <!--Full path from the application's root to your custom error page, else leave blank. --> 
    4040                <Setting name="CustomErrorTemplate"                     value="" /> 
  • coldbox/trunk/ApplicationTemplate/handlers/ehGeneral.cfc

    r500 r629  
    33Date     :      September 25, 2005 
    44Description :                    
    5         This is a ColdBox event handler. 
     5        This is a ColdBox event handler for general methods. 
    66 
    77Please note that the extends needs to point to the eventhandler.cfc 
     
    1010         
    1111-----------------------------------------------------------------------> 
    12 <cfcomponent name="ehGeneral" extends="coldbox.system.eventhandler"> 
     12<cfcomponent name="ehGeneral" extends="coldbox.system.eventhandler" output="false"> 
    1313         
    1414        <!--- This init format is mandatory if you are writing init code else is optional,  
     
    2121        </cffunction> 
    2222        ---> 
    23          
    24         <cffunction name="onAppInit" access="public" returntype="void" output="false"> 
    25                 <cfargument name="Event" type="coldbox.system.beans.requestContext"> 
    26                 <!--- ON Application Start Here ---> 
    27         </cffunction> 
    28          
    29         <cffunction name="onRequestStart" access="public" returntype="void" output="false"> 
    30                 <cfargument name="Event" type="coldbox.system.beans.requestContext"> 
    31                 <!--- On Request Start Code Here ---> 
    32         </cffunction> 
    33          
    34         <cffunction name="onRequestEnd" access="public" returntype="void" output="false"> 
    35                 <cfargument name="Event" type="coldbox.system.beans.requestContext"> 
    36                 <!--- ON Request End Here ---> 
    37         </cffunction> 
    38          
    39         <cffunction name="onException" access="public" returntype="void" output="false"> 
    40                 <cfargument name="Event" type="coldbox.system.beans.requestContext"> 
    41                 <!--- ON Exception Here ---> 
    42         </cffunction> 
    43          
     23 
    4424        <cffunction name="dspHello" access="public" returntype="void" output="false"> 
    4525                <cfargument name="Event" type="coldbox.system.beans.requestContext">