Quick links: Content - sections - sub sections
EN

Trace: 1.6 irc 1.4 minitutoriel 1.2 1.7.x 1.0.8 1.3 minitutorial 1.1

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:tutorials:main:creating-application [2007/09/16 06:44] laurenten:tutorials:main:creating-application [2012/04/15 08:30] (current) laurent
Line 1: Line 1:
-====== Creating an application and module ======+We're going to create an application from scratch. Every Jelix application has name : the name of its directory. We will call our application "news.org".
  
-We're going to create an application from scratch. Every Jelix application has a name : the name of its directory. We will call our application "actu.org"+We suppose that you installed the Developer Edition of Jelix as indicated on the [[http://docs.jelix.org/en/manual-1.0/installation/installation|installation]] page, and that you use the default configuration, without modifying the tree strucure. You must have installed PHP and PHP-CLI, as said in the same page, to use the jelix.php script.
- +
-We suppose that you installed the Developer Edition of Jelix as indicated on the [[en:manual:installation|installation]] page, and that you use the default configuration, without modifying the tree strucure. You must have installed PHP and PHP-CLI, as said in the same page, to use the jelix.php script.+
  
  
Line 30: Line 28:
  
 <code bash> <code bash>
-  export JELIX_APP_NAME="actu.org"        # under linux +  export JELIX_APP_NAME="news.org"        # under linux 
-  set JELIX_APP_NAME=actu.org             # under windows+  set JELIX_APP_NAME=news.org             # under windows
 </code> </code>
  
 +
 +Notice that you can execute the script from any directories. For example, you can type:
 +
 +<code bash>
 +  php jelix/path/lib/jelix-scripts/jelix.php --news.org createapp   # under linux
 +  php jelix\path\lib\jelix-scripts\jelix.php --news.org createapp   # under windows
 +</code>
  
  
Line 44: Line 49:
 </code> </code>
  
-You then get a actu.org/ directory, at the same level as the lib/ directory. Its content is :+You then get a news.org/ directory, at the same level as the lib/ directory. Its content is :
  
-  actu.org/+  news.org/
      modules/      the modules owned by your application      modules/      the modules owned by your application
      plugins/      the plugins owned by your application      plugins/      the plugins owned by your application
Line 55: Line 60:
      www/          the root of the site      www/          the root of the site
  
-Check that the temp/actu.org directory, that you juste created has write permissions for the web server.+Check that the temp/actu.org directory you have just createdhas write permissions for the web server.
  
  
 ===== Creation of a module ===== ===== Creation of a module =====
  
-Now that we have a skeleton of application, we will have to create a module, because for the moment, our application can do nothing since there is no defined action. Indeed, we will have to declare and implement some actions. An action can be a page display, backup of a form, a webservice call, etc.+Now we have a skeleton of application, and we will have to create a module, because for the moment, our application can do nothing since there is no defined action. Indeed, we will have to declare and implement some actions. An action can be a page display, backup of a form, a webservice call, etc.
  
-The actions are grouped in distinct modules according to the domainthe fonction to which they are linked. We will for example create a module which will group the actions meant to display and manage the news. To do that, you have the createmodule command, which takes as parameter the name of the module that will be created.+The actions are grouped into distinct modules according to the domain or the fonction to which they are linked. We will for example create a module which will group the actions meant to display and manage the news. To do that, you have the createmodule command, which takes as parameter the name of the module that will be created.
  
 <code bash> <code bash>
Line 70: Line 75:
 By typing this command, Jelix has created for you a module named news with all its tree structure and some mandatory files : By typing this command, Jelix has created for you a module named news with all its tree structure and some mandatory files :
  
-   actu.org/modules/+   news.org/modules/
               news/                the directory of the module               news/                the directory of the module
                 module.xml          file discribing the identity of the module                 module.xml          file discribing the identity of the module
Line 85: Line 90:
 We are now ready to define the actions. We are now ready to define the actions.
  
----- 
-   * Next : [[en:tutorials:main:creating-action|Creating an action]] 
-   * [[en:tutorials:main|Back to the summary]] 

en/tutorials/main/creating-application.1189925056.txt.gz · Last modified: 2007/09/17 22:42 (external edit)

Recent changes RSS feed Creative Commons License