I'm using the language switcher block and noticed that when I used the Marina theme it no longer works properly. Specifically I have two languages and the language picker's first language is no longer and active link, while the second language in the list is working properly as an active link.
So users can switch to the second/last language in the list but cannot switch back by clicking on the first language in the language switcher block because it is not an active link.
Here's the HTML block that's being generated. Not sure if it's important but you can see that the first list item is not labeled as 'active' but the second list item is:
<ul>
<li class="en first">
<a class="language-link" href="/drupal/">
<img class="language-icon" width="16" height="12" alt="English" src="/drupal/sites/all/modules/languageicons/flags/en.png"/>
</a>
</li>
<li class="ja last active">
<a class="language-link active" href="/drupal/ja">
<img class="language-icon" width="16" height="12" alt="日本語" src="/drupal/sites/all/modules/languageicons/flags/ja.png"/>
</a>
</li>
</ul>
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | Screen.png | 4.35 KB | Anonymous (not verified) |
Comments
Comment #1
Anonymous (not verified) commentedI found the 'cause', this line in block.tpl.php
block.tpl.php:19:
<div class="block-icon pngfix"></div>If I remove that line the problem goes away. I'm not sure if I am introducing any new problems though :( I unfortunately don't have IE6 to test with
Comment #2
jwolf commentedPlease provide a link to "the language switcher block" module so that we can look into this issue.
Identifying the languages you are using would help too.
Also, screenshots and/or links to the site of where this can be reproduced would help.
The more details you provide the more likely we can troubleshoot this issue.
Comment #3
Anonymous (not verified) commentedHi and thanks for following up.
The language switcher block is part of Core (I think it's provided by Locale). I'm using English and Japanese but I don't think the actual languages used matter since the problem is with the HTML of the links. And also as pointed out the page renders fine in Opera but not Firefox.
You can see the problem (if you use Firefox) at the site below (might not be there for long though)
http://www.cachekuni.com/drupal
Notice that if you put the cursor *anywhere* on the Japanese flag it acts as a link. However if you try this with the English flag, you only get a link at the very bottom/under the flag. Putting the cursor in the middle of the flag doesn't work as a link.
Would post a screen shot but I can't get the pointer to show up when I take a screen shot in Opera. I'm including a screen shot of Firefox showing the 'hand' pointer is not showing on the UK flag but is when on the Japanese flag.
Comment #4
jwolf commentedUpdating version info:
Fusion version has been moved to 3.x
Comment #5
Anonymous (not verified) commentedComment #6
jeremycaldwell commentedHi totsubo, can you try adding this bit of CSS to your theme?
For some reason that seems to fix the local language block switcher for me in FireBug.
Comment #7
dddave commentedHi folks,
I can confirm the misbehaviour described by totsubo and more importantly confimr that the code from #6 makes the language switcher work fine again.
Comment #8
jeremycaldwell commentedChanges have been made to the theme and will be in the next release. Thanks for testing this out too.
Comment #9
jeremycaldwell commentedFixed in the Alpha 2 release.
Comment #10
druplicate commentedThis causes the icon to disappear in the language switcher block using Firefox 3.5.7, and the AM alpha -2 release.
In Firebug I disabled that line and the icon reappeared.
Comment #11
dddave commentedI can confirm that I cannot get a Block Title Icon but the language switcher and the language icons are working fine.
@10: Do the language icons still work after deleting the line?
Comment #12
druplicate commentedYes, I disabled the line in Firebug and the icon reappeared.
Comment #13
dddave commentedOk, that is really weired.
I removed the line that should make the language switcher block work fine (#6) and now I get the block title icon AND the switcher icons+links work fine as well. It seems that the "fix" is no longer needed. I cannot make out if this is due to the fact that I now am using language icons 2.0 or some other changes in AM3, Fusion or skinr.
So it seems that this fix can be rolled back...
Comment #14
jeremycaldwell commentedThanks for all the testing and feedback dddave and druplicate. I removed the ".block-locale .block-icon" code as it's not needed anymore and seems to be working correctly now. Will get this change into the next release of the theme.
Comment #15
droshani commentedPlease consider to look at this issue as well,
http://drupal.org/node/688280
Thanks
Comment #16
jensensi commentedIt sounds like we are having a similar problem, but can’t get it to work.
We are using Burnt Rubber theme with 2 languages – Danish (default) and English. In IE8 it works perfectly switching between languages and pages, but in FF it will only show English pages, except when you type the specific node ID in the URL (e.g. node/5). It shows the correct links when you use all roll over the languages and menu items, but keeps showing the English version of the pages.
When you specifically switch to a Danish page and roll over the Danish menu items, it shows the links with their node ID, not the defined path settings.
I have tried the code in #6, but it doesn’t do anything. Help!
Comment #17
jeremycaldwell commentedFixed in the beta release of the theme.