Introducing Quicktags (qT 2.1 and higher)

Having Problems? Need Help? Post here!

Re: Introducing Quicktags (qT 2.1 and higher)

Postby sillie83 » Wed Jul 07, 2010 11:04 am

How do I change this text ("Oudere Berichten" and "Nieuwe Berichten" to different languages? I tried different ways but none of them work...

Code: Select all
<?php if (show_posts_nav()) : ?>
            <div id="post-navigation" class="clearfix">
               <span class="previous"><?php next_posts_link('Oudere Berichten') ?></span
               <span class="next"><?php previous_posts_link('Nieuwe Berichten') ?></span>

            </div>
            <?php endif; ?>
sillie83
 
Posts: 3
Joined: Thu Jun 24, 2010 11:11 am

Re: Introducing Quicktags (qT 2.1 and higher)

Postby mll » Sat Jul 10, 2010 5:30 pm

hi everyone;
im using of a template that has a custom menu , i tried to add quicktags for showing the name of menu but it showed me everything that i add ...

i added this :
[:en]contactus[:ku]پیوندی

the menu showed me :
[:en]contactus[:ku]پیوندی

this menu save everything in database and read them from there ...

help me please i need that menu ...
mll
 
Posts: 2
Joined: Sat Jul 10, 2010 5:25 pm

Re: Introducing Quicktags (qT 2.1 and higher)

Postby mll » Sat Jul 10, 2010 8:58 pm

willy wrote:Hi
sorry for my bad english
I Need make two links en my rss widgets
1 for español rss
2 for english

Im try to make tag en fiel ( Enter the RSS feed URL here:)

[:en]http://rss.news.yahoo.com/rss/eurobiz[:es]http://rss.cnn.com/rss/money_latest.rss

but no working

PLEASE I NEED HELP!!!

i have a same problem :?
mll
 
Posts: 2
Joined: Sat Jul 10, 2010 5:25 pm

Re: Introducing Quicktags (qT 2.1 and higher)

Postby cmode » Tue Aug 03, 2010 10:39 pm

I am new to qTranslate and understand the concept of adding quicktags to fields in WP to translate text.
But, I don't know how to translate when inside a php language file. I'm using the WP e-commerce plugin,
and there is certain text generated through the wp-e-commerce/languages/EN_en.php file.

For example, I wanted to be able to use qTranslate to translate "Visit the shop" into Spanish:
define('TXT_WPSC_VISITTHESHOP', 'Visit the shop');

Of course, quicktags don't work inside ' '. Any ideas of how I should go about it?
cmode
 
Posts: 2
Joined: Tue Aug 03, 2010 10:24 pm

Re: Introducing Quicktags (qT 2.1 and higher)

Postby PArtu » Thu Sep 02, 2010 2:14 pm

Hi,
Is there a common reason why my all quicktags disapear when I change something in widgets?
They are gone and only one default language stays, no quicktags present anymore.
Thanks,
Artur
PArtu
 
Posts: 2
Joined: Thu Sep 02, 2010 2:01 pm

Re: Introducing Quicktags (qT 2.1 and higher)

Postby Qian Qin » Fri Sep 10, 2010 7:58 am

cmode wrote:I am new to qTranslate and understand the concept of adding quicktags to fields in WP to translate text.
But, I don't know how to translate when inside a php language file. I'm using the WP e-commerce plugin,
and there is certain text generated through the wp-e-commerce/languages/EN_en.php file.

For example, I wanted to be able to use qTranslate to translate "Visit the shop" into Spanish:
define('TXT_WPSC_VISITTHESHOP', 'Visit the shop');

Of course, quicktags don't work inside ' '. Any ideas of how I should go about it?


wp-e-commerce uses a different concept, you will need to download a language pack or something for it.
Qian Qin
Site Admin
 
Posts: 964
Joined: Thu Jun 19, 2008 12:14 pm
Location: Germany

Re: Introducing Quicktags (qT 2.1 and higher)

Postby Proglot » Tue Sep 21, 2010 1:33 am

hi, everybody!
i'm using wordpress mu + buddypress and have one problem: tabs on buddypress does not translated, for example file wp-content\plugins\buddypress\bp-groups.php:
Code: Select all
bp_core_new_subnav_item( array( 'name' => __( 'My Groups', 'buddypress' ), 'slug' => 'my-groups', 'parent_url' => $groups_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_my_groups', 'position' => 10, 'item_css_id' => 'groups-my-groups' ) );


i tried:
Code: Select all
bp_core_new_subnav_item( array( 'name' => _e( '[:en]My Groups[:ru]Moi gruppi[:uk]Gruppalar' ), 'slug' => 'my-groups', 'parent_url' => $groups_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_my_groups', 'position' => 10, 'item_css_id' => 'groups-my-groups' ) );

but it's not worked.

is there another way?
how can i change, to translate? plz help!
Proglot
 
Posts: 4
Joined: Mon Aug 16, 2010 12:53 am

Re: Introducing Quicktags (qT 2.1 and higher)

Postby Proglot » Thu Sep 23, 2010 11:43 pm

i solved my problem. I did as it is written here:
Frankx7 wrote:I had the same problem and I made a fix
Please note this fix will only work if you have the "URL Modification Mode" option set to "Use Pre-Path Mode (Default, puts /en/ in front of URL)".

In the file: qtranslate/qtranslate_core.php
at around line #83, there should be this:
Code: Select all
$q_config['language'] = $q_config['url_info']['language'];

Replace it with the following code
Code: Select all
$languagelist = qtrans_getSortedLanguages();
for($i=0;$i<count($languagelist);$i++) {
   $languagelist[$i] = "/".$languagelist[$i]."/";
}
if($_COOKIE["WEBSITELANGUAGE"] == "" || in_array(substr($_SERVER["REQUEST_URI"],0,4),$languagelist)) {
    $q_config['language'] = $q_config['url_info']['language'];
} else {
    $q_config['language'] = $_COOKIE["WEBSITELANGUAGE"];
}
setcookie("WEBSITELANGUAGE", $q_config['language'], mktime(0,0,0,date("m"),date("d"),date("Y")+2),"/");

Basicly it checks if in the url, there is a language (/en/ at the begining), if it is there, it will use that one and set a cookie
If there is no language in the url, it will use the default language for first time visitors, and then use the cookie

Hope this helps other people
Frank


and changed my code like this:
Code: Select all
if($_COOKIE["WEBSITELANGUAGE"] == "en")
bp_core_new_subnav_item( array( 'name' => __( 'My Groups', 'buddypress' ), 'slug' => 'my-groups', 'parent_url' => $groups_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_my_groups', 'position' => 10, 'item_css_id' => 'groups-my-groups' ) );
elseif($_COOKIE["WEBSITELANGUAGE"] == "ru")
bp_core_new_subnav_item( array( 'name' => __( 'Мои группы', 'buddypress' ), 'slug' => 'my-groups', 'parent_url' => $groups_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_my_groups', 'position' => 10, 'item_css_id' => 'groups-my-groups' ) );
elseif($_COOKIE["WEBSITELANGUAGE"] == "uk")
bp_core_new_subnav_item( array( 'name' => __( 'Мин бөлөхтөрүм', 'buddypress' ), 'slug' => 'my-groups', 'parent_url' => $groups_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_my_groups', 'position' => 10, 'item_css_id' => 'groups-my-groups' ) );

i dont deleted __( 'text', 'buddypress'), whatever is working .
Proglot
 
Posts: 4
Joined: Mon Aug 16, 2010 12:53 am

Re: Introducing Quicktags (qT 2.1 and higher)

Postby awared » Fri Dec 17, 2010 9:16 pm

Hi. I am trying to have html subscription form that automatically sets the default value of the
textfield according to the language. However no matter what tag I try I'm ending up with a

Code: Select all
'); ?>


at the end and any php code after that gets printed like html.
I think /> is the cause of this. I am ready to initiate the <hitting head against keyboard> process.
Here is the list of codes I already tried:

Code: Select all
<?php if (get_bloginfo('language')=='fa-IR') {
echo "language: <input type='text' VALUE="; echo '"Farsi"'; echo "name='language' /><br/> ";} ?>


Code: Select all
<?php _e('[:en] echo"<input type='text' value='English' name='language' />";  [:fa] echo"<input type='text' value='فارسی' name='language' />"; ');?>


Code: Select all
<?php _e("<!--:en--><input type='text' value='English' name='language' /><!--:--><!--:fa--><input type='text' value='فارسی' name='language' /><!--:-->"); ?>


I also tried this:
Code: Select all
<?php
    $stren= "<input type='text' value='English' name='language' />";
    $strfa= "<input type='text' value='Farsi' name='language' />";

_e('[:en] echo htmlentities($stren);  [:fa] echo htmlentities($strfa); ');?>
awared
 
Posts: 5
Joined: Sun Nov 28, 2010 2:44 pm

Re: Introducing Quicktags (qT 2.1 and higher)

Postby lilibird » Tue Jan 18, 2011 4:45 pm

hello,
this is a good good plugin ! After so many try, this is this only one wich is easy and really usable for a newbie like me !

I just have a few little troubles and may be someone could help me to finish the installation of qtranslate.

I try to use "full" and "short" tag in a dedicated place in arras theme and it does'nt work...
Idem for widget title (qt 2.5)

In fact It works in english but the translate in french look like this : (English) English
instead of the translation : Français

I had try this :
[:en]English[:fr]Français
and this :

<!--:en-->English<!--:--><!--:fr-->Français<!--:-->

And the result is idem...

tath means the tag is active but something wrong happened ...

Do I missed something ?

My second problem is : I upload the fr_FR.mo and .po for arras theme , but I don't understand how activate the translation of my theme... With wordpress location I found it in the right place with the right tranlation, but I imagine I have some code to do ? Arras is compatible with qtranslate, I found those line in function.php :
// Remove filter on theme options if qTranslate is enabled
if (function_exists('qtrans_init')) {
remove_filter('option_arras_options', 'qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage', 0);
}

Well, if someone has a few minuts for me, welcome !
lilibird
lilibird
 
Posts: 3
Joined: Tue Jan 18, 2011 4:11 pm

PreviousNext

Return to qTranslate Support Forum

Who is online

Users browsing this forum: Google [Bot], Google Adsense [Bot] and 5 guests