Hiking in Switzerland

Hiking in Switzerland

In 2019 Swiss people spent 162 million hours walking and hiking in Switzerland. Hiking generates 2.5 billion CHF per year and there are 50,000 signs to help people find their way. In Switzerland people hike 20 times per year.


I go for a two to three hour walk/hike every single day and as a result I have walked almost 2 million steps since March.


The Canton de Vaud has 3736 kilometres of hiking trails of which 1538 have hard surfaces. 547 kilometres are in the mountains. 136 volunteers help keep the paths open.


The total number of hiking trails in Switzerland amount to 66,722 kilometres, of which 17444 have hard surfaces. 24,783 kilometres are in the mountains. For 2019 there were 1028 organised hikes by Randonner.ch. These facts and figures are from the 2019 annual report.


Walking from Village to Village, and Village to Town
| | | |

Walking from Village to Village, and Village to Town

The conversation is too often about designing cities to be car-free, but I would argue that designing the countryside to require less frequently would be more advantageous. The reason for this is that walking from village to village, and from villages to towns eliminates the need for, and appeal of the car. If the need for a car is mooted by making the sides of roads pleasant for pedestrians and cyclists, we reduce the allure of the car.


From March to June I walked around one million eight hundred and fifty thousand steps between villages according to the pedometer++ app. In that time I have walked through rain, wind, mud, and streams. In the process, I have come to the conclusion that the grass on the sides of roads needs to be cut more frequently.


When the grass at the side of the road is not cut we are forced to walk through increasingly longer grass from week to week. On a dry day this doesn’t matter so much but on a rainy it does. On a rainy day if the grass is cut regularly you’d get wet from the rain over a period of time.


When the grass is long you get soaked within a few steps. Rainwater goes from the grass, to your shoes, and onto your trousers, and other time it works its way down to the soles of your feet and up your trousers, through to your t-shirt and beyond. By the end of a walk you’re drenched through.


If the grass had been cut you’d be wet, but it would take longer. If you’ve been drenched from walking through long grass frequently enough the idea of getting soaked yet again encourages you to walk on the side of the road, rather than the grass bank. This affects traffic fluidity because a pedestrian on the road has to be avoided. If they’re in the grass then the problem is resolved.


When I drive along narrow roads and I see pedestrians or cyclists I slow down to the speed at which I would like to be passed, if I was the one walking. This is also true of cyclists. Drivers seldom understand the effect that their speed and proximity has on vulnerable road users.


When you’re walking between villages you sometimes have to walk on the road because hedges and other vegetation make it impossible to walk off of the road. In some cases, when walking at the side of the road I have come across thorny plants. Walking into them, without knowing that they were thorny is a one time mistake. After that you walk on the road.


We could walk along agricultural roads but there are two issues with agricultural roads. The first is that people drive cars down them at speed so it’s no better than walking by the side of the road, but the second is people with dogs.


When you’re afraid of dogs it’s more interesting to walk in the grass by the side of the road than agricultural roads.


I should add some context. I walk along the sides of roads, rather than agricultural paths because I like to walk for two to three hours at a time. To walk for two to three hours I need at least ten to fifteen kilometres of paths and routes to walk along. I could get in a car, drive for an hour or two and walk in the mountains, but over the last two years I have found that I can get the same workout without the use of the car.


I have found that there are plenty of nice things to see, without burning fossil fuels.


The reason for which people do not walk or cycle between villages, and from villages to towns, is that they see roads as dangerous. Drivers too often, see pedestrians and cyclists, as a nuisance. If the grass at the side of the road was kept short enough for pedestrian trails to form and be used, then the need for cars would be reduced. If the need for cars between towns and villages is reduced, so is the need within towns. Urban planners, before removing cars from towns, should think about getting people into the habit of walking between villages and towns. If you get people out of that habit, then it is easier to get them into the habit of catching the train.

|

FaceBook’s Primitive Content Management System

Facebook’s Primitive Content Management System, because aside from being a social media platform, it is a CMS, makes it very hard to delete posts, images, and more in bulk. Facebook should be seen as a CMS because it allows us to share images, posts, events, and more.


As a CMS we should have more control over how we handle our data on Facebook, Twitter and other social networks. Privacy settings that are not bulk editable retro-actively, are not of much use because no one will spend days or weeks tidying up their timelines.


With a CMS like Wordpress you can go to See all posts, choose “show two hundred posts” and you can delete 200 posts at a time. This means that, if for any reason you decide to tidy up old content, you can do so within a short period of time.


