Wizard’s Toolkit Setup Instructions
The Wizards Toolkit is a combination of PHP, SQL, JavaScript and MaterializeCSS designed to make the development of full-featured data-driven websites and mobile apps fast and maintaining them easy. This repository has the SQL table definitions and initial data, PHP, HTML, CSS and JavaScript. It also includes the documentation that was created via phpDocs and numerous demo files.
Originally written in 2009, this library has been constantly updated. It was known to work with PHP 5.4 and recently was fully tested with PHP 7.4. Currently clients are using it with PHP 8.1.
If you have any questions, contact Alec via this contact form: https://wizardstoolkit.com/wtk/contactUs.php
Table of Contents
Download Options
Both the below methods include all source code for Wizard’s Toolkit. In fact both methods retrieve exactly the same files. The only difference is the Docker method then runs a Docker container so you do not need MAMP or any other configuration.
Both include the SQL files to create all the necessary data tables, scripts to fill the core data, SQL functions and triggers. The SQL is for MySQL but Wizard’s Toolkit should work with any SQL database. If you are interested in using for PostgreSQL or other databases please contact us.
Download via Docker
The fastest way to have a perfectly working version of Wizard’s Toolkit is via Docker. To download, build and run scripts takes less than 2 minutes and you have a completely working Wizard’s Toolkit environment running in an Nginx container with PHP 8.1, MySQL 8.3 and phpMyAdmin.
Setup steps are located at: https://hub.docker.com/r/proglabs/wizards-toolkit.
Download via GIT/BitBucket
Download the latest Wizard’s Toolkit source code from our GIT repository at https://bitbucket.org/AlecSherman/wizards-toolkit/src/main/. This includes docker-compose.yml and instructions so you can create a Docker container this way also.
Setup Steps
Setup for Wizard’s Toolkit is quick and easy. After you have downloaded using one of the above methods, then:
- Access this document locally so you can use links within document to affect/test your local environment
- For example: http://localhost:8888/docs/setup.html
- Create database and run SQL scripts (see below)
- Test Wizard’s Toolkit by going to /devUtils/testWTK.php
- Use ionCube loader-wizard.php to verify ionCube is set up correctly
- Set the password for your admin account by going to: /wtk/passwordReset.php?u=test
SQL Setup
If you are using PostgreSQL with Docker then during initial start PostgreSQL will have automatically run the scripts and set up the database. If you are not using Docker or are using MySQL instead of PostgreSQL, you will need to run the scripts manually.
Manually Running Scripts
In Terminal you can run ./SETUP_MYSQL.sh and this will create database, user, and run all SQL scripts to create tables and insert initial core data.
Or you can manually run all SQL scripts in numeric order. Scripts are located in \SqlSetup\MySQL or \SqlSetup\PostgreSQL folder depending on which database you are using. Of course these should not be uploaded to your production web server.
Note, your login will be admin@email.com unless you changed that when running wtk2InitialData.sql . Because passwords are encrypted and based on salt you set in wtkServerInfo.php, you will need to set your password via going to a web page in your environment. The password will be whatever you set it to be by going to /wtk/passwordReset.php?u=needToSet
If you have any issues or questions please contact us for support.
ionCube Loader Setup
If you use the Docker method then you can skip this because it is all handled automatically.
The ionCube loader wizard was downloaded in February 2024 and is located in your Wizard’s Toolkit environment at /devUtils/ioncube/loader-wizard.php. You can also download the latest version of ionCube loader wizard at https://www.ioncube.com/loaders.php.
This will explain exactly how to install the ionCube loader for your particular web server. Note: when testing on a Mac the ionCube instructions said ioncube_loader_mac_7.2.so but that file did not exist in their zipfile and was actually named ioncube_loader_dar_7.2.so . Following all the instructions but changing 'mac' to 'dar' in the php.ini setting made it work.
In the entire library of over 285 PHP files, 10 JavaScript files, and 11 CSS files, there are only three files encrypted. Two of those are wtk/lib/Encrypt.php and wtk/lib/Save.php which are used primarily to allow for saving data using an encrypted method without the developer having to write a single line of code. This saves developers a huge amount of coding time and is one of the reasons Wizard’s Toolkit is such a fantastic low-code development library. The third file is Browse.php because it contains 1,553 lines of code that turn any SQL query into a dynamic, listing page with sortable columns, column alignment, totalling and many other features.
Note: these three files are encrypted for PHP version 7.4, 8.1 and 8.2. If you are using a different version of PHP, contact us and we will send you the proper files.
Demo Pages
To help your development get a fast start, Wizard’s Toolkit comes with several pages in the /demo/ folder. These include example list pages, edit pages, modal-edit pages, image/pdf display pages both via data or simply in directoreis, PayPal subscription button, file upload and save to data features, and more.
For more information make sure to check out our WTK Wiki.