Scott Cottam

scott@scottcottam.co.uk

Laravel

4th May, 2019
This is the first post on this newly revamped and more database driven website, my original intention was to create a static website to host my portfolio and my projects but as time went on I decided it would be best to make it database driven so in future I don’t need to edit HTML even if it did mean putting the hard work in and creating all the systems necessary to do that. The first iteration of this site was created in December 2017 using vanilla PHP with no form of templating system and the only dynamic part was the Portfolio page, that was generated using a hand written JSON file to populate the websites I had previously worked on. Later on during my time learning the Laravel framework around August last year, I decided it woul...
Read More
5th May, 2019
I, probably like a lot of people use cheap shared hosting to host my sites, its no fuss and its cheap but every so often you run into the limitations of shared hosting. my current hosting provider is Dreamhost, Now with Laravel when you upload a file it stores it in 'storage/app/public' as opposed to 'public' which is used to store all public files, you get around this by creating a symlink using Laravel's Artisan Console via a shell console. The problem is with Dreamhost even though it does provide shell access and the latest versions of PHP for the hosted sites the shell however seems to run PHP 5.6 of which Artisan is incompatible with, it errors out when you try to run Artisan commands, however Dreamhost does provide a guide to instal...
Read More
15th August, 2019
Over the last month or so I’ve been working on a project using the Symfony framework as it is sort of the basis for Laravel, apart from a few moments of pulling my hair out but that is mainly getting used to the database side of the framework as it uses Doctrine, I have really grown to like Symfony over Laravel as it feels a lot less bulky. But this post really isn’t to discuss the merits of Symfony vs Laravel, it is however to talk about the caching Symfony does for its Twig templates as well as the Doctrine database queries, the caching does over all reduce system loads when sites built with Symfony are loaded and reloaded by its users. In the dev environment changes to Twig templates and Doctrine queries aren’t cached quite as aggres...
Read More
1st June, 2021
I really am bad at updating this blog, aren't I? Personal Updates I have completed my foundation degree at Blackpool and The Fylde College and awaiting my final results, so far my grades are looking good and I'm hoping I come away with a distinction, I have started applying for jobs again but there seems to be a lot of competition for roles and I'm hoping I'll be able to eventually pull an interview at least and as of last week I have received my first Pfizer jab. Website Updates With some free time on my hands I've put some time into tweaking this website and fixing the issues I had put off for over a year, firstly the CSS has had a minor refresh with a new font, minor text highlighting animations and a revamp of the navigation eff...
Read More
18th June, 2021
I have to admit uploading an image directly the public directory using Laravel stumped me for longer than I would have liked as the Laravel documentation isn’t exactly forthcoming for a scenario in which this would be required. For the uninformed the Laravel documentation would much prefer you to upload files into the Storage directory and create a symlink between the files within the Storage directory and the Public directory, this symlink is created using the Artisan command line interface, this method works great within the development environment of Homestead and any hosting that allows you to have complete access to shell interface, however on shared hosting this may not always be the case.  There are workarounds for this however a...
Read More