Link to Mod (https://custom.simplemachines.org/mods/index.php?mod=3896)
One of the common complaints is Q&A support in SMF doesn't support multiple answers per question or languages per question.
I added this to 2.1 back in October 2013, but there's been nothing in the meantime, so here we go, a package ported back from 2.1's support. Everything is, therefore, 3-clause BSD should you want to do anything with it.
It's not a perfect port; 2.0 doesn't have jQuery as standard so I had to rewrite the JavaScript a little, but in hindsight it sort of works better this way.
While of most use to people with multiple language sites, anyone who wants to offer multiple choices of answer for any question can use this, e.g. if you want to offer variations on spelling or both numeric and textual answer components (e.g. 12 vs twelve)
Technical notes:
It uses the same table name and structure as 2.1 and so should upgrade cleanly. It will take your existing questions and upgrade them to the new table (and if you remove it, your original questions are preserved)
Note: to use this with multiple languages, UTF-8 is STRONGLY preferred. I will not get into trying to support installations that are running multiple languages without being UTF-8, it can't end well.
Changelog:
24 July 2014 - 1.0.2
Added German, French, Italian and Dutch translations, thanks to Justyne, Flavio93Zena and Dav999
24 July 2014 - 1.0.1
Added Russian translation, thanks Bugo!
18 July 2014 - 1.0
Bug fix for certain admin edge cases
16 July 2014 - 1.0
First version
this isa a wonderful addition o my site. Thanks. :D
*-* finally the (http://www.katzy.dsl.pipex.com/Smileys/cake.gif) huh? :D Thanks!
Good job man! thanks
@ ‽:
Very helpfull mod indeed! Thanks!
But... I think there's a small bug in it? I'm just testing the looks of the various questions now. When I'm looking at the French version I see the French verification questions. When I change the language to English, I go back one page to the Registration Agreement. When I press 'Accept' I go again to the verification page, but while that whole page is in English, the questions are still in French. When I Press 'Register' again in the top of the page, I go back to the RA, press 'Accept' and then the whole verification page is in English. Same thing other way around, same with Dutch. But it doesn't happen all the time... When I go e.g. from English (with English questions) to Dutch, the Dutch has also English questions. But when I go straight on to French, the French has normal French questions. Straight on to English, I see still French questions... When you just press the 'Registration' at the bottom of the verification page the wrong language questions just stay in the wrong language.
You might want to have a look at this. Sure looks silly...
Edit: here (http://www.simplemachines.org/community/index.php?topic=525073.msg3723191#msg3723191) explained. Issue was considered by creator, but could also be seen as an extra barrier for spambots. Not a real issue for legitimate users.
Add russian translation, please.
Thanks, I'll update that later on today if I get chance.
Thanks, I've updated the package with the Russian translation and bumped it to version 1.0.1.
You know what they are ;) I suggest you to wait though, maybe I can do the French one as well if I remember how to say some words. I will add the attachments along the way. (done already)
I kindly ask any French guy to revise my translation if that was incorrect (even if it should be), it's been a few years I haven't spoken French.
Thanks for the mod once more Pete :)
// Handle verification questions.
// Handle verification questions.
Intentional?
Proof I'm human.
Here's a Dutch translation :)
$txt['setup_verification_add_answer'] = 'Voeg een nieuw antwoord toe';
$txt['question_not_defined'] = 'Er moet een vraag en antwoord toegevoegd worden voor de standaard forumtaal (%1$s) anders kunnen gebruikers geen verificatie invullen, en zich dus niet registreren.';
Thanks for the translations, Flavio and Dav999, I'll sort them out later on tonight.
Flavio: I'm confused by your translations. Firstly, the non-UTF-8 files are using UTF-8 characters, so that's not going to work properly, and secondly the entities in the UTF-8 files aren't fully formed; they should end with a ; to be legal entities. Browsers can parse them at their discretion but they're not supposed to.
Quote from: ‽ on July 24, 2014, 12:58:29 PM
Thanks for the translations, Flavio and Dav999, I'll sort them out later on tonight.
You may want to ommit the last comma in the Dutch translation.
Ugh, I *literally* just uploaded them.
Don't worry, it will most likely not kill anybody. :comforting
The comma is a small, non-important difference. You could omit it if you want, now that I think of it I think I should have added a comma after the "(%1$s)" :P
Quote from: ‽ on July 24, 2014, 01:56:21 PM
Flavio: I'm confused by your translations. Firstly, the non-UTF-8 files are using UTF-8 characters, so that's not going to work properly, and secondly the entities in the UTF-8 files aren't fully formed; they should end with a ; to be legal entities. Browsers can parse them at their discretion but they're not supposed to.
UGH, I reversed the name of the files while saving them =_= sorry about that. And about the entities... Huh? I can see no significant difference between these and yours. :)
LOL about the name, I'm really sorry, lesson learned, never save things when about to leave and in a bit of a hurry xD
They were already fixed and released I think.
Yup, I already fixed the entities, fixed the stray unescaped ', harmonised encoding to be straight entities in both files and updated. It's just easier that way, even if not "ideal" since entities are completely valid ASCII which means they use the same code points in ISO-8859-everything and One True Encoding (UTF-8)
LOL good then, sorry for the typo(s). Won't happen again, at least.
Nice modification. Here's my humble contribution for it since I liked it, a Spanish translation of the only 2 strings there:
<?php
$txt['setup_verification_add_answer'] = 'Añadir otra respuesta';
$txt['question_not_defined'] = 'Necesitas añadir al menos una pregunta (con su respuesta) para el idioma por defecto de tu foro (%1$s). De otro modo nadie podrá resolver el CAPTCHA, lo que significa que no habrá nuevos registros.';
?>
Thanks for your time!
I installed this mod and would like to keep using it (to keep all of those silly Russian spammers out).
But it has a weird bug: it doesn't display the first character of the first question.
Doesn't matter which question it is, and if the same question shows up further down it shows everything, including the first character.
The forum is in Dutch, I don't think that has anything to do with this, just mentioning it to be complete.