Nathan Explosion Posted December 13, 2021 Posted December 13, 2021 (edited) This resource is not yet in the MarketPlace...so calm down!! 😉 I am writing this up now for the eventual release... Here's what it does do... Shows a 'Translate' link/menu below the content in Forum/Calendar/Pages* (support for other applications may be added depending on popularity of this application) * "Pages" will require a manual action by the admin to add something to the 'Display' template(s) for their database. Uses Google's Cloud Translation REST API (Basic) or DeepL's Translator API You, the Admin, can choose from the list of the API's supported languages and make those available to the user for use (would be a good idea - Google supports approximately 100 target languages while DeepL currently supports 28 target languages If you choose to display one language for use, then a single link is available to the user But if you choose more than one language then a menu will appear listing the configured available languages. You can also choose who can see the translate option. When a language is selected, the content will be sent to the configured API using REST, translated and returned. The returned translation will be processed and the content will be replaced. Additionally, each translation is stored in the database so that further translation requests for the same content are pulled from there instead of being translated via the API. If the original content is edited then any translations stored in the database will be discarded, ensuring that any further translation requests do not provide an out-of-date translation, and always translate the current content. Functionality exists to allow you to view the translations in the ACP and refine the translation if you so wish. Translations can be 'protected' so that the editing action above doesn't discard the translation - useful if you have refined the translation and wish to retain that refinement In this case, if an edit is performed then a clear indication will be displayed in the ACP advising that the translation is out-of-date due to the original content being edited. The user can revert to the original content at any time by clicking a link to do so. Usage logs are available in the ACP for each translation request, so you can see basic information about requests made from your site out to the APIs (both of which have their own console available which provides detailed usage information), along with requests made to content saved in the database. Here's what it doesn't do... It does not translate your entire site at the flick of a switch. If that is something you are seeking then you would have to implement your own Google Translate functionality on your site (https://www.dummies.com/article/technology/notable-websites/google/how-to-install-google-translates-website-translator-plugin-145074) Translation of content at the time of display, as opposed to a user choice Why? Translation is performed via a REST API request - each item of content in a topic, for example, would need to be sent to the API. In a topic with multiple posts then this will mean up to 25 REST API requests being performed to display each page of the topic. That is going to result in a performance hit, and is not something I am willing to put in place at this time. Will it be a future feature? Maybe, but no promises.   Edited January 9, 2022 by Nathan Explosion BomAle, SeNioR-, Edjazoli and 1 other 4
Nathan Explosion Posted December 16, 2021 Author Posted December 16, 2021 (edited) v1.1.0 of the application is now pending approval on the Marketplace. A pre-Xmas sale price of $25 ($10 yearly renewal) is in effect, which is 50% off the price of the application. This special price offer will end on 1st January 2022, at which point it will revert to $50 ($20 renewal) IMPORTANT: this was developed against the default IPS theme. If you purchase this application and have a custom theme which results in the template hooks not working then there will be manual steps required to put things in place - instructions can be provided on how to do this, if it is deemed necessary. Edited December 16, 2021 by Nathan Explosion Ilya Hoilik and Edjazoli 1 1
Nathan Explosion Posted December 18, 2021 Author Posted December 18, 2021 Note: v1.1.0 is missing a little content in some language strings related to the privacy policy page on a site. Not a showstopper, but v1.1.1 will populate the missing items. Edjazoli 1
Nathan Explosion Posted December 18, 2021 Author Posted December 18, 2021 OK - this won't be out this side of Xmas, as it has been rejected (awaiting some feedback on the reasons) and I won't have time to work on it much next week due to my normal job workload. Â
Nathan Explosion Posted January 1, 2022 Author Posted January 1, 2022 So, the feedback on the rejection was related to how cache was being used and mainly around the fact that running the support tool will clear that cache (to be expected) So, with that in mind, I'm going all-in on storing the translations in the database instead. And with that, I'm going to build in some functionality that will allow you to refine the API-provided translations by editing them in the ACP (if that is something you wish to do) - I have a few ideas around how that is done, which I am working on over the next few days. Once done, it will be v1.2.0 that will be the version release - and I'll update here once it is released, along with the 'sale' details that will be in place initially.  Edjazoli, SeNioR- and IveLeft... 3
Edjazoli Posted January 8, 2022 Posted January 8, 2022 Let us know asap when will be available for purchase. On the side I must say that is a great job you are doing. Hope you keep yourself and family safe in this pandemic situation.... On 1/1/2022 at 6:04 PM, Nathan Explosion said: translations in the database instead. And with that, I'm going to build in some functionality that will allow you to refine the API-provided translations by editing them in the ACP (if that is something you wish to do) If that will not make the application to"heavy" it will be a great addition  SeNioR- 1
Edjazoli Posted January 8, 2022 Posted January 8, 2022 I was going through my forum today and then I realised if I will apply translation to the post, then every answer/comment will be translated separately….it’s any chance that you can translate the whole topic in to certain languages? For example if I have few answers in Polish, then English and German, it will be easier to apply the “total topic translation “ as an option?
Nathan Explosion Posted January 9, 2022 Author Posted January 9, 2022 14 hours ago, Edjazoli said: it’s any chance that you can translate the whole topic in to certain languages? Maybe at a later point - I would like to concentrate on getting the initial release out first, and see if it is worth my time adding additional functionality outside of the original intended design. Edjazoli 1
Nathan Explosion Posted January 13, 2022 Author Posted January 13, 2022 v1.2.0 is now available. Edjazoli 1
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 (edited) @Edjazoli - sorry, but this is the support topic for the resource..I don't use PM as first point of contact. Quote I just obtained my API key and after adding to the settings I've got this error...any ideas and advices? Thx.  "A configuration or server error has occurred" when accessing 'netranserrors' controller in ACP. Easy fix - it's just a typo. Quote  Interesting - will do a brand new install on my test site, see if it fails for me too and go from there. Edited January 14, 2022 by Nathan Explosion Edjazoli 1
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 @Edjazoli - is the API key for a Pro plan? Edjazoli 1
Edjazoli Posted January 14, 2022 Posted January 14, 2022 @Nathan Explosion, I thought about that as well as I am on the free plan, however I have received the email saying "welcome to the pro". Maybe, if everything is ok on your test site, I will terminate the free plan and join again with the new details?Â
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 (edited) Up to you - but if it's a Pro API then the URL below the API key needs to be changed. Let's improve that area a little to assist with that element - scratch that, found the Pro API URL. Leave it with me for the moment. Â Â Edited January 14, 2022 by Nathan Explosion Edjazoli 1
Edjazoli Posted January 14, 2022 Posted January 14, 2022 Im definitely on the free plan and the only problem is with the key, and yes I even tried to type it in instead of copy/paste. Â
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 Thanks for confirming - your API key isn't being accepted by their site at present. Just in case that is my fat fingers typing it out from the image you sent me, can you send me the text version of the key via PM please? Edjazoli 1
Edjazoli Posted January 14, 2022 Posted January 14, 2022 So I generate another key but this time I use Enter key instead of SAVE and works. Everything works perfectly, however I'd like to add few things: Show translation option for topic's first post- it will be handy if you could connect title and first topic as one translation. I think it will help the users to understand better topic etc. In the list of  language choices is not possible to select more than one language( or maybe its only Safari issue)- however on the iPhone its not a problem. Thank you again for quick reply. Â
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 (edited) v1.2.1 has been submitted for approval New added setting to allow easy switch of DeepL plan being used, to force use of different API endpoints Fixes fixed issue with 'Errors' page in ACP not opening due to a typo in the code Changes hard-coded "Translate" in HTML template changed to a language string Removed redundant .css call from HTML template Renamed .js file to remove an informational message from developer console (message may be construed as an error when it isn't actually an issue) 2 minutes ago, Edjazoli said: Show translation option for topic's first post- it will be handy if you could connect title and first topic as one translation. I think it will help the users to understand better topic etc. Will have a think about that one. 2 minutes ago, Edjazoli said: In the list of  language choices is not possible to select more than one language( or maybe its only Safari issue)- however on the iPhone its not a problem. Not something that I can control - I'm using the IPS form helper to generate the select box for the Languages, which makes it their code and not mine. I will say that Safari on Mac is a pain in the proverbials though. Edited January 14, 2022 by Nathan Explosion Edjazoli 1
Edjazoli Posted January 14, 2022 Posted January 14, 2022 17 minutes ago, Nathan Explosion said: Changes hard-coded "Translate" in HTML template changed to a language string Maybe even in the future a link position Button before post controls Before post controls After post controls Before member name After member name Â
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 12 minutes ago, Edjazoli said: Maybe even in the future a link position Button before post controls Before post controls After post controls Before member name After member name  Not fully following you here - are you referring to moving the 'Translate' menu to different positions? Edjazoli 1
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 1 hour ago, Nathan Explosion said: 1 hour ago, Edjazoli said: Show translation option for topic's first post- it will be handy if you could connect title and first topic as one translation. I think it will help the users to understand better topic etc. Will have a think about that one. This one will be included in the next release after v1.2.1 Edjazoli 1
Edjazoli Posted January 14, 2022 Posted January 14, 2022 1 hour ago, Nathan Explosion said: Not fully following you here - are you referring to moving the 'Translate' menu to different positions? For moving Translate to language string😉
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 2 minutes ago, Edjazoli said: For moving Translate to language string😉 This bit: Quote Maybe even in the future a link position Button before post controls Before post controls After post controls Before member name After member name What is that in relation to?
Nathan Explosion Posted January 14, 2022 Author Posted January 14, 2022 (edited) On 1/9/2022 at 10:37 AM, Nathan Explosion said: On 1/8/2022 at 8:24 PM, Edjazoli said: it’s any chance that you can translate the whole topic in to certain languages? Maybe at a later point - I would like to concentrate on getting the initial release out first, and see if it is worth my time adding additional functionality outside of the original intended design. This one will be included in the next release after v1.2.1, with the following caveats: specifically for Forums only specifically for only the visible comments - each comment to be translated will use 1 API call, and if I send everything from a topic containing 767 comments then you might as well go put the kettle on...twice. 4 hours ago, Nathan Explosion said: v1.2.1 has been submitted for approval And is now available. Edited January 14, 2022 by Nathan Explosion Edjazoli 1
Edjazoli Posted January 15, 2022 Posted January 15, 2022 Any idea why the longer topic is only partly translated and the rest simply disappearing? Pls check the video, due to max total size Im sending the external link on WeTransfer https://we.tl/t-BhKJdyFP8s
Nathan Explosion Posted January 15, 2022 Author Posted January 15, 2022 How long is the content in character terms? Provide a link directly to the item please. Edjazoli 1
Recommended Posts