Administrator Manual¶
Preparation¶
The QFQ extension needs the PHP MySQL native driver. The following functions are used and are only available with the native driver (see also: http://dev.mysql.com/downloads/connector/php-mysqlnd/):
- mysqli::get_result (important),
- mysqli::fetch_all (nice to use)
Installation for Ubuntu:
sudo apt-get install php5-mysqlnd
sudo php5enmod mysqlnd
sudo service apache2 restart
Setup¶
- Install the extension via the Extensionmanager.
- Rename the file <ext_dir>/config.example.ini to <ext_dir>/config.ini and configure the necessary values: <ext_dir>/config.ini
- Play the SQL File <ext_dir>/qfq/sql/formEditor.sql to fill the database with the FormEditor records.
- Configure Typoscript to include Bootstrap, jQuery and QFQ javascript and CSS files.
page.includeCSS {
file1 = typo3conf/ext/qfq/Resources/Public/Css/bootstrap.min.css
file2 = typo3conf/ext/qfq/Resources/Public/Css/bootstrap-theme.min.css
file3 = typo3conf/ext/qfq/Resources/Public/Css/jqx.base.css
file4 = typo3conf/ext/qfq/Resources/Public/Css/jqx.darkblue.css
file5 = typo3conf/ext/qfq/Resources/Public/Css/qfq-bs.css
}
page.includeJS {
file1 = typo3conf/ext/qfq/Resources/Public/JavaScript/jquery.min.js
file2 = typo3conf/ext/qfq/Resources/Public/JavaScript/bootstrap.min.js
file3 = typo3conf/ext/qfq/Resources/Public/JavaScript/validator.min.js
file4 = typo3conf/ext/qfq/Resources/Public/JavaScript/jqx-all.js
file5 = typo3conf/ext/qfq/Resources/Public/JavaScript/EventEmitter.min.js
file6 = typo3conf/ext/qfq/Resources/Public/JavaScript/qfq.debug.js
}
FormEditor¶
Setup a report to manage all forms: Create a Typo3 page and insert a content record of type qfq. In the bodytext insert the following code:
form = {{form}}
10 {
sql = SELECT CONCAT('{{pageId}}&form=Form&r=', f.id) as Pagee, f.id, f.name, f.title, f.tableName FROM FormEditor As f ORDER BY f.name
head = <br><table class="table">
tail = </table>
rbeg = <tr class="table-hover">
rend = </tr>
fbeg = <td>
fend = </td>
}
<ext_dir>/config.ini¶
Keyword | Example | Description |
---|---|---|
DB_USER | DB_USER=qfqUser | Credentials configured in MySQL |
DB_PASSWORD | DB_PASSWORD=12345678 | Credentials configured in MySQL |
DB_SERVER | DB_SERVER=localhost | Hostname of MySQL Server |
DB_NAME | DB_NAME=qfq_db | Database name |
DB_NAME_TEST | DB_NAME_TEST=qfq_db_test | Used during development of QFQ |
DB_INIT | DB_INIT=set names utf8 | Global init for using the database. |
SQL_LOG | SQL_LOG=sql.log | Filename to log SQL commands: relative to <ext_dir> or absolute. |
SQL_LOG_MODE | SQL_LOG_MODE=modify | all: every statement will be logged - this is a lot modify: log only statements who change data |
SHOW_DEBUG_INFO | SHOW_DEBUG_INFO=auto | Possible values: auto|yes|no. For ‘auto’: If a BE User is logged in, debug information will be shown on the fronend. |
CSS_LINK_CLASS_INTERNAL | CSS_LINK_CLASS_INTERNAL=internal | CSS class name of links which points to internal tagets |
CSS_LINK_CLASS_EXTERNAL | CSS_LINK_CLASS_EXTERNAL=external | CSS class name of links which points to internal tagets |
DATE_FORMAT | DATE_FORMAT= yyyy-mm-dd | Possible options: yyyy-mm-dd, dd.mm.yyyy |
Example: <ext_dir>/config.ini
DB_USER = qfqUser
DB_SERVER = localhost
DB_PASSWORD = 12345678
DB_NAME = qfq_db
DB_NAME_TEST = qfq_db_test
DB_INIT = set names utf8
SQL_LOG = sql.log
SHOW_DEBUG_INFO = auto
CSS_LINK_CLASS_INTERNAL = internal
CSS_LINK_CLASS_EXT = external