Jump to content

Recommended Posts

Hi,

I don't know if this is even possible, but I need to copy configuration of existing server to my localhost (using XAMPP on windows). I only have full output of phpinfo() function from that server (I don't have access to php.ini), and I would like to change my localhost server to behave exactly like remote one. 

Is this even possible? 
Is there some more "automatic" solution, than just going through bunch on lines of code and trying to change them?
Furthermore, remote server has much longer configure command, as well as list of additional .ini files parsed... how to change these?

if php can read it to load it, you can read it to make a copy -

<?php
$in_file = 'C:\xampp\php\php.ini'; // path to the php.ini, can be found in the phpinfo() output under - Loaded Configuration File
$out_file = 'ini.org';

file_put_contents($out_file,file_get_contents($in_file));

 

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.