On Sun, 2009-11-08 at 22:04 -0800, leledumbo wrote: > I need to create a multilingual website and my framework already gives me > that facility. However, I also use JavaScript quite extensively and since > XHTML 1.0 Strict doesn't allow inline script, I must use external .js file. > The problem is in these scripts, there are strings that needs to be > translated as well. How can I make PHP parse these scripts as well? Or are > there alternative approaches? > > -- > View this message in context: http://old.nabble.com/Multilingual-website%2C-texts-in-external-JavaScript-problem-tp26261666p26261666.html > Sent from the PHP - General mailing list archive at Nabble.com. > > You could either use several different Javascript files to hold the language translations and just those as variables, and then in the main Javascript use the variables rather than the actual words. Or you could store all the translations into a Javascript array and refer to the specific array element you need to output Thanks, Ash http://www.ashleysheridan.co.uk