With Facebook, you have three choices. Choice one is to go and manually delete thousands of posts and spend several days doing so. The second option is simply to delete your old Facebook account and start from scratch and the third option is simply to dump Facebook entirely.


Facebook should offer users the option to curate their content quickly and efficiently. It currently has a monopoly because it is the primary social network that people use to share events, participate in group discussions and more.


As with real life we have good days and we have bad days. It should be possible to delete multiple posts at once. With spam comments we can “Empty spam” both in e-mail applications and WordPress comment sections.


Every e-mail client allows us to delete multiple messages at once. Inbox Zero and other concepts rely on this.


With MySQL we can drop the post table in less than a second. We should have such functionality on Facebook, Instagram and other social networks. Without this functionality we are limited in who we can accept as friends. We can only accept people whom we know and trust not to form prejudiced opinions based on what we wrote on a bad day.


If the only way to set the clock back to zero on Facebook and Twitter is to delete our accounts then we are encouraged to dump social networks altogether.


In the age of GDPR and other privacy-protecting measures these options should be available to users. We should also have an option to say “If user=”new” show “only posts from the day we became friends on Facebook””.


How to Migrate from Instagram To WordPress

How to Migrate from Instagram To WordPress

Recently I migrated my photos from Instagram to a WordPress blog. The process took some trial and error. The first step is to understand how to read JSON files and format them in a way that WordPress can use. The next step is to import that data into Wordpress.


To request your data follow this link, request the data and wait for an e-mail telling you that the files are ready to download. When the files are ready to download download them and unzip the files.


Convert from JSON to CSV


You will find photo directories listed by year and month. You will also get a few JSON files but the ones you want are the media.json files. With a tool like the Konbert app you can convert the files from JSON to CSV files. When the CSV file or files are ready open them in Google Sheets or other spreadsheet software and look at the columns.


The fields you will find are


  • Caption
  • Taken At
  • Location
  • Path
  • Stories
  • Videos
  • Photos


Although not essential you can add fields like author. If you see “stories” and “videos” remove these columns. The CSV importer plugin I used cannot import videos and stories automatically.


When this is done you should have a CSV file that has caption, taken at, location, and path. Keep the photo file structure as it is.


Installing WordPress Locally


The simplest Wordpress installation I found is Local. Within minutes you can have a wordpress blog setup and running on your local machine. The reason you want a local install is that JSON to CSV conversions can be messy so if you make a mistake it is easy to reset and start again.


It took several attempts before I managed to import all the images and get them to display properly. If I had imported those files to my production Wordpress Blog I would have spent hours deleting thousands of posts more than once.


Folder Structure


When you import your images to WordPress with the CSV importer tool you have the option of leaving them where they are or of importing them into the uploads/year/month folder structure. Be warned that if you let the importer tool import the images itself it will import all of the images and generate thumbnails. If you have 3900 images you will end up with 12,000 images in a single folder as thumbnails are generated.


I would recommend:


  • creating a folder for every year that you were on Instagram
  • renaming every Instagram folder from /yearmonth/ to month, for example from 202006 to /06/ in the 2020 folder.
  • placing each month in the appropriate year/month folder in uploads.


Preparing the CSV file.


For the next step, I would recommend saving a copy of the document as it is so that you can go back to it if you make a mistake.


If you have changed all of the yearmonth folders to a year/month/ folder structure then you can use find and replace to update the folder names. You can find and replace 202006 with 2020/06 and work recursively. This will take more time, but be tidier. The CSV importer tool does not keep imports tidy. If I had known this ahead of time I would have taken this additional step.


In the CSV file the path is relative. To be tidy I put the photo folders in /wp-content/uploads/photos/ and had to update the CSV document to reflect that. Although you can find and replace in Google Sheets I used Visual Studio code for the next step.


Originally the path will be something like photos/202006/filename.jpg. but as the images are in wp-content/uploads/photos WordPress will look in the wrong place. With Find and Replace I selected “/photos/” and replaced it with “http://localhost:10003/wp-content/uploads/photos/”. At this point, the CSV files were ready to be imported.


Import CSV to WordPress


Although I tried a few tools the one I settled on is WP Ultimate CSV Importer.


The fields you will get when importing the CSV file.


If the CSV file is prepared correctly you should see Caption, Taken at, Location and Path. When I imported I mapped it so that so that Title and Content and slug would be the caption and for slug to be the caption. I then mapped Taken On to Publish date and featured image to the image path.


Select “Use media images if already available and “download post content external images to media


