Hi guys,
you have probably noticed there has not been much new stuff recently. This is because version 5 did not have all the features I originally planned and some of the new stuff in this version affects all the files and blocks so I did not want to release any new stuff before this is finished.
Let me introduce to you a brand new major update – Meteotemplate 6.0 Blueberry!
What is new?
Well… a lot. And most importantly, most of the changes are now done all automatically, so update should be very simple. The update has lot of changes in the backend which you probably will not even notice, but will substantially improve the user experience and speed. This update is especially for YOU – the webmaster – many more options for customization as well as much easier administration!
Here is a brief list of new things:
- setup.php – all template setup (ie. the config) is now done using a graphical user interface! This has many advantages: reduced potential for making errors, much easier editing and direct realtime previews of changes and also very important – for me the possibility to make modifications to config, i.e. changes that affect the template globally – without you having to setup everything again! How this is done is explained in the updated wiki and also in the instructions for update below.
- new mechanism for block updates – there is now a page which will automatically detect your block versions and compare them with the latest ones available by checking at Meteotemplate.com automatically. You will immediately see if there are any new versions for any of your installed blocks. Just install a new block and it will appear here (again, more info below).
- block setup also now done from one global page using graphical user interface
- new interactive banner – although it looks the same, it has several major changes – it no longer uses unreliable and slow Yahoo. Instead, it will use your own station data together with information from the nearest METAR you specify. Also, I have completely replaced the original code for the banner, which used some libraries I found back when I was still just getting to know the first bits of JS and PHP. The new code I wrote is 80% less CPU intensive, most part is done using PHP, not JS, so in the HTML it will be about 75% shorter, and it is much faster and reliable because it no longer relies on Yahoo or WWO.
- this update is also a lot about customization, the new setup allows me to add things to the config and thus change the things in the template as a whole. Here are some newly added features (all setup using live previews and graphical user interface inside setup.php)
- customizable top banner title
- customizable top banner subtitle
- customizable left image in the top banner – choose if you want to automatically use your country flag (just like until now) or specify custom image URL
- customizable page background (one color, custom linear or radial gradients, or custom picture, all with live preview)
- customizable page width
- menu can now be set to either the way it was now, or as “sticky” – will remain on top, once the user starts scrolling down the page
- customizable block borders, border widths, border radius and 3D effect
- optional: all headings with shadows, all body text with shadows
- globally increase/decrease template font size and graphs font size
- “debug mode” – in case something goes wrong you can activate this, which will then help me as a developer in trying to diagnose what is wrong with your template without having to ask you for FTP access or any further changes
- customizable text in the footer – autoinsert date, time, date and time or custom text
- customizable menu slidedown/slideup speed (I have also fixed the bug where the menu closed when you tried to hover over it too fast)
- customizable top banner image – use the interactive banner, or specify URL for your custom image file
- CSS tweaks – the multiple blocks should now align much better and symmetrically, also some minor problems in the “light” theme were corrected
- optimization of all icons and images – the update package is quite large because it contains all the images and icons – but overall they are smaller, so once you replace the original ones, they will take up less space and load faster
Other change include bug fixes – all the ones that were included in the Bug Fixes section
Update instructions
It is probably more important than ever to make a backup of at least your config.php because this update will make changes to this file.
This update package is quite large, the reason for this is that I also optimized all the icons and images, so although you have to download them all, you will then replace them on your server and they will take less space than they did before.
Follow the instructions for updating very carefully!
- First part is to replace particular files that are already on your server with new ones. Begin with the folders, which only contain some files. It is therefore very important that you do not simply delete the original and upload the folder in the update package. The following folders are NOT complete and only the specific files inside them need to be replaced.
- Open the following folders in the update package, one by one, and open the same folders on your server and always add or replace the files, corresponding to the exact same path. For example, in the admin folder, there is a replacement for the original index and there are also new files. What you have to do is replace the index and add the new ones, however there are more files in that folder on your server, those were not changed, are not included in the update package and should be left as they are. So, this procedure should be applied to the following folders in the update package: admin, css, homepage, install, mobile, pages
- Then, the following folders should be replaced completely. in other words, the update package contains some modified and new files, as well as all the other files and so simply delete these folders from your server and completely replace them with the ones in the update package. This is to be done with the folders: icons, imgs and scripts.
- Now replace the header.php and footer.php in your root directory.
- Now for the menu. There are changes in the code of the menu.php that affect its functionality as such. However, the menu items themselves did not change in any way. You have your own customized menu, so DO NOT simply replace the menu, it would reset to default. What you have to do is: open your original menu.php in the template root folder in a text editor (not the built-in windows notepad). Then, copy all the menu items code. This means finding the line: <!– MENU ITEMS –> and copy down everything until you reach the line <!– DO NOT EDIT BELOW –>. Once you copied all that, open the new menu.php and find the exact same lines and paste your own code between those two lines. In other words, copy the menu items from your original menu to the new menu file. Then, save the changes and upload the new menu.php from the update package, the one where you should now also have pasted your own menu items, and replace the original menu.php in the template root folder (note: the mobile menu.php did not change and needs no update).
- What you have to do now is prepare the blocks for the new updating mechanism. This will make your life a lot easier because you will be able to automatically check for new updates, set the blocks using graphical user interface etc. In order to be able to do this, I had to include one extra small text file for each block, which contains the necessary information for these scripts. From now on, all newly released blocks and also the ones already released (the download files at Meteotemplate.com have been updated) will already contain this file. However, your current block files do not have it. To make it easier again, instead of you having to download all the blocks, I have included just these little text files in the update package. There are however a few blocks, which needed more changes and so those are included inside the update package as complete directories.
- So, first step – and this is very important! You must first check that all your blocks that you currently have are in their latest version. To do this, always open the xxxBlock.php file of each block and look at the top, it should have a version number there in the comments section, if there is no version number anywhere, then assume it is version 1.0. Just a little note – due to some CSS changes, I recently uploaded the following two blocks (so you are likely to have the old version): meteogram and interactiveGraph.
- Once you make sure you have the most recent version (by checking at Meteotemplate.com), open the BLOCK FILES folder in the update package. At the top you will see 5 folders, these are the blocks that needed more substantial changes and so must be completely replaced. Then, always take the text file (they all end with …Config.txt) and insert them inside the corresponding directory of each of those blocks. I know this is annoying and time-consuming, but keep in mind that this will make your life a lot easier in the future. The blocks will now be able to automatically check for updates, you will be able to set all the parameters directly from your admin section. BUT! This is very important! The blocks themselves did not really change, so except for meteogram and interactiveGraph, if you leave this for later, the current blocks will work just fine with the new version. The only thing that would be different is that until you copy all the text files, you will not be able to use the block autoupdate and settings features of this new version.
- OK and now you are done. What is next? Next is to set up all the new stuff that can now be customized. Let me explain how. The following text talks more in detail about what is new in this version and especially how to use it.
First let´s talk about the new config setup. Your config can now be fully set up using graphical user interface. This will substantially reduce the number of errors people make and also – very importantly – allow me to easily make changes to the config during version updates and that is very useful because I can make global changes that affect all pages if necessary. This script is the newly added setup.php inside the install directory.
The way this new script works is this:
First the script checks if config already exists. If not, then it means you are a new user and so no password will be required and all fields will be pre-filled with default values. It will automatically try to detect your location, your country, it will try to set the paths automatically for you (assuming you have placed this file correctly in the install directory). You can set everything up and then click the save button and it will create the config. You will also create the password. Also, there is a button in the MySQL section, which will test the MySQL info you provided, so if that fails, there is no point in using it because the template will not work properly. You can directly check that from this file.
If the script detects that config is already created, it will only let you continue if you include this password in the URL – this is probably the case of most of you, so what you have to do is access this file using the following syntax.
In your browser, open:
your template root folder/install/setup.php?password=XXXXX
Replace your templat root folder with your real site URL and replace XXXXX with your admin password you have already set up.
Now what happens is that the script will load all your currently set values. However, there are many new things that can be setup, likewise, I can add new things even in the future versions. So it will show you all the ones you have already set up, and for the new ones, it will prefill default values, but you can change it.
If you are already using Meteotemplate you will find most of the new stuff right at the bottom in a new section for further customization of the template. Just go through it and also always look at the default value to see what the input should look like. There are also live previews for the design, blocks and backgrounds.
Once you are done, click the Save button again. This will overwrite your original config.php and create a new one, copying your old values, but also adding the new ones. If anything fails after this process, overwrite the newly created config.php with the backup copy you created before starting the update and send me an email. I tested it on several servers, but you never know… The only parameter that is discontinued is the bannerID, don’t worry, the reason for that is because the new banner uses the METAR and your own station data – much more reliable, faster and easier. Just make sure you fill in correctly the METAR code in the setup file.
You can now access this setup site any time in the future and make whatever changes you wish.
The other change in this version is the block autoupdate. If you now open your admin section, there will be a new button for blocks setup. If you click that you will get a table. In this table, the template will include all blocks you currently have installed. Note: this is done by scanning the directory, so if you add a new block, you do not need to do anything, just by adding it in the blocks folder, it will automatically appear here as well.
The script will also connect to Meteotemplate.com and get the latest version numbers for each block. It will then show you in that table what version number you have, what is the currently latest version available and if that particular block needs some setting up, there will be a link that will take you directly to a page where you can set up everything and save those changes (ie. no longer necessary to make changes directly in the code). Note: there are a very few blocks which do require changes in the code like before, but that is always included in the information that can be accessed from the blocks set up. So you would always be told that.
Enjoy
Jachym
Congratulations for this new version Jachim .
I am trying to install it.
I’ll test it.
It would be great in the future is that the plugin ‘s and blocks installed in the expected directories are automatically detected by meteotemplate and are embedded in menus without that one must edit menu configuration files for example. Is this possible in a future release ?
Hello and thank you for that version 6 awesome and very easy to do the update
Bonjour et merci pour cette version 6 génial et très facile a faire la mise a jour
Love the new interface!!!! And your instructions were excellent too.