Page 1 of 1

Logo image change in different language option

Posted: Thu Sep 30, 2010 9:40 am
by gopi_joomla123
Hi friends,

i have used in multilingual language used in joomfish component. English and Tamil. How to change the logo image in two different language. Please give me the solution.


MY CODE html code:
<div id="header">
<h1><a href="#">Example Company Name</a></h1>
</div>
css:
#header h1 a {background:url("../../images/en/logo.png") no-repeat scroll left top;}

Any solution guys...

Re: Logo image change in different language option

Posted: Thu Sep 30, 2010 4:53 pm
by ooffick
You could do something like this:

Open you template's index.php file and search for the following line:

Code: Select all

<div id="header">
Try to replace it with this code:

Code: Select all

<?php 
$lang =& JFactory::getLanguage();
if($lang->getTag() == 'en-GB'): ?>
<div id="header_en">
<?php else: ?>
<div id="header">
<?php endif; ?>
and then use the following code in the css file:

Code: Select all

#header_en h1 a {background:url("../../images/en/logo.png") no-repeat scroll left top;}
#header h1 a {background:url("../../images/en/otherlogo.png") no-repeat scroll left top;}
Olaf

Re: Logo image change in different language option

Posted: Tue Oct 05, 2010 10:45 am
by gopi_joomla123
ooffick wrote:You could do something like this:

Open you template's index.php file and search for the following line:

Code: Select all

<div id="header">
Try to replace it with this code:

Code: Select all

<?php 
$lang =& JFactory::getLanguage();
if($lang->getTag() == 'en-GB'): ?>
<div id="header_en">
<?php else: ?>
<div id="header">
<?php endif; ?>
and then use the following code in the css file:

Code: Select all

#header_en h1 a {background:url("../../images/en/logo.png") no-repeat scroll left top;}
#header h1 a {background:url("../../images/en/otherlogo.png") no-repeat scroll left top;}
Olaf

I got the results thanks for your help.

Re: Logo image change in different language option

Posted: Tue Oct 05, 2010 11:25 am
by weichhold
it was a super help for me!! thanks oofkick!

Re: Logo image change in different language option

Posted: Mon Jan 09, 2012 11:41 am
by NicolaCards
Hi, I am not a css master... I have a similar problem: I want to customize the logo header according to the language.
I am using a beez_20 template with some customization...
The image is in this part of the personal.css file

#all #header
{padding-top:1.0em ;
}
.logoheader
{
background: #fff URL(../images/personal/personal2.png) no-repeat bottom right ;
color:#660000;
min-height:250px;
margin:0em 0px 0 10px !important;
}

How can I refer to this and apply what you suggested? I beleive this is a slightly different context....
Thank you in advance
Nicola

Re: Logo image change in different language option

Posted: Mon Jan 09, 2012 11:44 am
by NicolaCards
...and let me add what I found in the template's index.php file


<div id="all">
<div id="back">
<div id="header">
<div class="logoheader">
<h1 id="logo">

<?php if ($logo): ?>
<img src="<?php echo $this->baseurl ?>/<?php echo htmlspecialchars($logo); ?>" alt="<?php echo htmlspecialchars($templateparams->get('sitetitle'));?>" />
<?php endif;?>
<?php if (!$logo ): ?>
<?php echo htmlspecialchars($templateparams->get('sitetitle'));?>
<?php endif; ?>
<span class="header1">....
etc.

Re: Logo image change in different language option

Posted: Tue Oct 28, 2014 10:21 am
by joaojoomla
Hi Oofick,
I follow the procedure, cause I had the same doubt and it all went well. But I had to write the css in the html file I don't know why, but it is working.

I have another question. In this site www.date.pt as you can see in the fotter I have "Termos e Condições" and "Política de Privacidade". This was created by default on the backoffice template.

But now I have a site in english, but I can't change the name of the links "Termos e Condições" and "Política de Privacidade" to the english site version. I created the categories and the articles for the english site version, but the links remain in portuguese (I think it is because it's made by de Joomla backoffice). How is it possible to solve this situation?

Thanks