Search Results

Search found 1315 results on 53 pages for 'ini'.

Page 8/53 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • mb_internal_encoding() not available though configured?

    - by Jonas Byström
    I'm having problem with mbstring in my Apache2.2/Win7/PHP5.3 setup, though I think it's correctly configured in my php.ini: extension_dir = "ext" extension=php_mbstring.dll I get the following: Fatal error: Call to undefined function mb_internal_encoding() in ... I did a manual installation (by the book) using the VC6 .zip. I'm running out of ideas of what to try.

    Read the article

  • including files without having to specify $_SERVER['DOCUMENT_ROOT']

    - by pâtissier
    Hi... Before the PHP Version update I used to be able to include files as following without specifying the document root: <?php include '/absolute/path/to/files/file1.php'; ?> However I now have to include the same file as following: <?php include $_SERVER['DOCUMENT_ROOT'].'/absolute/path/to/files/file1.php'; ?> What php.ini setting could have overridden the former behaviour?

    Read the article

  • Problem making system calls with PHP scripts

    - by mazin k.
    I have the following PHP script: <?php $fortune = `fortune`; echo $fortune; ?> but the output is simply blank (no visible errors thrown). However, if I run php -a, it works: php > echo `fortune`; Be careful of reading health books, you might die of a misprint. -- Mark Twain php > Am I missing a config directive or something that would cause this? Edit: So, I tried running my script using $ php-cgi fortunetest.php and it worked as expected. Maybe the issue is with Apache2?

    Read the article

  • error in php not logging or displaying

    - by Grant M
    I can not get any errors to display on screen on write to a log file. When check phpinfo() print out I have same value of master a local for display_errors On display_startup_errors On error_log /var/log/php.log error_reporting E_ALL & ~E_NOTICE log_errors On log_errors_max_len ls -l /var/log/php.log is -rw-rw-rw- 1 root root 0 Jun 21 07:47 /var/log/php.log for /var and /varlog drwxrwxrwx 23 root root 4096 Jun 2 11:13 var when there is an error in the code the page the browsers shows nothing and browser says there is no source for the page. Any suggestions of where else to look or change to errors to appear somewhere (anywhere would be good) edit: my error script is now <?php ini_set('display_errors', 1); error_reporting(E_ALL); echo "print from error.php 2 "; error //print from erroerror to cuase logging to happen. ?> this will print on display and to log Notice: Use of undefined constant error - assumed 'error' in /var/www/piku_dev2/error.php on line 7 but if I put garbage like #@$%$ on the error line I get nor error messages anywhere. Edit2: The problem turned out to in the httpd.conf file. I don't know what it was yet as it was fixed y someone else.

    Read the article

  • Issues after upgrading the servers PHP version

    - by Harish Kurup
    I have created my project in Symfony 1.4.8 with Propel ORM. previously server had PHP version 5.2.* and i have upgraded it to 5.3.4, then the problem started giving some error in Propel. the errors were, PHP Deprecated: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0 PHP Fatal error: Class 'PDO' not found in /usr/local/lib/php/symfony/plugins/sfPropelPlugin/lib/vendor/propel/util/PropelPDO.php on line 42 PHP Warning: Module 'PDO' already loaded in Unknown on line 0 PHP Warning: Module 'pdo_sqlite' already loaded in Unknown on line 0 PHP Warning: Module 'SQLite' already loaded in Unknown on line 0 Is there any config error that has to be taken care of?? please help!

    Read the article

  • CPU spikes on small site- possibly apache or php config related

    - by Mike
    Hello, I hope you can help me. I have a site that I'm moving to a new datacenter. The server is pretty much vanilla, no control panel, and also no optimizations. When I hit a page, the site takes an extremely long time to load, despite it being relatively light weight. I ran top to see what was happening, and the cpu jumps to 75%, and drops back down to about 20% while the rest of the page is loading. Someone suggested that I ran lsof -p on the offending processes, but I'm not sure what I'm looking at. I ran through my httpd.conf file and commented out a bunch of loaded modules that didn't seem necessary, but that didn't help either. Anyone have any ideas? Output of the lsof http://pastebin.com/mfa113f

    Read the article

  • Best way to handle PHP sessions across Apache vhost wildcard domains

    - by joshholat
    I'm currently running a site that allows users to use custom domains (i.e. so instead of mysite.com/myaccount, they could have myaccount.com). They just change the A record of their domain and we then use a wildcard vhost on Apache to catch the requests from the custom domains. The setup is basically as seen below. The first vhost catches the mysite.com/myaccount requests and the second would be used for myaccount.com. As you can see, they have the exact same path and php cookie_domain. I've noticed some weird behavior surrounding the line below "#The line below me". When active, the custom domains get a new session_id every page load (that isn't the same as the non-custom domain session). However, when I comment that line out, the user keeps the same session_id on each page load, but that session_id is not the same as the one they'd see on a non-custom domain site either despite being completely on the same server. There is a sort of "hack" workaround involving redirecting the user to mysite.com/myaccount, getting the session ID, redirecting back to myaccount.com, and then using that ID on the myaccount.com. But that can get kind of messy (i.e. if the user logs out of mysite.com/myaccount, how does myaccount.com know?). For what it's worth, I'm using a database to manage the sessions (i.e. so there's no issues with being on different servers, etc, but that's irrelevant since we only use one server to handle all requests currently anyways). I'm fairly certain it is related to some sort of CSRF browser protection thing, but shouldn't it be smart enough to know it's on the same server? Note: These are subdomains, they're separate domains entirely (but on the same server). <VirtualHost *:80> DocumentRoot "/opt/local/www/mysite.com" ServerName mysite.local ErrorLog "/opt/local/apache2/logs/mysite.com-error.log" CustomLog "/opt/local/apache2/logs/mysite.com-access.log" common <Directory "/opt/local/www/mysite.com"> AllowOverride All #php_value session.save_path "/opt/local/www/mysite.com/sessions" php_value session.cookie_domain "mysite.local" php_value auto_prepend_file "/opt/local/www/mysite.com/core.php" </Directory> </VirtualHost> #Wildcard (custom domain) vhost <VirtualHost *:80> DocumentRoot "/opt/local/www/mysite.com" ServerName default ServerAlias * ErrorLog "/opt/local/apache2/logs/mysite.com-error.log" CustomLog "/opt/local/apache2/logs/mysite.com-access.log" common <Directory "/opt/local/www/mysite.com"> AllowOverride All #php_value session.save_path "/opt/local/www/mysite.com/sessions" # The line below me php_value session.cookie_domain "mysite.local" php_value auto_prepend_file "/opt/local/www/mysite.com/core.php" </Directory> </VirtualHost>

    Read the article

  • wamp server REDIRECT_STATUS

    - by user143039
    I have noticed my remote server returns $_SERVER[REDIRECT_STATUS] with every request. Example: [REDIRECT_STATUS] = 200 But my localhost wamp server does not. Interestingly, when I manually set a header: Example: header('HTTP/1.1 302 Redirect This'); The variable: $_SERVER[REDIRECT_STATUS] is still not set. Though I can view the headers, including the one I set, with HttpFox. $_SERVER[REDIRECT_STATUS] is set when .htaccess throws(?) an ErrorDocument, like ErrorDocument 404 for example. Any ideas how to get wamp server to set the variable $_SERVER[REDIRECT_STATUS] with every request?

    Read the article

  • How do I activate SQLite3 on PHP 5.3.3 Centos 5?

    - by user58553
    I have reviewed the previous questions on this and they don't seem to cover what exactly I'm looking for, before I start, I'm no server admin. I'm trying to help get this server up and active and I have got it all going with exception to the SQLite3. The phpinfo displays '--without-sqlite' '--with-libxml-dir=/usr' '--enable-xml' '--with-system-tzdata' '--with-apxs2=/usr/sbin/apxs' '--without-mysql' '--without-gd' '--disable-dom' '--disable-dba' '--without-unixODBC' '--disable-pdo' '--disable-xmlreader' '--disable-xmlwriter' '--without-sqlite3' ' can somebody please advise in simple terms what to do to activate this, I've attempted a yum install. Thanks in advance, Sam

    Read the article

  • Installing PHP extensions in Debian

    - by Nick Sabatino
    I'm trying to install the PECL extension pecl_http so that I can use PHP's http_negotiate_language() function. I'm running PHP5 on Apache2 and Debian Lenny. I installed the php_http package from the debian repo, however, I still can't use that function in my php scripts! The package also doesn't show up under phpinfo(). I tried installing it from PECL, but I could not. Is there some procedure for enabling these extensions in PHP? Kind of like a2enmod for apache? Note: This is a repost from http://forum.slicehost.com/comments.php?DiscussionID=4650 I also tried adding extension=pecl_http.so to my apache2/php.ini with no effect. Any guesses?

    Read the article

  • How can I make PHP display the error instead of giving me 500 Internal Server Error

    - by Rob
    This has never happened before. Usually it displays the error, but now it just gives me a 500 internal server error. Of course before, when it displayed the error, it was different servers. Now I'm on a new server (I have full root, so if I need to configure it somewhere in the php.ini, I can.) Or perhaps its something with Apache? I've been putting up with it by just transferring the file to my other server and running it there to find the error, but that's become too tedious. Is there a way to fix this?

    Read the article

  • PHP - a different open_basedir per each virtual host

    - by Lopoc
    Hi I've came across on this problem, I have a sever running apache and php. We have many virtual hosts but we've noticed that a potentially malicious user could use his web space to browse other user's files(via a simple php script) and even system files, this could happens due to the php permissions. A way to avoid it is to set the open_basedir var in php.ini, yhis is very simple in a single host system, but in case of virtual hosts there would be a basebir per each host. Ho can I set dis basedir per each user/host? is there a way to let apache hereditate php privileges of the php file that has been requested E.G. /home/X_USER/index.php has as owner X_USER, when apache read the file index.php it checks its path and owner, simply I'm looking for a system set php basedir variable to that path. Thank in advance Lopoc

    Read the article

  • PHP does not return errors at all

    - by ErJab
    I am running PHP and nginx and I use a production version of php.ini. So the variable display_error is set to Off and there is a good reason I want it this way. But for certain files I need to enable error reporting. I used ini_set to turn on error reporting. But a simple code snippet like: <?php error_reporting(E_ALL); ini_set("display_errors", 1); echo "hi"errorrrrr ?> does not trace the error. It simply returns a HTTP 500 Internal Server Error message. What should I do to enable error reporting?

    Read the article

  • PHP+MYSQL Server Config

    - by Matias
    Hi guys, I am parsing an XML file with PHP and inserting the rows in a MYSQL database. I am using PHP simplexml_load_files to load the XML and a foreach to loop through the array and insert the rows into my database. It works perfectly fine with small files i am testing, but it comes to reality I need to parse a large 500mb XML file and nothing happens. I was wondering what was the right Php.ini config for this case ? I have a VPS Linux Cent OS, with 256 mb of dedicated Memory and MYSQL 5.0.5. I have also set php memory_limit = 256M (maximum of my server) Any suggestions, similar experiences will be greatly appreciated Thanks

    Read the article

  • PHP script stops running arbitrarily with no errors.

    - by RobHardgood
    I was working on a fairly long script that seemed to stop running after about 20 minutes. After days of trying to figure out why, I decided to make a very simple script to see how long it would run without any complex code to confuse me. I found that the same thing was happening with this simple infinite loop. At some point between 15 and 25 minutes of running, it simply stopped. There is no error output at all. The bottom of the browser simply says "Done" and nothing else is processed. I've been over every single possible thing I could think of... set_time_limit, session.gc_maxlifetime in the php.ini as well as memory_limit and max_execution_time. The point that the script is stopped is never consistent. Sometimes it will stop at 15 minutes, sometimes 22 minutes, sometimes 17... But it's always long enough to be a PITA to test. Please, any help would be greatly appreciated. It is hosted on a 1and1 server. I contacted them and they couldn't help me... but I have a feeling they just didn't know enough.

    Read the article

  • PHP: Using browscap.ini on shared host. - ini_set() failing

    - by GreybeardTheUnready
    I'm trying to use get_browser() , unfortunately my page is on a shared host, and I have no access to php.ini. I have downloaded the latest version of browscap.ini and placed in my document root. I have then added the following:- if (!ini_set('browscap', '/home/private stuff/browscap.ini')) { echo "Failed to set browscap"; } else { echo "browscap = [" . ini_get('browscap') . "]"; } exit(); But this fails, (nb: the echo statement for the failed condition always shows [] - even if I didn;t have the browscap.ini file the setting should still show up in the ini_get.... shouldn't it?) I have looked at the previous questions on this and they don't seem to help, any ideas?

    Read the article

  • Logging Errors with messages in Codeigniter

    - by user1260776
    I’m using codeigniter on a production server, and I’m not able to properly log the errors generated to the file. I edited php.ini like this- error_reporting = E_ALL | E_NOTICE | E_STRICT|E_WARNING display_errors = Off log_errors = On error_log = "/var/log/php-scripts.log" // This is where I would like to log all the errors and notices.. And php-scripts.log is able to show the logs like this- [06-Jun-2012 03:22:20 UTC] PHP Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:26:06 UTC] PHP Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:05 UTC] PHP Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:07 UTC] PHP Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:11 UTC] PHP Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 Now, the “index.php” settings in my “public_html” folder, (i’ve rest of CI folder outside public_html) I’ve these settings- define('ENVIRONMENT', 'production'); if (defined('ENVIRONMENT')) { switch (ENVIRONMENT) { case 'development': error_reporting(E_ALL); break; case 'testing': case 'production': error_reporting(0); break; default: exit('The application environment is not set correctly.'); } } Though everything seems to be fine, now, I’ll just change Environment to “development”, this is what I get on my website homepage- A PHP Error was encountered Severity: Warning Message: fclose() expects parameter 1 to be resource, null given Filename: core/Common.php Line Number: 91 A PHP Error was encountered Severity: Warning Message: Cannot modify header information - headers already sent by (output started at /home/theuser/codeigniter/system/core/Exceptions.php:185) Filename: core/Security.php Line Number: 188 The “rest” of the page is also displayed. And when I look at php-scripts.log, I’m not able to see any of these logs there- [06-Jun-2012 03:22:20 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:26:06 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:05 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:07 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:11 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:30:45 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 [06-Jun-2012 03:37:41 UTC] PHP Deprecated: Directive ‘safe_mode’ is deprecated in PHP 5.3 and greater in Unknown on line 0 One more thing is I don’t know how/where codeigniter itself would log all the errors. The permissions of “application/logs” folder is “777”, but there is no log file (I was expecting that CodeIgniter would automatically create a log file, should I create one, if I’ve to log errors there). I’ve set these configurations in config/config.php $config['log_threshold'] = 4; $config['log_path'] = ''; //hoping it would log errors at "default" location... Ideally, I just wish all those errors, warning, and notices (with messages) that were displayed on my webpage were sent to log-file /var/log/php-scripts.log when the “Environment” is “Production”. If it’s not possible, I would also be fine, If i can log it somewhere else. Now, I’m confused as to what should be the settings in the “index.php” page or some other configuration, so as to supress all the errors and warnings on the webpage when environment is "Production", and send all those errors, warnings, and notices to php-scripts.log. (or any other file) my php version is PHP 5.3.13 with Suhosin v0.9.33 Please help me with this. Thank you

    Read the article

  • Is it possible to auto update php.ini via a bash script?

    - by Tada.wav
    I'm trying to write an install script and i need to change the sendmail line in php.ini but I want to do this automatically at the moment I'm doing this manually: sudo nano /etc/php5/apache2/php.ini finding the line containing sendmail_path = then editing it to be sendmail_path = /usr/bin/msmtp -t then saving the file. Is it possible to just auto script this to make the change? Thanks a lot

    Read the article

  • IP Blocking on error logs PHP

    - by Lee
    Is there a way to block error logging from a specific set of IP's ? Basically macafee carry out a range of testing on the server nightly and we don't want to record these in our error logs. Is there a good way to avoid this from happening ? Hope you can advice!

    Read the article

  • File not readable exception - pear/Config_Lite

    - by CasperNine
    I have two config files located in: /etc/svnauth and var/www/svnauth I have given read, write access to for both files like shown below chown -R apache:apache /etc/svnauth chmod -R 770 /etc/svnauth chown -R apache:apache /var/www/svnauth chmod -R 770 /var/www/svnauth When I try to read these two files using pear/Config_Lite, /etc/svnauth always fails. I can successfully read the /var/www/svnauth file Any reasons for this? What am I missing here Following is the error message i get: Fatal error: Uncaught exception 'Config_Lite_Exception_Runtime' with message 'file not readable: /etc/svnauth' in /var/www/html/svnmanager/Config/Lite.php:112 Stack trace: #0 /var/www/html/svnmanager/index.php(60): Config_Lite->read('/etc/svnauth') #1 {main} thrown in /var/www/html/svnmanager/Config/Lite.php on line 112

    Read the article

  • PHP file upload

    - by Develman
    I have big trouble with file uploads with php. My own tests are successful but my colleague is telling me that he cannot update "larger" (ca. 5mb) files. Phpinfo says: - max_execution_time 30 - memory_limit 32 Mb - post_max_size 8 Mb - upload_max_filesize 10 Mb Is it better to use FTP? The problem is that I cannot change these settings at my webhoster.

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >