[phpwebapp-commits] CVS: web_app/doc to_do.txt,1.21,1.22 changes_5.txt,1.1,1.2 changes.txt,1.22,1.23
Brought to you by:
dashohoxha
From: Dashamir H. <das...@us...> - 2005-11-01 13:24:42
|
Update of /cvsroot/phpwebapp/web_app/doc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1556/doc Modified Files: to_do.txt changes_5.txt changes.txt Log Message: i18n and l10n of web_app messages Index: to_do.txt =================================================================== RCS file: /cvsroot/phpwebapp/web_app/doc/to_do.txt,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** to_do.txt 21 Oct 2005 12:17:48 -0000 1.21 --- to_do.txt 1 Nov 2005 13:24:25 -0000 1.22 *************** *** 9,14 **** * - Regenerate the code documentation with doxygen and phpDocumentor. - * - Use the webbox docbook in the documentation of phpWebApp. - * - Write more tutorials for phpWebApp. --- 9,12 ---- *************** *** 17,20 **** --- 15,21 ---- * ------------- Make a new release 1.3 + + + * - Add this functionality to the framework: any webobject can handle an event sent to another webobject, if it defines the Index: changes_5.txt =================================================================== RCS file: /cvsroot/phpwebapp/web_app/doc/changes_5.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** changes_5.txt 31 Aug 2005 07:59:48 -0000 1.1 --- changes_5.txt 1 Nov 2005 13:24:25 -0000 1.2 *************** *** 186,191 **** as an argument of the T_() function and should be surrounded by double quotes, like this: T_("Hello!") . This can be used ! both in the PHP code and in the HTML templates (but not in ! JS files, because they are not processed by the framework). Then, the rest is the same as described by the gettext documentation --- 186,205 ---- as an argument of the T_() function and should be surrounded by double quotes, like this: T_("Hello!") . This can be used ! both in the PHP code and in the HTML templates. ! ! In order to have variables inside a message, you have to make ! some tricks. E.g., to make translatable this message: ! --code ! $msg = "file '$filename' does not exist"; ! print "Error: $msg."; ! ---- ! It can be written like this: ! --code ! $msg = T_("file 'v_filename' does not exist"); ! $msg = str_replace('v_filename', $filename, $msg); ! print "Error: $msg."; ! ---- ! This allows the translator to change the position of the variable, ! if needed. Then, the rest is the same as described by the gettext documentation Index: changes.txt =================================================================== RCS file: /cvsroot/phpwebapp/web_app/doc/changes.txt,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** changes.txt 31 Aug 2005 07:59:48 -0000 1.22 --- changes.txt 1 Nov 2005 13:24:25 -0000 1.23 *************** *** 5,8 **** --- 5,58 ---- ------------------------------------------------------------------- + + The 'docbook' webbox is used just to display the cache (HTML) files + of a DocBookWiki application. It is useful for including a docbook + document in an application. + + It can be included like this: + <include src="{{DOCBOOK_PATH}}docbook.html" /> + where DOCBOOK_PATH is defined by the framework itself. + If you make a local copy of the webbox, then you have + to use the right path. + + It has these state variables which can be initialized or changed + by the application that includes it: + + docbook->cache_path -- the path of the HTML files (usually the + directory 'contents/books/cache/' of the DocBookWiki + docbook->book_id -- the id of the book + docbook->node_path -- the path of the node to be displayed (default './') + docbook->lng -- the language of the book (default 'en') + + The JS function set_node(node_path) can be used by the application + to change the node that is currently displayed. + + If the constant WEBNOTES_ENABLE is defined as 'true', then webnotes + will be appended at the end of each section (but first they must + be installed and configured properly). This constant is set at the + begining of 'docbook.php'. + + ------------------------------------------------------------------- + + The webbox 'webnotes' can be used to append comments or notes + to documentation pages or to other web pages. It can be included + like this: + <include src="{{WEBNOTES_PATH}}webnotes.html" /> + WEBNOTES_PATH is defined by the framework. + + This component uses the database, and, if not already installed + (e.g. by another application), it should be installed like this: + --scr + bash$ cd webnotes/db/ + bash$ mysql -p -u username < webnotes.sql + ---- + The database connection parameters at + 'templates/docbook/view/webnotes/DB.php' need to be modified as well. + + The application or the webbox that includes it should also give a + value to the state variable 'webnotes->page_id', which is used to + select from the database the notes that will be displayed. + + ------------------------------------------------------------------- ------------------------------------------------------------------- ------------------------------------------------------------------- |