{"id":15396,"date":"2026-10-21T14:42:29","date_gmt":"2026-10-21T11:42:29","guid":{"rendered":"https:\/\/creativethemes.com\/blocksy\/?post_type=documentation&#038;p=15396"},"modified":"2026-10-21T14:42:29","modified_gmt":"2026-10-21T11:42:29","slug":"change-languages-header-element-icon-size","status":"publish","type":"documentation","link":"https:\/\/creativethemes.com\/blocksy\/docs\/code-snippets\/change-languages-header-element-icon-size\/","title":{"rendered":"Change Languages Header Element Icon Size"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">The <a href=\"https:\/\/creativethemes.com\/blocksy\/docs\/header-elements\/languages\/\" target=\"_blank\" rel=\"noreferrer noopener\">Languages<\/a> header element lets visitors switch the site&#8217;s language, as long as a compatible multilingual plugin is installed. Each language is shown as a flag, and the snippet below changes the size of those flags.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add the snippet to your child theme&#8217;s <code>functions.php<\/code> file, or use a code snippets plugin such as Code Snippets or WPCode. Change the <code>width<\/code> and <code>height<\/code> values (in pixels) to the size you want.<\/p>\n\n\n<div class=\"ct-code-box wp-block-blocksy-landing-child-code-box\" data-type=\"php\">\n\t<div class=\"ct-code-box__header\">\n\t\t<div class=\"ct-code-box__meta\">\n\t\t\t<span class=\"ct-code-box__label\"><svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><path d=\"m9 8-4 4 4 4\"\/><path d=\"m15 8 4 4-4 4\"\/><\/svg>PHP<\/span>\n\t\t\t\t\t<\/div>\n\t\t<button type=\"button\" class=\"ct-code-box__copy\" aria-label=\"Copy code\">\n\t\t\t<svg class=\"ct-code-box__icon-copy\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><rect x=\"9\" y=\"9\" width=\"11\" height=\"11\" rx=\"2\"\/><path d=\"M5 15V6a2 2 0 0 1 2-2h9\"\/><\/svg>\n\t\t\t<svg class=\"ct-code-box__icon-check\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><path d=\"M5 12.5l4.5 4.5L19 7.5\"\/><\/svg>\n\t\t\t<span class=\"ct-code-box__copy-label\">Copy<\/span>\n\t\t<\/button>\n\t<\/div>\n\t<pre class=\"ct-code-box__code\"><code>add_filter(&#039;blocksy:language-switcher:flag:attr&#039;, function ($attr) {\n\t$attr&#91;&#039;width&#039;] = 22;\n\t$attr&#91;&#039;height&#039;] = 22;\n\n\treturn $attr;\n});<\/code><\/pre>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>The Languages header element lets visitors switch the site&#8217;s language, as long as a compatible multilingual plugin is installed. Each language is shown as a flag, and the snippet below changes the size of those flags. Add the snippet to your child theme&#8217;s functions.php file, or use a code snippets plugin such as Code Snippets [&hellip;]<\/p>\n","protected":false},"author":6,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"_acf_changed":false,"footnotes":""},"doc_categories":[125],"class_list":["post-15396","documentation","type-documentation","status-publish","hentry","doc_categories-code-snippets"],"acf":[],"_links":{"self":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/15396","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation"}],"about":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/types\/documentation"}],"author":[{"embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/comments?post=15396"}],"version-history":[{"count":1,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/15396\/revisions"}],"predecessor-version":[{"id":15397,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/15396\/revisions\/15397"}],"wp:attachment":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/media?parent=15396"}],"wp:term":[{"taxonomy":"doc_categories","embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/doc_categories?post=15396"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}