[SOLVED] Link a flag to an external site / URL

This is a FORK of the CMS Made Simple project and is not oficially supported in any way by the CMS Made Simple development team.
Locked
User avatar
jswags
Forum Members
Forum Members
Posts: 15
Joined: Tue Dec 11, 2007 1:57 pm

[SOLVED] Link a flag to an external site / URL

Post by jswags »

Hello,

I'd like to add two additional flags USA and China to my current MLE install. However these flags need to link to different external URL's, not internal language pages within the CMSMS install.

So the obvious place to start is the config_lang.php and add in the appropriate code for USA and Chinese flag images, alt text etc.

Is there a way I can set up an absolute URL for each flag within config_lang.php that will go to "http://www.google.com" for example? Or could I set up a re-direct?

The other obvious option is to just add the flag images and hard code the URL within my template but I'd prefer to keep it contained within one place for neatness.

I'm using Version 1.2.3 of CMSMS MLE
Thanks
Jason
Last edited by jswags on Mon Dec 07, 2009 10:48 am, edited 1 time in total.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Link a flag to an external site / URL

Post by Dr.CSS »

Doesn't seem to make much sense to use MLE and then have the lang flags go to something other than the internal cmsms pages...

You might as well just call the flag images and hard code the links...
User avatar
jswags
Forum Members
Forum Members
Posts: 15
Joined: Tue Dec 11, 2007 1:57 pm

Re: Link a flag to an external site / URL

Post by jswags »

Thanks for the replay and yep I see your point and that's my option 2  :)

I just wondered if it was possible because it's an MLE install already set up with five languages and adding two additional languages via the config_lang.php with a line of code to redirect would have been neat and simple - rather than updating multiple templates.

So if someone else needs to do this just add (using USA flag as an example):

Code: Select all

<a href="http://www.externalURL.com" target="_blank"><img src="/images/lang/en_US.png" alt="USA" width="18" height="12" /></a>
below your {lang} tag within each Template you may have.
Last edited by jswags on Mon Dec 07, 2009 10:48 am, edited 1 time in total.
Locked

Return to “[locked] CMSMS MLE fork”