This repo contains the website for the short-course, www.infectiousdiseasemodels.org, refactored in January 2023 to make maintenance a bit easier, and with MS-SQL dependencies removed in August 2023.
The website is currently deployed on a Windows server, and runs on vanilla PHP with no significant dependencies.
-
Clone the repo directly into where you would like the page served from. (eg, within an appropriate
htdocsfolder). -
The server will need write/modify access to this folder for the webhooks to work.
-
For the live website, leave the repo on the
mainbranch. -
For the preview website,
git checkout preview. -
With the vaultr package installed, and the environment variables
VAULT_ADDRandVAULT_AUTH_GITHUB_TOKENset, rundeploy.Rin thedatafolder, to create thedb_metadata.php
-
Make changes on the
previewbranch. When you push to that branch, a webhook in this repo will cause those changes to appear on the preview website: https://mrcdata.dide.ic.ac.uk/shortcourse-preview -
When you're happy, make a PR from the latest preview, and merge it, and the live site will be updated.
- Edit the
data/metadata.phpfile. This is (currently) aPHPfile, so lines must end with asemicolon.
- Edit the
data/presenters.jsonfile - a bit fiddly, but perhaps choose a similar person in the list, and copy and paste a section within curly braces, and include the comma after the close-brace unless it is the last entry. The list is sorted by surname. Current conventions:-identifieris unique, containing lower-case letters and underscorestitleis currentlyProfessororDrforenamesin the form['Wes'], or one exception:['Sir', 'Roy']postnominalsfor example['OBE', 'FMedSci']. PhD or lower not included currently.surnameis a simple stringpositionsis a list of the main roles, not necessarily exhaustive.descriptopnhas some short bio written in the third person.photo- links to ajpgsuch asimages/presenters/p_erson.jpg. Current size is 150x200, or proportional to that.pubs- links to the presenter's personal publications page, usually withinhttps://www.imperial.ac.uk/people/.
-
The first file:
timetable_days.csvcontains three fields:-nois the day number in order, starting at 1, including 7 and 8 for the weekend.dayis the three-lettered day nametextis a one-line title, for exampleSunday: Maths and Excel refresher day.
-
The second file:
timetable_slots.csvcontains five fields:-dayis the numerical day, matchingnoin the previous file.slotis a numberical slot number - just an ordering of what happens. The timetable hasn't included times so far, which we could change.classis the type of activity, one ofpractical,break,lunch,qa,lectureorkeynote.nameis the one-line text for the title of the session.presenterare the presenters, Currently comma-separated, in the form"A. Person, B. Person"
The remaining text is included in PHP files at present, as it is not expected to change significantly. Should that change, we'll do some more refactoring to make it easier to edit that text without getting stuck into the code for the website. Get in touch, or file issues on the repo to request changes to how editing occurs, or any other aspect of the site.