Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Header configuration & styling »

Different logo with different language


  #1  
Old Oct 31, 2009, 11:27 AM
madfab685
 
15 posts · Aug 2009
Hello there,

I need to have 2 differents logos depending on the language (english or french). I am working with qtranslate and I thought I was able to insert something like the following.

<?php _e('[lang_en]logo1.png[/lang_en][lang_fr]logo2.png[/lang_fr]') ?>

I thought I could simply add this code directly where it says "show logo image?"

Can anybody help me on this?

Many thanks

Fabrice
  #2  
Old Nov 2, 2009, 04:28 AM
juggledad's Avatar
juggledad
 
23,682 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
in ver 3.4.4 edit bfa_header_config.php and locate lines148-152 which are
HTML Code:
     // if this is Wordpress and not WPMU, print the logosymbol.gif in the theme folder right away
     } else { 
       $logo_area .= $bfa_ata['template_directory'] . '/images/' . $bfa_ata['logo'] . '" alt="' . 
       $bfa_ata['bloginfo_name']; 
     } 
and change them to
HTML Code:
   // if this is Wordpress and not WPMU, print the logosymbol.gif in the theme folder right away
   } else { 
     $logo_area .= $bfa_ata['template_directory'] . '/images/'
     $logo_area .= _e('[lang_en]logo1.png[/lang_en][lang_fr]logo2.png[/lang_fr]')
     $logo_area .=  '" alt="' . $bfa_ata['bloginfo_name']; 
   } 
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old Nov 3, 2009, 03:36 PM
madfab685
 
15 posts · Aug 2009
Hi Juggledad,

Thanks for your help. It did not work because I am not sure about my code.
I went back on the qtranslate forum and I saw something like this:
<?php if (qtrans_getLanguage() == 'en') : ?>english html here<?php else : ?>french html here<?php endif; ?>

Any chance to embed this ?

Thanks again
  #4  
Old Nov 3, 2009, 06:05 PM
juggledad's Avatar
juggledad
 
23,682 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
you can try this - you need to come up with the html inserts for both english and french
HTML Code:
  // if this is Wordpress and not WPMU, print the logosymbol.gif in the theme folder right away
   } else { 
     $logo_area .= $bfa_ata['template_directory'] . '/images/'
     if (qtrans_getLanguage() == 'en') : $lang_logo = 'english html here' 
     else : $lang_logo = 'french html here' endif;
     $logo_area .= $lang_logo
     $logo_area .=  '" alt="' . $bfa_ata['bloginfo_name']; 
   }
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #5  
Old Nov 4, 2009, 02:32 PM
madfab685
 
15 posts · Aug 2009
Hi Juggledad

I tried to sort it out but my knowledge is limited. Apparently the qtranslate function needs to be declared somewhere. I don't want to bother you more with my problem.

Thanks again
MadFab685
  #6  
Old Dec 4, 2009, 10:36 AM
kyriakos
 
1 posts · Dec 2009
That's some months ago but you guys helped me out a lot with what you wrote...

Mad, the key lies in your code actually.
You edit the header.php and look for

<div id="header">
<div id="header-left">
there you get something like :

<a href="<?php bloginfo('url'); ?>"><img src=" SOMETHING " ETC ETC>

hopefully (I'm quite new with WP, so I hope that's the same with every theme etc.)

in the src for the img you write, that is within the " ":

<?php if (qtrans_getLanguage() == 'en') : ?><?php bloginfo('stylesheet_directory'); ?>/images/logoENG.gif<?php else : ?><?php bloginfo('stylesheet_directory'); ?>/images/logo.gif<?php endif; ?>

where logoENG.gif is your english logo and logo.gif is your french one (I gather you have French as default...)

anyway, a nice one for anybody looking for something like this...

Bookmarks

Tags
language, logo, qtranslate

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Other language Newgamer Languages & Translations 13 May 24, 2010 12:10 PM
Language Switcher and Atahualpa 3 arnaud Plugins & Atahualpa 19 Sep 17, 2009 07:57 AM
xili-language plugin atunoa Plugins & Atahualpa 1 Jul 14, 2009 06:06 PM
Switch positions of logo and search box? Logo on right side DogBot Header configuration & styling 1 Jun 12, 2009 10:17 AM
How change language Diego Velazquez Languages & Translations 17 May 11, 2009 02:58 PM


All times are GMT -6. The time now is 02:32 AM.


Powered by vBulletin® Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.