Home › Forums › Weaver Xtreme Theme › HTML Insertion in Pre Header
- This topic has 16 replies, 4 voices, and was last updated 1 year, 8 months ago by
Weaver.
-
AuthorPosts
-
December 14, 2024 at 11:44 UTC - Views: 77 #75252
wallee
ParticipantI am currently updating the website on the weaver extreme pro and unfortunately the title is displayed double in the languages F and D (above the header image). I have entered the titles via HTML insertion in the pre header (see neu.voyagevertical.ch):
<!–:fr–>
<!–:–><!–:de–>
<!–:–>On the old webpage (voyagvertical.ch) with weaver pro this worked fine. Do I have to enter the HTML somewhere else?
If you need the password for the webpage please let me know.
December 14, 2024 at 15:09 UTC - Views: 73 #75253User
Moderator@Scrambler will need to comment.
Regards!
December 14, 2024 at 15:22 UTC - Views: 78 #75254wallee
ParticipantI have entered the title via HTML insertion in the preheader (see new.voyagevertical.ch):
<!–:fr–>
<!–:–><!–:de–>
<!–:–>On the old webpage (voyagvertical.ch) with weaver pro it worked fine like this
December 14, 2024 at 17:04 UTC - Views: 61 #75257scrambler
ModeratorIt looks like you are using shortcodes (
<!–:fr–>
<!–:–><!–:de–>
<!–:–>To hide or display contents based on the site language.
This is not a theme feature nor a worpdress one I believe, and so I suspect this is a Plugin you are using. If so, you need to make sure that plugin is installed and if it does not do what it is suppose to, contact the plugin developper
December 16, 2024 at 23:23 UTC - Views: 53 #75265wallee
Participantstrange, the plugin otherwise works perfectly with the extreme pro (see “neu.voyagevertical.ch”)
With weaver II pro I was able to display the titles in two languages without them appearing double (see “voyagevertical.ch”).December 16, 2024 at 23:31 UTC - Views: 52 #75267wallee
ParticipantI have now made the title in English so that it does not appear double…
December 17, 2024 at 17:01 UTC - Views: 44 #75272scrambler
ModeratorHave you tried contacting the developer to ask them, they may be able to figure out why it would not work and then we can determine if it is an issue on their end or something in the theme interfering,
Also, Have you tried deactivating ALL other non weaver plugins, in case the interference is with something else?
If it solves the issue, reactivate one by one to find the culprit
December 17, 2024 at 23:14 UTC - Views: 42 #75276wallee
Participantnow the qtranslate-xt pluging is maintained open source via https://github.com. A top pluging; which runs with the Weaver II pro and also with Weaver extreme.
I have totally the same plugins installed on both webpages and I assume that the HTML insertion for the PreHeader just does not work in both languages on the weaver extreme.
Therefore another idea: is it possible to place a widget with the titles above the header image (preheader area)? A widget should actually work bilingually.December 17, 2024 at 23:26 UTC - Views: 37 #75277scrambler
ModeratorCan you try to place the shortcodes and content inside a test page to see if they work there
December 17, 2024 at 23:59 UTC - Views: 35 #75278wallee
ParticipantYes, thank you, that works. It’s a little less elegant because it needs to be entered on every page, but it works 🙂
December 18, 2024 at 00:42 UTC - Views: 33 #75279scrambler
ModeratorI wanted you to do the test to confirm the problem with the HTML insertion area, not as a workaround 🙂
@weaver, he is using a shortcode from a plugin that hides or show content depending on the language, and apparently, these do not work when placed in the HTML insertion area, but do work in othe5r content area.Any reason why a shortcode would behave like that ? Could it be a filtering problem specific to the insertion area
The shortcode looks likethis
<!–:fr–>
Content1
<!–:–><!–:de–>
content2
<!–:–>December 18, 2024 at 13:18 UTC - Views: 29 #75280wallee
Participantyes, at least under the outdated Weaver II pro the HTML input in the PreHeader works perfectly with this code without both languages being displayed at the same time.
If I enter the code in the individual field at the bottom of the page with the name “preheader” and the value “<!-:fr->Content1<!-:-><!-:de->content2<!-:->”, it also works perfectly in the Weaver extreme pro. But the code has to be entered on every page…December 18, 2024 at 16:51 UTC - Views: 23 #75281scrambler
ModeratorUntil @weaver answer, have you tried placing the shortcodes in the Header widget area or the footer widget area?
Below are all the areas available
Layouts and HTML Insertion Areas – Weaver Xtreme Guide
In case it is a filtering issue specific to the HTML insertion areas, use any other area
December 18, 2024 at 20:07 UTC - Views: 26 #75282Weaver
KeymasterThe preheader code is inserted directly into the generated HTML, and it I don’t think it will process shortcodes – mostly because the main intent of that area is for inserting javascript and custom html. I suppose it was possible that Weaver II handled pre-header differently.
But I don’t really understand exactly where a shortcode is being used. Is it a shortcode from a plugin that somehow adds the <!-:fr->French content<!-:->?? Is there a WP type shortcode [shortcode-name values] in the PreHeader area? <!-:-> is not any sort of valid HTML code I’ve ever heard of, nor is it proper syntax for WP shortcodes, so I’m pretty confused.
I couldn’t open the test side new.voyagevertical.ch, so can’t tell much. Maybe if I looked at that, I could tell more.
I also think one could use pretty vanilla custom HTML embedded into whatever area is used to display the logo and text:
<p lang="nl">Dit is een Nederlandse paragraaf.</p>
<p lang="de">Dies ist ein deutscher Satz.</p>
<p lang="en">This is an English sentence.</p><p lang="en-GB">Matching the language range of English.</p>
<p lang="fr">Ceci est un paragraphe français.</p>
<p lang="fr-Latn-FR">Ceci est un paragraphe français en latin.</p>
So use the Weaver HTML shortcode to add your language dependent header which would change depending on language.
This example found here: https://developer.mozilla.org/en-US/docs/Web/CSS/:lang#examples
December 19, 2024 at 17:27 UTC - Views: 19 #75285wallee
ParticipantHello,
it is not called new. but neu. But you might as well type voyagevertical.ch now that I have published the site.
I entered this code in the HTML insertions area a few years ago based on a advice from you and it worked perfectly with weaverII pro.
With weaver extreme, however, the input in the HTML insertions pre header does not work, or is then displayed twice.
As I said, if you enter the code on the page, the title is displayed correctly, i.e. in the respective language.
I have not yet tested whether it works with a widget, but I think so, as the other widgets are also displayed correctly depending on the language. What would be the best place to place a widget in the preheader?
best regards
December 19, 2024 at 21:19 UTC - Views: 11 #75286scrambler
ModeratorHave you tried the other method weaver mentioned
-
AuthorPosts
- You must be logged in to reply to this topic.

