Websites: what’s involved
The basics
1. What a website is. A website can be as simple as a textfile with "hello" written on. As long as it is located by its own 'root' domain and can be accessed in a web browser, it's a website.
2. Knowing HTML, what it is, how it works, the structure of a web page, 'view source' etc. HTML, sometimes called 'markup', is actually very simple. It doesn't take long to know everything there is to know.
3. CSS (cascading style sheets) is more involved with a longer learning curve. The style sheets for this website have evolved over several years and this will continue.
Every website has at least one style sheet containing rules attached to the HTML about how it should be displayed in web browsers. Web browsers read the HTML and read the style sheets. They also read JavaScript. JavaScript (which I have never been able to grasp) isn't strictly necessary. It is read by web browsers and makes them 'do things' like special effects, slideshows etc that can't be done only with HTML and CSS style sheets. The JavaScript files for this website were copied from 'code repositories' like W3Schools and others. Increasingly, ChatGPT is a good resource. It knows WordPress too.
4. Knowing at least some PHP. PHP is a 'scripting' language that works on web servers. Web browsers don't read PHP, only web servers with PHP installed. Before PHP came along each web page was a separate standalone HTML file you wrote on your computer and unloaded to a web server connected to the world wide web. If your web pages all had a standard 'footer' say, you had to write the HTML for the footer in every HTML file. Using the footer example, PHP lets you write one separate HTML file for the footer and 'include' it in every HTML file. So if you want to change the footer for every page, you have only one file to edit.
PHP really got going from about 2004 and was transformative. WordPress started in about 2005 because of it and is possible only with PHP. Facebook is PHP. Every web designer knows something about PHP. WordPress now contains tens of thousands of PHP files, most of which you don't need to bother with, but there are some files – the ones for your 'Theme' – that you may want to edit so it's important to have a basic grasp of it. The Theme for this website consists of about 10 .php files, all very simple but they must be 'correct', so if you want to change something you must know how to do it. ChatGPT knows PHP.
5. Using images. At present most images on websites are JPEGs – files ending in .jpg. They are measured in pixels, width and height. A JPEG from a mobile phone camera might be several megabytes 4,000 pixels wide, say. This is no use for a website for two main reasons. Firstly it would take far too long for a web browser to download it. Secondly if would have a 'native resolution' much bigger than the space allocated to it on the web page, which might be, say 640 pixels wide. A 4,000 pixel wide image squashed into a space only 640 pixels wide won't look right.
Preferably all images on websites have the same pixel width as the space allocated so they need to be processed first. Of course on a mobile phone screen they will be compressed, from, say, 640 pixels wide to 300 pixels (or whatever, but smaller), but mobile phones are very good at displaying 'squashed' images very clearly.
The point is, using images successfully usually requires them to be carefully processed for web pages and this needs Adobe Photoshop. Typically you set the size, edit the brightness and contrast, edit the saturation and hue, crop it perhaps, then compress it in filesize. Each time a JPEG is compressed for the web, it degrades, so what you do is start with the image as a TIFF file, work on it, then export it in Photoshop as a JPEG. Do not further edit the JPEG, always the TIFF.
Building a modern website tends to be labour-intensive until the website is complete, i.e. all 'set up'. Even then, things move on, requiring 'further attention' from time to time. It requires precision, looking things up, and attention to detail. It's 'the nature of the beast!' It should be enjoyable. If it isn't enjoyable, best to leave it to someone else who does enjoy it because they will probably do it better. That's my experience.
Category: Patrick Category