I have achieved it from this PHP script and Javascript, but it takes a little while to place in correct position:
# Add an Icon Button
add_action('ava_inside_main_menu', function() {
echo '<li id="menu-item-login" class="noMobile menu-item menu-item-search-dropdown menu-item-avia-special">';
echo '<a href="http://marinapedrena.es/area-privada/" rel="nofollow" aria-hidden="true" data-av_icon="" data-av_iconfont="entypo-fontello"><span class="avia_hidden_link_text">Buscar</span></a>';
echo "</li>";
});
# Place the button on the left side
function change_menu_position() {
?>
<script>
(function($){
$('#menu-item-login').insertBefore($('#menu-item-search'));
})(jQuery);
</script>
<?php
}
add_action('wp_footer', 'change_menu_position');
GIF of the problem:
Hey semarac,
That happens because the page is loaded first before the js script gets executed.
Try to enable/check Page Preloading in Enfold > Theme Options.
Hope this helps.
Best regards,
Nikko
Yes!! It works!
Thanks!!
Hi semarac,
Glad you got it working for you! :)
If you need further assistance please let us know.
Best regards,
Victoria