User:Cpeel/mysqli conversion
This was completed, merged, and deployed to PROD in July 2017.
The DP code has used the mysql PHP extension since its inception in 2000. PHP has since deprecated that extension in preference to the mysqli extension (notice the trailing i). In PHP 7.0 the mysql extension was removed entirely. To support PHP 7.0 we need to change the DP code to use the mysqli extension.
What we're not doing
We're not moving the DP codebase to a new DB abstraction layer. That work is good and necessary, but my objective was to get us to working with PHP 7.0 with as little thrashing as possible. To that end, we did an almost straight replacement from mysql_* to mysqli_* using a singleton class so as to not rely on a global variable for the database connection.
Testing
The conversion of the code has been completed and is ready for testing. Like the User:Cpeel/Remove magic quotes changes, the mysqli changes touch almost every single file of the code. For the most part the change was so straightforward that it was done by a script. Still, it bears some due-diligence to ensure that we didn't break anything in the process.
The code is live on the TEST server at http://www.pgdp.org/c
We need to validate that the site continues to function normally. This includes all aspects of proofing (including WordCheck), project managing (including creating and editing projects and managing word lists), smoothreading, etc.
If you find problems or have questions, please use the #pgdpdev Slack channel to let cpeel know about it, send cpeel a PM, or comment in the testing thread.
Test plan
This is the same test-plan used for the Remove magic quotes work which served us well. After you test an area, put your name next to it to mark that it has been looked at.
(Please note: you can test in any area you'd like even if someone else has signed up for it -- the more eyes the better!)
The following are areas we want to test:
Accounts
- Signing in - cpeel
- Registering & Activating new account - srjfoo
- Project search - FallenArchangel
- Round pages - FallenArchangel
- Using filters with single-quotes in the values - srjfoo
Statistics
- Searching for members - srjfoo
- Searching for teams - srjfoo
- Adding a team - srjfoo
- Editing a team - srjfoo
Preferences
- General - srjfoo
- Proofreading - srjfoo
Proofreading
- Standard Interface - srjfoo
- Enhanced Interface - FallenArchangel
- Wordcheck - FallenArchangel
- Format Preview:
- Standard Interface - jjz, srjfoo
- Enhanced Interface - jjz
Project Management
- Creating project - FallenArchangel, srjfoo
- Editing project information - FallenArchangel, srjfoo
- Editing word lists - FallenArchangel, srjfoo
- Handling bad page - FallenArchangel, srjfoo
- Remote File Manager - FallenArchangel, srjfoo
Smooothreading
- Download a file - srjfoo
- Add comments to file, with and without curly quotes and upload - srjfoo
- Make project available for SR - srjfoo
PP and PPV
- Check out for PP and upload for PPV - lhamilton
- Check out for PPV, generate PPV report - lhamilton
- Change project state - srjfoo
Quizzes
- General (tried all Proofreading/Formatting Quizzes) - lhamilton
Site admin
- Special days
- Add - lhamilton, srjfoo
- Edit - lhamilton, srjfoo
- Site news
- Add - lhamilton
- Edit - lhamilton
- Manage site word lists
- Edit - srjfoo
Misc
- Image sources
- Add - srjfoo
- Edit - srjfoo
- Authors
- Search - srjfoo
- Add - srjfoo
- Edit - srjfoo
- GM Scripts - lhamilton