View Complete Thread
  • DropPhone DropPhone

    360 Posts

    Microsoft

    Moderator

    Re: One Site, two version of PHP and Wincache

    Aug 27, 2014 12:26 PM|DropPhone|LINK

    One addendum to this discussion:

    Since I first posted my response, I've learned there *are* tricks to getting two versions of PHP to work within the same worker process.

    It turns out you can have different handler mappings per web.config file.  And you can put a web.config file in any directory in your web site.  So, you could have two sub-directories in your site, with a different handler mapping for "*.php".  To do this, however, you have to change the overrideModeDefault for the "handlers" section to "Allow", and there is some danger in doing so, esp. if you're a hoster.  However, it *is* possible.

    Here's the trick to getting two different Wincache versions to safely ignore each other: You *must* set the Wincache.namesalt setting in the php.ini file, and the value of the namesalt *must* be unique for each version of PHP + Wincache you have installed on the box.  So, let's say you had two installed versions of PHP 5.4.* installed on the server; for example, different dot releases.  Even if they're using the same Wincache version, you'd still want to set the Wincache.namesalt in each of the php.ini files to a different value. 

    Thx!

        --E.

    See: http://php.net/manual/en/wincache.configuration.php#ini.wincache.namesalt