Tagged: WPML Plugin
-
AuthorPosts
-
April 29, 2021 at 9:02 pm #1297410
Can someone explain to me how to add images to my secondary navigation. I want to add flags to the secondary navigation on the right
English EspañolApril 30, 2021 at 12:58 pm #1297547Hi merrywatson,
It is automatically added once you are using WPML for translation.
Please check the following:
– Documentation: https://kriesi.at/documentation/enfold/translation/
– Video: https://www.youtube.com/watch?v=fHwjObRRhN0Best regards,
NikkoMay 2, 2021 at 9:58 pm #1297816Do I need to purchase WPML plugin?
May 3, 2021 at 5:04 am #1297840Hi merrywatson,
No, but you’ll need to use a child theme, you can download and find instructions in our documentation: https://kriesi.at/documentation/enfold/child-theme/
Then in functions.php of the child theme, add this code:function add_flags_to_header() { $output = "<ul class='custom_flags noLightbox social_bookmarks icon_count_2'>"; $output .= "<li><a href='ENGLISH_URL'>"; $output .= " <span class='language_flag'><img title='English' src='ENGLISH_FLAG_IMAGE_URL' alt='English' /></span>"; $output .= "</a></li>"; $output .= "<li><a href='ESPANOL_URL'>"; $output .= " <span class='language_flag'><img title='Español' src='ENGLISH_FLAG_IMAGE_URL' alt='Español' /></span>"; $output .= "</a></li>"; $output .= "</ul>"; echo $output; } add_action( 'ava_inside_main_menu', 'add_flags_to_header', 10 );
just replace the following in the code:
– ENGLISH_URL with the link in private content
– ESPANOL_URL with the link in private content
– ENGLISH_FLAG_IMAGE_URL (you’ll need to find an image of the flag, then upload it to Media Library and copy the URL and replace this one)
– ESPANOL_FLAG_IMAGE_URL (same with ENGLISH_FLAG_IMAGE_URL)Then add this CSS code in Enfold > General Styling > Quick CSS:
#top .custom_flags { padding-right: 20px; }
Hope it helps.
Best regards,
NikkoMay 4, 2021 at 6:50 pm #1298364I added the code on my staging site https://qgk.aff.myftpupload.com/ I added the code in the Private Content section
I don’t see the flags.- This reply was modified 3 years, 6 months ago by Yigit. Reason: Fixed HTML
May 4, 2021 at 10:58 pm #1298378Hi merrywatson,
Please post us your login credentials (in the “private data” field), so we can take a look at your backend.
- Install and activate ” Temporary Login Without Password “.
- Go to ” Users > Temporary Logins ” on the left-side menu.
- Click ” Create New “.
- Add the email address for the account ( you can use (Email address hidden if logged out) ), as well as the ” Role ” making that the highest possible and the expiry about four days
( to be sure that we have enough time to debug ). - Click ” Submit “.
- You’ll now have a temporary account. Please provide us here in the private section the URL, so we can login and help you out.
When your issue is fixed, you can always remove the plugin!
If you prefer to not use the plugin, you can manually create an admin user and post the login credentials in the “private data” field.Best regards,
NikkoMay 4, 2021 at 11:47 pm #1298385I added you as a user, using the email (Email address hidden if logged out) .
This is on my staging site https://qgk.aff.myftpupload.com/
If you do not receive the login credentials please let me know.May 5, 2021 at 8:10 am #1298453Hi merrywatson,
I did not receive it.
Please post it here in private content, so any moderator can check it. :)Best regards,
NikkoMay 5, 2021 at 2:48 pm #1298583Here you go, I put my login in the private content.
May 5, 2021 at 2:49 pm #1298586this is the website URL below in the private content
May 7, 2021 at 3:54 pm #1298982Hi merrywatson,
Thanks for giving us admin access.
This is now showing properly, please review your site.The greater than and lesser than symbols were replaced with & g t ; and & l t ; (I just replaced it with the correct symbols)
Then I have replaced this code:add_action( 'ava_inside_secondary_menu', 'add_flags_to_header', 10 );
with:
add_action( 'avia_meta_header', 'add_flags_to_header', 10 );
Then to fix the alignment and adjust the flag size, I added this code in QUick CSS:
#top .custom_flags { margin-top: -7px !important; } #top .custom_flags img { max-height: 16px; }
Best regards,
NikkoMay 7, 2021 at 4:16 pm #1298986Thank you for this. One question when I go to the Spanish page in the secondary nav the flags are not there.
Do I need to add additional code?
May 7, 2021 at 4:23 pm #1298990Hi merrywatson,
That’s because it’s a different domain, we have applied it here: https://qgk.aff.myftpupload.com/espanol/
You’ll just need to do the same steps we did in https://qgk.aff.myftpupload.com/espanol/ for this domain: https://pimasters.com/espanol/Best regards,
NikkoMay 7, 2021 at 4:26 pm #1298991thanks, I understand.
Mary
May 7, 2021 at 4:37 pm #1298994Hi Mary,
No worries, we’re just happy to help you.
Just let us know if you need further assistance :)Best regards,
NikkoMay 10, 2021 at 7:19 pm #1299477Good morning, I am trying to find where the WPML plugin is.
I have attached my login information in the Private Content.May 11, 2021 at 5:15 am #1299529Hi merrywatson,
You can’t find it in the Plugins, since it can be download and purchased in their site: https://wpml.org/
I think you can try to checkout Polylang since it’s free.Best regards,
NikkoMay 11, 2021 at 4:12 pm #1299724I thought the WPML was part of the Enfold template? Are you saying I would need to purchase it? For a free one you are suggesting I use the Polylang.
May 12, 2021 at 4:45 am #1299797Hi merrywatson,
WPML is a third party plugin and not part of Enfold but our theme supports it (some integrations), I apologize for not being clear.
You can think of it similar to Woocommerce where it is a separate plugin (different author) but once you install and activate that plugin certain features in Enfold are unlocked (like additional elements).
And yes, WPML is a paid plugin.Best regards,
NikkoMay 12, 2021 at 4:11 pm #1299958Thanks, I will look into using it.
Mary
May 13, 2021 at 6:52 am #1300026Hi Mary,
You’re welcome :)
Just let us know if you still need further assistance regarding this topic or if we can close this thread.Best regards,
NikkoMay 13, 2021 at 3:14 pm #1300169Please close this thread and thanks for your help.
Mary
May 14, 2021 at 8:54 am #1300268Hi Mary,
We’re glad to hear that :)
Thanks for using Enfold and have a great day!Best regards,
Nikko -
AuthorPosts
- The topic ‘adding flag images to my secondary navigation’ is closed to new replies.