Skip to content Skip to sidebar

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client is attempting to replace the default country flag with a custom icon on their homepage using WPML, but the old flag, specifically the Dutch flag, continues to appear instead of the intended Belgian flag. Despite following initial steps to change the flag, the custom icon only appears on non-home pages.
Solution:
We recommend reviewing the documentation on how to add a custom flag at here. Ensure that you upload the flag in SVG format instead of PNG, as SVG files tend to display more consistently across different pages, including the homepage.

If this solution does not resolve your issue or seems outdated, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If problems persist, please open a new support ticket.

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

Tagged: 

This topic contains 3 replies, has 0 voices.

Last updated by dimitriL-10 11 months, 2 weeks ago.

Assisted by: Bobby.

Author Posts
May 2, 2025 at 3:06 pm #16990119

dimitriL-10

Background of the issue:
I am trying to change the flag to a custom icon on my homepage using WPML. The old symbol, showing the Dutch flag instead of the Belgian flag, is still shown on the homepage.

Symptoms:
Custom flag icon not shown on homepage. The old flag icon is still appearing.

Questions:
How can I change the flag icon to a custom one?
Why is the old flag icon still appearing on the homepage?

May 2, 2025 at 7:54 pm #16990925

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hi Dimitri,

Please review the following documentation on how to add a custom flag.

https://wpml.org/documentation/getting-started-guide/language-setup/language-switcher-options/custom-language-flags/#:~:text=Go%20to%20WPML%20%E2%86%92%20Languages,custom%20language%20to%20your%20site.&text=For%20each%20language%2C%20choose%20to,flag%2C%20then%20click%20Choose%20File.&text=Upload%20your%20flag%20file%20and,flag%20to%20your%20language%20switcher.

Once following these steps you should be able to see the original flag overwritten by the new one.

Let me know your results, please.

May 4, 2025 at 6:10 pm #16993693

dimitriL-10

Hi

apologies if this was unclear in my original request but I have already followed the steps above originally and still get the results as described in my original request in which the custom flag icon is only applied to non-home pages. Could this be a bug?

Br, Dimitri

May 5, 2025 at 5:38 pm #16997699

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Thank you for updating me!

Are you using .png or .svg icons? (from experience .svg tends to work better)

Please go to the following sandbox I created for us and upload the custom flag there so I can further review.

hidden link

May 6, 2025 at 11:09 am #17001129

dimitriL-10

Hi

this was resolved by adding the svg format instead of the png format, thanks for the help!