• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 246
  • Last Modified:

PHP: script: why doesn't it work?

Hello Experts,

why is it that the 'test' value is not displaying on the browser?

thanks,
<?php
ini_set('test', 2);
echo ini_get('test');
?>

Open in new window

0
epifanio67
Asked:
epifanio67
1 Solution
 
PragmatiCoderCommented:
The ini_set function is used to set php configuration values, such as "display_errors", "include_path", etc... all of them come from the php.ini file... so since there is no "test" configuration for php, it can not get the value of it...

If you try

<?php
    ini_set('test', 2);
    var_dump(ini_get('test'));
?>

Open in new window


You'll see that ini_get is returning FALSE, cause there is no setting with that name
0
 
epifanio67Author Commented:
got it ... thank you!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: MCSA MCSE Windows Server 2012

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

Tackle projects and never again get stuck behind a technical roadblock.
Join Now