PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Monday, February 7, 2022

[FIXED] Loading php extension for specific domain only

 February 07, 2022     apache, lamp, php     No comments   

Issue

I have a dedicated LAMP server with more than one domains hosted. I want to load a php extension only for a single domain. Is it possible?


Solution

Edit your VirtualHost configuration.

Make a copy of php.ini file. Add the extension you need in there. Store it in separate directory.

Use PHPIniDir in your config for the particular site and point to that new dir, containing new php.ini

Restart apache.

Your config will be loaded and will use separate php.ini file.



Answered By - Anatoliy Kim
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing