Hello,
We would like create BLOCKS per LANGUAGE... and give right
Example : Italian can see only bloc with "right" ITALIAN...
Do you think its possible ?
A mod in Market ?
That's will be better, because i can't create 1 boonex per language...
Hello, We would like create BLOCKS per LANGUAGE... and give right Example : Italian can see only bloc with "right" ITALIAN... Do you think its possible ? A mod in Market ? That's will be better, because i can't create 1 boonex per language... |
You can add multiple languages and people can select their language. There also might be a mod available that automates this for you. Dedicated servers for as little as $32 (28 euro) - See http://denre.com for more information |
Be a bit more specific in the content of the block. However, this is probably going to be a bit tricky. Unless you have a profile field with language; the member's country is part of the standard join form. The php block code would have to check for the user's language. Now here is a trick, php blocks will not be displayed if they are empty. So what you would do is to check for the users language and if not correct just return from the script. Anyway, so check if !correct_language; return (that is not correct code, just pseudo code). This will return an empty block so it will then not be displayed to the member. Geeks, making the world a better place |
No, because if i create a block with French text, all member can read this text...For an italian member, its impossible to understand the text...This block must be see by French member only ... and not Italian member... normalIts a real problem, because i can't create 10 boonex for the world and content are always different |
No, because if i create a block with French text, all member can read this text...For an italian member, its impossible to understand the text...This block must be see by French member only ... and not Italian member... normalIts a real problem, because i can't create 10 boonex for the world and content are always differentI gave you the answer. You will create a php block. If the block is just going to be text, then you can use PHP to output the text. The PHP script will do a check for the person's language, or I am guessing that country will work just as well and that is already a part of the join. If the language is not correct; and you would code that into each block, it will simply return, and that block will not be displayed. $lang = "italy"; check to see if the current user country matches $lang; if not, then return. That block will not be shown to anyone unless their country is Italy. If you can not do this coding, then contact a Dolphin coder or Dolphin module developer; it should not take long to make a module that can do this with you choosing the language in a backend interface. Or, they code a php block for you and all you would need to do is to change the language string. Geeks, making the world a better place |
Thanks for your messages.. The method seems good... geek_girl I'll try to find a good developper for this job... If you can, contact me... |
Or you can just use whats already available. https://www.deanbassett.com |
Whaouuuu..... That seem a very good solution. I will test quicky and i inform you... Thanks a lot !!! |
OK, I think I misunderstood the question. If the text you are wanting to display is going to be the SAME for all members, then yes, Dean's simple solution is perfect. It is why language keys are part of Dolphin, to make it easy to have text presented in different languages. Geeks, making the world a better place |
Or you can just use whats already available. I created a new block php with DEANOS TOOL on index page... but my syntax seems bad I write : echo _t('_myLanguageKey'); in field PHP Code PS : The key is just for test... Can you help me... Thanks per advance PS... image on attachments |
Why do you think the syntax is bad? https://www.deanbassett.com |
In fact, in the block, appear : __sbs_txt_title_bx_poll .... but not the equivalence with the Key in langage file PS : Attachment... |
Sorry, it's Ok.... 2 underscore... Thank's a lot !!! |
Something else. I would like to insert a photo which would be on my server. What is the code ? In fact, I am afraid that the file language becomes too heavy. We can use of the HTML code ? What intrigues me, it is the syntax : echo _t('_myLanguageKey'); Thanks per advance |
Something else. I would like to insert a photo which would be on my server. What is the code ? In fact, I am afraid that the file language becomes too heavy. We can use of the HTML code ? What intrigues me, it is the syntax : echo _t('_myLanguageKey'); Thanks per advance Language keys can hold HTML markup. So you could have a language key with <img src="http://mysite.com/media/images/my_image.ext" /> and then when you echo out the language key it will display the image. Of course you can echo out the markup directly. For larger echos, use heredoc:
Geeks, making the world a better place |
Thanks to you all. It opens interesting perspectives Thank you again ! |