• Register
    • Help

    striker  0 Items
    Currently Supporting
    • Home
    • News
    • Forum
    • Wiki
    • Support
      • Manage Subscriptions
      • FAQ
      • Support For
        • VaultWiki 4.x Series
        • VaultWiki.org Site
    • What's New?
    • Buy Now
    • Manual
    • 
    • Support
    • VaultWiki 3.x Series
    • Feature
    • Multilingual articles setup, completely independent from forum language

    1. Welcome to VaultWiki.org, home of the wiki add-on for vBulletin and XenForo!

      VaultWiki allows your existing forum users to collaborate on creating and managing a site's content pages. VaultWiki is a fully-featured and fully-supported wiki solution for vBulletin and XenForo.

      The VaultWiki Team encourages you to join our community of forum administrators and check out VaultWiki for yourself.

    Issue: Multilingual articles setup, completely independent from forum language

    • Issue Tools
      • View Changes
    1. issueid=2171 December 22, 2010 6:45 AM
      Alfa1 Alfa1 is offline
      Distinguished Member
      Multilingual articles setup, completely independent from forum language

      Please add functionality to interlink an article with the same topic other languages by adding a flag symbol of the language. Similar to how e-commerce sites can show a set of flags, to depict that the same content is available in different languages.

      This should be completely independent from forum language. i.e. all articles should be visible to all readers, not matter what forum language they use.

      It should also be possible to browse articles per language. Each language could be considered as a different division/department/category.
    Issue Details
    Issue Number 2171
    Issue Type Feature
    Project VaultWiki 3.x Series
    Category Language / Phrasing
    Status Closed (Merged)
    Priority 4 - Warnings / Script Errors
    Suggested Version 4.0.0 Alpha 1
    Implemented Version (none)
    Milestone VaultWiki 4.0.0 Alpha 1
    Software DependencyAny
    Votes for this feature 2
    Votes against this feature 0
    Attachments 0
    Assigned Users (none)
    Tags (none)




    1. March 24, 2011 9:33 PM
      Alan_SP Alan_SP is offline
      Regular Member
      Just to add my comment, what's bothering me and why in present (3.0.11b002) VaultWiki:

      I'm having site in Croatian, most people use Croatian and similar languages (Serbian, Bosnian, Slovenian...) and Croatian language is the site's default one.

      I personally use English language for commands as I find them more usable in AdminCP and all around. Of course, when I write in forum, CMS etc I write in Croatian. I just saw that creating article in Croatian changed my forum language to Croatian. And if I wrote article in English, that would change language to all users' site language to English. For now, I'll manually change language to English, but I'd really like to see this independent, language the article is written in and language I see commands.

      I see it's accepted, but just wanted to say it anyway, as it is very important to me and I want you make it right for me too.
      Reply Reply  
    2. April 3, 2011 1:26 AM
      Alan_SP Alan_SP is offline
      Regular Member
      I just noticed, auto links also depend on language settings and if you look your forum in different language then wiki article is in, you won't see any auto links. I hope this is also fixed...
      Reply Reply  
    3. April 3, 2011 2:08 AM
      pegasus pegasus is offline
      VaultWiki Team
      Since article language won't be dependent on forum language, we won't be able to filter the article list based on the session language. Also, in order to enable two-way lookups, eliminate namespaces, and allow for article-level URL customization, we had to make language independent from the article's URL as well.

      This has the side effect of not being able to determine what language the article is without fetching the article itself. And this means that the complete article list must always be available for auto-linking, regardless of language.

      However, if the article's character set and the forum character set don't match, some characters (and titles) will not match because the character codes differ between sets.

      This is a long way of saying VaultWiki 4 will have the issue "fixed".
      Reply Reply  
    4. April 3, 2011 1:54 PM
      Alan_SP Alan_SP is offline
      Regular Member
      Excellent, thanks. I really like auto linking, it's fantastic, extremely useful.
      Reply Reply  
    5. April 3, 2011 5:26 PM
      basketmen basketmen is offline
      Junior Member
      Quote Originally Posted by pegasus
      Since article language won't be dependent on forum language, we won't be able to filter the article list based on the session language. Also, in order to enable two-way lookups, eliminate namespaces, and allow for article-level URL customization, we had to make language independent from the article's URL as well.

      This has the side effect of not being able to determine what language the article is without fetching the article itself. And this means that the complete article list must always be available for auto-linking, regardless of language.

      However, if the article's character set and the forum character set don't match, some characters (and titles) will not match because the character codes differ between sets.

      This is a long way of saying VaultWiki 4 will have the issue "fixed".
      pardon me to join the thread. actually maybe there is another way for this, i will share the hack if i can make it, but i need help too, to get information the right code that VW use

      so it is by using if languageid conditional in a plugin, to replace word become link, inspired by this hack Word Replacement. But you need to enter each words manually, that you want to become link, like example below, its no big deal for me

      for example you have an article page in english (languageid = 1)
      so we create new plugin like this hack Word Replacement, and just add if conditional for the language id, and change this code post['message'] (for forum post) into what VW code use (for wiki article post)

      Code:
      if(LANGUAGEID == 1)
      {
      $word = array(
      'google',
      'yahoo'
      );
      $link = array(
      '<a href="http://mydomain.com/wiki/google">google</a>',
      '<a href="http://mydomain.com/wiki/yahoo">yahoo</a>'
      );
      $this->post['message'] = str_replace($word, $link, $this->post['message']);
      }
      So only wiki article with languageid = 1 that will replaced the words into link, other wiki article with other languageid are not linked. For wiki article in other language we can create new plugin again just repeat above step

      i think this can be working, i want to try it. So pegasus, can you let me know what is excatly the code for wiki article post to put above? this is the code for forum post : post['message'], what is the code for wiki article post?
      please let me know if i am not clearly to tell what i mean
      Reply Reply  
    6. April 3, 2011 7:35 PM
      pegasus pegasus is offline
      VaultWiki Team
      $post['message']

      What you describe is already the way it's done. It's not perfect and is not the way it will be done in version 4, because languages won't be tied to the article route... Sacrificing flexibility in one area for flexibility pretty much everywhere else.

      Also the code you posted doesn't take into consideration that the terms might appear inside other BB-Codes or HTML. If the matches appear in a bad place, it can create broken HTML and leave vulnerabilities for attackers to exploit on your site, as long as they have knowledge of what words trigger replacements. Just writing this post I have already thought of 1 way to inject Javascript onto your site. If this is exactly how the mod works I recommend uninstalling it.
      Reply Reply  
    7. April 4, 2011 12:41 AM
      basketmen basketmen is offline
      Junior Member
      Quote Originally Posted by pegasus
      $post['message']

      What you describe is already the way it's done. It's not perfect and is not the way it will be done in version 4, because languages won't be tied to the article route... Sacrificing flexibility in one area for flexibility pretty much everywhere else.

      Also the code you posted doesn't take into consideration that the terms might appear inside other BB-Codes or HTML. If the matches appear in a bad place, it can create broken HTML and leave vulnerabilities for attackers to exploit on your site, as long as they have knowledge of what words trigger replacements. Just writing this post I have already thought of 1 way to inject Javascript onto your site. If this is exactly how the mod works I recommend uninstalling it.
      - so VW article post are using this code too $post['message'] ?

      - this mod same like admincp >> Styles & Templates >> Replacement Variable Manager, only its weaker only replacing in post message.
      Many people install this mod (34 install), and similar mod vBaffiliate Links (113 install), no security problem reported from those threads, and 2 vb staffs are posted in those thread too http://www.vbulletin.org/forum/showp...2&postcount=23 http://www.vbulletin.org/forum/showp...3&postcount=39 , but i will be careful too and get second opinion too

      if you can please just answer the first question above, at least this if conditional should be work right, including wrap VW autolinks plugin in wiki article pages

      if(LANGUAGEID == 1)
      {

      }
      Reply Reply  
    8. April 4, 2011 3:36 AM
      pegasus pegasus is offline
      VaultWiki Team
      Yes, VW uses $post['message'] but I see no reason to add your own plugin to make language-filtered auto-links, since VaultWiki does this already... and VaultWiki won't put the links if there's already a link on the word (the mods will). Like if you have "BB-Code" as a link-word and it appears like this:
      Code:
      &lt;a href="http://www.example.com/BB-Code"&gt;Some BB-Code&lt;/a&gt;
      The mods you mentioned replace it with this:
      Code:
      &lt;a href="http://www.example.com/&lt;a href="http://www.bbcode.com">BB-Code&lt;/a>">Some &lt;a href="http://www.bbcode.com">BB-Code&lt;/a>&lt;/a>
      And it seems you are right this doesn't work as a "security hole", it just spits out garbage if you try to use it. Just make sure you always use " in your replacement tags around the href attribute value, or it will become a hole.
      Reply Reply  
    9. October 8, 2011 5:04 AM
      basketmen basketmen is offline
      Junior Member
      Quote Originally Posted by basketmen
      pardon me to join the thread. actually maybe there is another way for this, i will share the hack if i can make it, but i need help too, to get information the right code that VW use

      so it is by using if languageid conditional in a plugin, to replace word become link, inspired by this hack Word Replacement. But you need to enter each words manually, that you want to become link, like example below, its no big deal for me

      for example you have an article page in english (languageid = 1)
      so we create new plugin like this hack Word Replacement, and just add if conditional for the language id, and change this code post['message'] (for forum post) into what VW code use (for wiki article post)

      Code:
      if(LANGUAGEID == 1)
      {
      $word = array(
      'google',
      'yahoo'
      );
      $link = array(
      '<a href="http://mydomain.com/wiki/google">google</a>',
      '<a href="http://mydomain.com/wiki/yahoo">yahoo</a>'
      );
      $this->post['message'] = str_replace($word, $link, $this->post['message']);
      }
      So only wiki article with languageid = 1 that will replaced the words into link, other wiki article with other languageid are not linked. For wiki article in other language we can create new plugin again just repeat above step

      i think this can be working, i want to try it. So pegasus, can you let me know what is excatly the code for wiki article post to put above? this is the code for forum post : post['message'], what is the code for wiki article post?
      please let me know if i am not clearly to tell what i mean
      i am sorry for replying old thread, i am still cant make this, this mod will be useful, only replacing text in language page that we want, or manual replacing text that we want, beside autolinks, i am prefer using this mod better than autolinks btw
      if you can help i will send $14.98 that usually for Upgrade Service

      this is the only plugin
      Code:
      if(LANGUAGEID == 1)
      {
      $word = array(
      'google',
      'yahoo'
      );
      $link = array(
      '<a href="http://mydomain.com/wiki/google">google</a>',
      '<a href="http://mydomain.com/wiki/yahoo">yahoo</a>'
      );
      $this->post['message'] = str_replace($word, $link, $this->post['message']);
      }
      its works in forum post, the text are not replaced, using hook postbit_display_complete

      but still not working in wiki article page, and using vault_article_complete hook, gets this error
      Code:
      Fatal error: Using $this when not in object context in /home/username/public_html/vault/tab/article.php(712) : eval()'d code on line 11
      i already tried to change this line
      Code:
      $this->post['message'] = str_replace($word, $link, $this->post['message']);
      with these line below, changing the $this with other variable, but still not working, the text are not replaced, please help how is that line should be to work in wiki article page
      Code:
      $post['message'] = str_replace($word, $link, $post['message']);
      $post[message] = str_replace($word, $link, $post[message]);
      $post->post['message'] = str_replace($word, $link, $post->post['message']);
      $post->post[message] = str_replace($word, $link, $post->post[message]);
      $postid->post[message] = str_replace($word, $link, $postid->post[message]);
      $postid->post['message'] = str_replace($word, $link, $postid->post['message']);
      $post_message->post[message] = str_replace($word, $link, $post_message->post[message]);
      $post_message->post['message'] = str_replace($word, $link, $post_message->post['message']);
      $post_message_$post[postid]$post[id_suff]->post['message'] = str_replace($word, $link, $post_message_$post[postid]$post[id_suff]->post['message']);
      Reply Reply  
    10. October 8, 2011 5:19 AM
      pegasus pegasus is offline
      VaultWiki Team
      Since you need to modify the post message before it's created, and you need to do it in object context. Use the hook vault_postbit_complete and apply the replacements to:
      Code:
      $this->post['message']
      Also use hook vault_postbit_broken, and apply the replacements to:
      Code:
      $messagebit
      Reply Reply  
    11. October 16, 2011 6:52 AM
      pegasus pegasus is offline
      VaultWiki Team
      Closing as merge to: https://www.vaultwiki.org/issues/2499/
      Reply Reply  
    12. October 17, 2011 12:19 AM
      Alfa1 Alfa1 is offline
      Distinguished Member
      This issue is the main attraction for VW4 for me. I much need to have a function to post translations of wikis. For example: if you have a wiki about bengal cats in English, that wiki would have flag icons for other languages. Clicking on those icons would bring the user to the German, French, Spanish translation of that article. (or whatever languages the admin has defined).

      Issue 2499 does not seem to describe this function.
      Reply Reply  
    + Reply

    Assigned Users
    Loading Please Wait
    Tags
    Loading Please Wait
    • Contact Us
    • License Agreement
    • Privacy
    • Terms
    • Top
    All times are GMT -4. The time now is 12:51 AM.
    This site uses cookies to help personalize content, to tailor your experience, and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Learn more… Accept Remind me later
  • striker
    Powered by vBulletin® Version 4.2.5 Beta 2
    Copyright © 2023 vBulletin Solutions Inc. All rights reserved.
    Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2023 DragonByte Technologies Ltd.
    Copyright © 2008 - 2013 VaultWiki Team, Cracked Egg Studios, LLC.