1
nachenko
Fastest Cache Hack and phppp's XLanguage
  • 2007/6/7 15:35

  • nachenko

  • Quite a regular

  • Posts: 356

  • Since: 2005/1/18


Hi.

I just installed Gijoe's Fastest Cache Hack in runs amazingly fast.

But it has problems with multi language sites. The problem is that the cache doesn't read language cookie, so doesn't make a difference between a page in english and same page in spanish. It simply serves the page it has in the cache, no matter what says visitor's language cookie.

An easy solution: use an apache rewriting rule to include language:

But I have two problems:

1 - Can Apache read cookies via .htaccess file?
2 - How do I write the rewriting rule so that it includes the language variable in a GET? COnsider that sometimes the text to be inserted will be...

Quote:
?lang=english

and sometimes it will be...

Quote:
& lang=english

Depending on whether there are other GET variables or not.