473,396 Members | 1,924 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Using my own php.ini

170 100+
Hello all,

I read up on the ability to place my own php.ini file in my web folder's directory, which is supposed to override the standard php.ini file. But it still seems to be using the standard one. Is there any setting I'm supposed to change somewhere for php to use my ini file?

Thanks
Jun 10 '08 #1
5 1236
r035198x
13,262 8TB
Run the phpinfo script
Expand|Select|Wrap|Line Numbers
  1. <?php phpinfo(); ?>
and check near the top of the first table there which php.ini is being used by your php engine. You'd then need to override the file in that location with yours.
P.S Don't forget to back up the old one first before overriding it.
Jun 11 '08 #2
beary
170 100+
Run the phpinfo script
Expand|Select|Wrap|Line Numbers
  1. <?php phpinfo(); ?>
and check near the top of the first table there which php.ini is being used by your php engine. You'd then need to override the file in that location with yours.
P.S Don't forget to back up the old one first before overriding it.
Hey there r035198x,

I've done that already and it's definitely using the standard one. The thing is, apparently it's possible to keep the standard one in the normal place, but put a different one in your own web directory.

So, the main one is in /etc/php5/apache2 but my website is in /var/www/html/mysite. Obviously for security I can't get into /etc/php5/apache2 anyway, so I need to place my php.ini file into var/www/html/mysite, which I can do (and have done).

But my question is how do I then tell php to use the php.ini file in var/www/html/mysite, whenever pages in the mysite directory are being loaded?
Jun 11 '08 #3
r035198x
13,262 8TB
Did you restart the web server?
Jun 11 '08 #4
Markus
6,050 Expert 4TB
I think it would be rather stupid if you could just upload your own php.ini to a website and have it override the original one.

Unless you have access to the orignal one, I don't think you can change it.
Jun 11 '08 #5
r035198x
13,262 8TB
I think it would be rather stupid if you could just upload your own php.ini to a website and have it override the original one.

Unless you have access to the orignal one, I don't think you can change it.
See the documentation for it here. You can even put it in the directory containing your script.
Jun 11 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Enos Meroka | last post by:
Hallo, I am a student doing my project in the university.. I have been trying to compile the program using HP -UX aCC compiler, however I keep on getting the following errors. ...
3
by: Mike L | last post by:
Should the command call "using" be before or after my namespace? **AFTER** namespace DataGridBrowser { using System; using System.Drawing; using System.Drawing.Drawing2D; using...
3
by: xzzy | last post by:
I was wondering why we have to have using System.Data using System.Configuration using etc.... why are they not all lumped into one 'using'? In other words, is there a best way to use...
14
by: pmud | last post by:
Hi, I need to use an Excel Sheet in ASP.NET application so that the users can enter (copy, paste ) large number of rows in this Excel Sheet. Also, Whatever the USER ENETRS needs to go to the...
8
by: acb | last post by:
Hi, I wrote a DLL Component (using Visual Studio 2005) and managed to include it into a C# Console application. I am now trying to include this component into a Web project. I copy the DLL...
0
by: Metal2You | last post by:
I'm working on an ASP.NET 2.0 application in Visual Studio 2005 that accesses a Sybase database back end. We're using Sybase SQL Anywhere 9.0.2.3228. I have installed and registered the Sybase...
10
by: mg | last post by:
I'm migrating from VB6 and have a question about using 'Using' and the best way to use it. Here is a example of a small bit of code: dbConx("open") Using CN Dim CMD As New OleDbCommand(sSQL,...
0
by: Eugene Anthony | last post by:
The problem with my coding is that despite removing the records stored in the array list, the rptPages repeater control is still visible. The rptPages repeater control displayes the navigation...
3
by: JDeats | last post by:
I have some .NET 1.1 code that utilizes this technique for encrypting and decrypting a file. http://support.microsoft.com/kb/307010 In .NET 2.0 this approach is not fully supported (a .NET 2.0...
6
by: =?Utf-8?B?U2hhd24gU2VzbmE=?= | last post by:
Greetings! I was researching AJAX to provide a solution to displaying status messages while a long process executed. I found several examples online and was able to use their code to get a quick...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.