vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=192)
-   -   Show Thread Enhancements - Translate a Thread in a Google Pop-Up Window (https://vborg.vbsupport.ru/showthread.php?t=168439)

vbob 01-25-2008 11:03 AM

Quote:

Originally Posted by Digital Jedi (Post 1428574)
The alternative code, and this my fault really, as I didn't check FireFox before I went to bed last night, wont necessarily work for cross browsers. Both browser require different lines of code to align them similarly. And everything I've looked at so far just seems inelegant from what I had intended. This is really my fault also for trying to get fancy with code I'm not all that familiar with.

I think I have a much simpler, more elegant solution for folks, without trying to get all fancy and cute. It should actually provide a solution for everyone. Just give me a few to edit Post 2. If it gets to late tonight (6 AM here), I'll try to have a replacement up by Friday night, barring flood or famine (or just forgetting to pay my Internet bill =/ ).

:-)

I believe that this mod is wonderful!!! :-)
(and thank you for your mod) :-)
To solve any problems, You should begin with the rule "keep it simple". :-)
If I were you, i would give 3 kind of different "Code situations" so anyone can fit the code in his needs. :-)

1) Make a script that can translate FROM: Any* Language TO: English (that could be very useful as English language is the Language that most of people could understand). So if someone have a i.e. Greek language board, can use the Greek to English option to be sure that at least the translation to the basics will be done for sure. :-)
*= by "Any language" I mean the languages that you already have in the script. :-)
2) Give people an example of "how to" transform existing code to make the script translate from "Any" to "Any" language he like (all the combinations) :-)
3) Make sure the code is simple (so it is surelly supported from all browsers)
4) Then make any experiments and supply people with the script that can do tricks like the one you've done as alternative.

So people can really have a code fitted to their needs, and working for sure. As for the alternative, they could experiment them selfs with various of browsers and give you feedback too. :-)

I hope I helped somehow. :-)
(keep up the good work...!!! I love that mod, thank you. Looking forward for the new "working in all browsers and flexible" (Greek to English...Greek to Any, Any to Any) version.....):-)

(ohh...it would be useful to have icons with words too in the menu like the way I show you below.
for example
[Icon_Country_Flag] Greek to [Icon_Country_Flag] English
[Icon_Country_Flag] Greek to [Icon_Country_Flag] German
.
.
.
etc......

(the ideal should be to recognize the language automatically and the user could just select the language he like to translate "to", but its is difficult and could have problems) :-)

vbob 01-25-2008 06:46 PM

Quote:

Originally Posted by baghdad4ever (Post 1428580)
i love this mod but

sorry it is not work on IE

but it work on firefox

see this

http://www.baghdad4ever.net/vb/showt...362#post791362

For me (my site) it Works fine Both in Firefox and I.E. and Opera too...!!! :-)
I checked your site and yes it have problem with I.E.

Check Out my forum and try to translate from Greek to English if you like to see if you have problem with I.E., Opera, and Firefox there...!!! :-)

http://madseeds.com/forum

Here is the Code I used for my forum (Step.2)

PHP Code:

<!-- Language Translator Menu -->
  <
div class="vbmenu_popup" id="languagemenu_menu" style="display:none">
        <
table cellpadding="4" cellspacing="1" border="0">
<
tr><td class="thead">Translate</td></tr>
 


<!--
Greek to English-->
<
tr><td align="right" class="vbmenu_option"><a href="#" onClick="Fenster1=window.open('http://translate.google.com/translate?u=http%3A%2F%2Fwww.madseeds.com/forum%2Fshowthread.php%3Ft%3D$thread[threadid]&langpair=el%7Cen&hl=en&ie=UTF-8','','directories=no,location=no,resizable=yes,scrollbars=yes,toolbar=no,status=no,menubar=no,width=800,height=800')">
<
img src="$stylevar[imgdir_button]/gr.gif" alt="Greek" width="15" height="10" border="0" /><span title="Greek">Greek to English Translation</span> <img src="$stylevar[imgdir_button]/us.gif" alt="English" width="15" height="10" border="0" /></a></td></tr>
 
  
   </
table></div>
 
  <!-- / 
Language Translator Menu --> 


(I also Changed the "Language" title to "Translation" title..!!!)
Later when i find some time I will fix it for the other languages too if I can..!!! :-)
I prefer to have simple menus so any unexperienced user can use it...(I mean that I want the menu to work to all browsers for sure)!!! :-)

yeku 01-26-2008 01:23 AM

Hello, my forum is in Spanish.

What I have to do modifications because you do not work

I need you to help me please.

thanks

Digital Jedi 01-26-2008 09:57 AM

Okay, guys. This took me a bit longer to put together then I thought it would. I'm sure it's not completely perfect, but see post 2 of this thread again. You can now add a link to all the available language options that Google offers.

Vbob, thanks for letting me know about the translation working in Greek. That's really the only thing about this mod that I can't test myself, so thanks much for the feedback. And thanks also for the suggestions. I was thinking along the same lines as well.

Baghad4ever, I'm sorry. But it appears to be an issue with Google and IE. My uneducated guess would be that is has something to do with the fact that their is a "vb" in your thread URLs. One other user had the same problem with way his URLs were formatted. Still, I can't imagine why FireFox would translate just fine and IE wouldn't. But at the moment, I don't know why.

Apiasto, see the new version I added to post 2 just now.

Yeku, what problems are you having exactly? If your trying find a Spanish to English translator, I only just added that now in post 2.

yeku 01-26-2008 11:47 AM

Quote:

In order to accept POST request originating from this domain, the admin must add this domain to the whitelist.
This is the answer, in admincp, I have "google.com/language_tools" and "translate.google.com/translate?"

Also when I try to make a translation, finalize session:erm:

What do I do wrong??

pd: Alternative 2, post n?2

Lombardo 01-26-2008 12:09 PM

In order to accept POST request originating from this domain, the admin must add this domain to the whitelist.

I get that too when i try to translate Italian to english all the rest work fine,just this.

baghdad4ever 01-26-2008 02:40 PM

thanks my dear

but my forum is arabic lang

so

only translate to english would be work

bec the google option only from arabic to english

so how can i made another translations to be work??

vbob 01-26-2008 02:57 PM

Quote:

Originally Posted by Digital Jedi (Post 1429217)
Vbob, thanks for letting me know about the translation working in Greek. That's really the only thing about this mod that I can't test myself, so thanks much for the feedback. And thanks also for the suggestions. I was thinking along the same lines as well.

You are welcome Digital Jedi. I am glad I helped. Thanks for your mod..!!! :-)
It is working fine for me (Greek to English and English to Greek Translation, tested in Firefox, I.E., Opera) :-)

Digital Jedi 01-26-2008 03:18 PM

Lombardo, yeku, in order for Google to translate a page, it needs to be able to see your page. So you'd need Guest browsing enabled, as you wont be able to log in from a translated page. I'm sorry, that's just how Google's service works.

baghdad4ever, what additional languages are you looking for? Have you tried the other language options yet? Sorry if I'm misunderstanding you.

Vbob, that's good to know. Feel free to ping this thread if you run into any other problems.

Lombardo 01-26-2008 03:30 PM

Works now mate,thanks a lot for your efforts mate.Its much appreciated.


All times are GMT. The time now is 08:00 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01222 seconds
  • Memory Usage 1,765KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete