LimeSurvey 2.0 Development Setup
Table of contents
General
This document assumes that you know how to setup your own local web-server for local development.Recommended package for a quick web-server LAMP stack setup is XAMPP
1. Install required PEAR libraries
These libraries are needed for development only. They are not needed for a normal installation of LimeSurvey 2.- Windows: Execute 'pear install mdb2' and 'pear install MDB2_Driver_mysql' from commandline
- Mac: Nothing to do here - you don't need PEAR.
- Linux: Execute 'pear install mdb2' as root from shell
Proxy: If you are using a proxy you have to setup pear accordingly using:
pear config-set http_proxy http://url.to.proxy:port
(e.g. pear config-set http_proxy http://proxy.domain.org:8080)
If the setup was adapted successfully the line config-set succeeded will be shown.
pear config-set http_proxy http://url.to.proxy:port
If the setup was adapted successfully the line config-set succeeded will be shown.
2. Retrieve source code
- Windows:
Use TortoiseSVN
to download https://limesurvey.svn.sourceforge.net/svnroot/limesurvey/source/limesurvey20/limesurvey-dev
to the created ls2 directory.
- Mac & Linux:
Open a console and execute:
svn co https://limesurvey.svn.sourceforge.net/svnroot/limesurvey/source/limesurvey20/limesurvey-dev
~/Sites/ls2/
Change /app/tmp directory permissions:
sudo chmod -R 777 ~/Sites/ls2/app/tmp and ~/Sites/ls2/app/config
Proxy: If you are using a proxy you have to edit ~/.subversion/servers . Find these two variables near the bottom under global settings and uncomment them out replacing with your proxy info
http-proxy-host = yourproxy.yourdomain.com
http-proxy-port = 80 (or what every your port number is)
http-proxy-host = yourproxy.yourdomain.com
http-proxy-port = 80 (or what every your port number is)
3. Install the MySQL GUI tools
- Download and install from http://dev.mysql.com/downloads/gui-tools/5.0.html
- Run the MySQL Administrator GUI tool
- Connect to localhost as root (no password). Under more options, Connect Using Socket need to be: /var/mysql/mysql.sock
- Create a new "Catalog" (database) called 'limesurvey'
4. Run the installer
- Fire up your browser and visit the URL of the previously created LS2 directory. You should be transferred to the installer. Run the installer and fill out all necessary information.
5. Activate debugging mode in CakePHP
- Go to the directory \app\config
- Copy the file debug-core.php.sample to debug-core.php to activate debugging in CakePHP. That way you can see possible errors & warnings (otherwise they are suppressed) and the queries hitting the database
6. Windows: Add the following paths to your system path environment variable
- Path to php.exe
- Path to /ls2/cake/console
7. Use the Firefox browser for development
Firefox has the best plug-ins for serious web-development. Install Firefox 3 and the following plug-ins:- For JavaScript & DOM debugging: Firebug
- For CSS/HTML Live Editing: Web Developer Toolbar
- For W3C validation: HTML Validator
Done! Point your browser at http://localhost/ls2
- + : A leading plus sign indicates that this word must be present in every object returned.
- - : A leading minus sign indicates that this word must not be present in any row returned.
- By default (when neither plus nor minus is specified) the word is optional, but the object that contain it will be rated higher.
- < > : These two operators are used to change a word's contribution to the relevance value that is assigned to a row.
- ( ) : Parentheses are used to group words into subexpressions.
- ~ : A leading tilde acts as a negation operator, causing the word's contribution to the object relevance to be negative. It's useful for marking noise words. An object that contains such a word will be rated lower than others, but will not be excluded altogether, as it would be with the - operator.
- * : An asterisk is the truncation operator. Unlike the other operators, it should be appended to the word, not prepended.
- " : The phrase, that is enclosed in double quotes ", matches only objects that contain this phrase literally, as it was typed.
