Hello everyone,

First of all, I'd like to say how happy I am with Drupal. I've been trying many CMS solutions for setting up my little webpage, and Drupal was the only one able to produce what I wanted. Fast, efficient, customizable. Really, thanks a lot, guys.

However, I'm still a total newb and I'd like your help regarding a small issue. I publish content in several languages on the same site, and I'd like the visitor to quickly see in which language a given node is written by displaying a little flag icon right after its menu entry. The icon would be chosen depending on the item selected in the "Language" vocabulary (using the taxonomy module). I'm pretty sure this is possible with Drupal, but I just fail to find how. I've looked at the forum archives, grepped "href" in the source to find which function I could overload, without success. So I'd be really grateful if someone could point me to how to do that (supposedly, editing template.php and overloading the right function?).

I suppose what I want to do can be achieved easily with the i18n module, but my nodes are either in one language or another (i.e. there are no node translations), and I'd like to have nodes of both languages in the same page. So I wouldn't like to have different URL templates (for instance: en/node/xx and fr/node/xx) that would just point to the exact same content. It would be a little confusing. However, if I can keep URL consistency, I'm also interested in solutions involving the i18n module (especially if I can choose the right locale for the interface according to the taxonomy if the current node).

Well, I hope my question is clear. Thank you in advance for any help!
Alex.

Comments

ckeo’s picture

http://www.nicklewis.org/node/843

hope that helps,
Craig.

Anonymous’s picture

Great - that should do the trick. Thanks a lot!

Now maybe I've reached the limits of what is possible here, but would there be a way to generalize this to ALL the links of the site? (including links in nodes) I'm not sure at all about this one because this seems beyond the scope of PHPTemplate. Anyway, I could still do it manually by setting the right class for the right link.

ckeo’s picture

I havnt actually used this method... but im sure it could do that.

Craig.