If you have kept the image folders as they were when you unzipped the Instagram download then select “Use media images if already available” and “download post content external images to media.” The images will be copied from the photos folder into the correct folder for WordPress to use.


If you have already organised your images by year and month in the uploads folder then you do not need to check “download external images to your media as they are already there.


The Final Step


The Final Step is to find a theme that reflects how you. want your images to be displayed and share the new location of your photo library to your various social media profiles and networks.


As a final step if you find that an image does not load for single posts you can add this line of code after the PHP tag.


if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
the_post_thumbnail( 'full' );
}


This is a lot faster than going through 3900 posts and adding an image to each individual post.


Conclusion


If everything works as expected you can now export a CSV file of your test blog and upload it and the appropriate files to your online photo blog.

Playing With Grasshopper

Playing With Grasshopper

Grasshopper is a Google app to teach adults and children about Javascript. It provides people with short, easy to understand modules to get a grasshopper to do things.


The curriculum is divided into seven modules. These are:


  • Fundamentals
  • Fundamentals II
  • Intro to Interviewing
  • Array Methods
  • Animations
  • Animations II
  • Using a Code Editor
  • Intro To Webpages


So far I have only played with part of the fundamentals course. You don’t need to write much code. You can select which function and variable you want to use, rather than typing lines and lines of code.


This is the type of app that you can use almost anywhere, and anytime you have a few minutes free.


One of the challenges, when you want to learn a new programming language, is to set up an environment before you start playing with code. That can be a long process and it’s easy to lose interest before you have even written two lines of code.


With such a simple app you don’t need to set anything up. You can play with code, see what it does, and then try something more complex. You can familiarise yourself with the language before you install a development environment on the machine you use.


An example of Grasshopper on a desktop.


As soon as the app is installed on your phone you start learning.


The Fun and Games of Attempting to Migrate Instagram Data continue

The Fun and Games of Attempting to Migrate Instagram Data continue

The Fun and games of attempting to migrate Instagram data continue. I have now spent several days on the task. I have my Instagram posts currently sitting on a local blog. The challenge has been to migrate it from my local WordPress installation to the main website.


After dozens of failed attempts the SQL database, seperate from this blog’s database was getting filled with lines of data. I was up to over 31,000 pieces of data or more. I didn’t check the term a plugin uses.


From my experience of playing with JSON files they are dealt with differently by each app you use to convert them, so what works in one instance, fails in another. This is true of JSON to XML and JSON to CVS conversion.


I went to PHPMyAdmin and purged two tables and now I’m back to having a blank slate. I cleared both the media and the post tables. I also emptied the uploads folder. I feel optimistic that my next attempt will be successful.

Close to Success – Exporting Instagram images to WordPress Natively
| |

Close to Success – Exporting Instagram images to WordPress Natively

When Instagram was a self-run startup I loved the product. I loved that it was a way of sharing images with friends. I loved that it was fast and that it was light. I also liked that it had it’s own community. I liked that it was a way of sharing real life with people we conversed with online.


When Facebook bought Instagram that slowly changed. Algorithms and popularity contests became more important than sharing between friends and so the sense of community was lost and we were posting for strangers rather than friends.


For months, or even a number of seasons now, I have felt that Instagram is just a way of forcing us to see images by people we are not that interested in, with the hope that we will eventually see images that are relevant to us. That time investment we make is devalued when you consider that the Facebook behemoth is making millions from our mindless scrolling.


During the pandemic my patience for social media finally fizzled out and I’ve been playing with my website. By playing I mean, experimenting, learning, and developing and trying new ideas.


One of those ideas was to export my Instagram account and find a way to flip it over to Wordpress. Why Wordpress, rather than another social network? WordPress is an open-source social network that we control. We control advertising, we control posting frequency, we control layout, and best of all, there is no group of investors holding our… …I’ll leave that to your creative imagination, over the fire.


I tried finding tools to import from JSON to WordPress but in one case I needed to install wp-cli and that was complicated, and I wasn’t confident that it would be tolerated by the web host. I could have asked but instead, I set myself the challenge of installing MySQL on the laptop and running the localhost for experimenting. I failed to connect my localhost WordPress install with MySQL and eventually after two days of trial and error I decided to take a break and try something easier. I tried XAMPP but then I found what looked like a simpler tool, with WP-CLI integrated.


I settled on LocalWP. With this, I tried the GitHub project I thought would help me import the JSON files but that failed so I looked for another solution and it got me 90 percent of the way to achieving what I wanted to achieve. When I confirm that this process works I will post a How-To guide.