About Clonable

Clonable - your cloning & localization tool for website & webshops.

Phone number
+31 492 77 52 69

Business Center Gemert
Scheiweg 26
5421 XL Gemert

Adjusting the country selector

How to: adjusting the country selector

Arranged in a few steps

An example of country selection is the possibility to switch to another country on the website itself or display a flag related to that country. For example, you might want to be able to switch from a Dutch site to a German one, and vice versa. This is usually done by clicking on the flag somewhere on a site and then choosing another country.

These countries, and their order, can be changed by editing a piece of code. Use the inspect option (right mouse button) for the part of the site that deals with the different countries / flags. Copy this piece of code in the left column in Clonable. The piece of code with 'selected' needs to be exchanged, just like above. On the Dutch site, it is with the Dutch flag, but left out in the right column. In the piece of code for the German flag, it is absent and must be added. So you need to fill in two lines in Clonable to complete the switch. Otherwise, 'selected' will remain with both options, and that is of course not the intention.

Besides changing the selected country, it may also be necessary to change the order. For example, on a Dutch site it might make more sense to switch to an English site. Then the UK flag would appear as the second option in the list. But on a Belgian site it would probably make more sense for a French site to be the second option. To change the order of the options, just switch them around in the code snippet.

From 2:21