Home arrow PHP arrow Page 3 - Installing PHP under Windows: Further Configuration of WAMP
PHP

Installing PHP under Windows: Further Configuration of WAMP


PHPIn his last article, Matthew showed us how to successfully install and configure WAMP (Windows, Apache, MySQL and PHP) to setup a development environment.  In this next piece, learn how to make use of the Apache and PHP configuration files to further enhance your server needs.

Author Info:
By: Matthew Phillips
Rating: 4 stars4 stars4 stars4 stars4 stars / 93
December 11, 2003
TABLE OF CONTENTS:
  1. · Installing PHP under Windows: Further Configuration of WAMP
  2. · Configuring Apache
  3. · Configuring PHP
  4. · Conclusion

print this article
SEARCH DEVARTICLES

TOOLS YOU CAN USE

advertisement
Installing PHP under Windows: Further Configuration of WAMP - Configuring PHP
(Page 3 of 4 )

Now we are going to edit php.ini in the Apache folder (one up from the conf folder).  Anything following the semi-colon character (;) is commented out, to uncomment it, simply delete the semi-colon.

short_open_tag = On
This should be set to off.  This will not allow us to use the short <? ?> style tags.  Although there are ways to get around this, this setting will force us to code in the 'proper' and more portable way (<?php ?>).

asp_tags = Off
Who wants to use ASP style <% %> tags (apart from ASP developers)?

highlight.string = #DD0000
highlight.comment = #FF9900
highlight.keyword = #007700
highlight.bg = #FFFFFF
highlight.default = #0000BB
highlight.html = #000000

Simply uncomment these lines (remove the semi colon (;) before them).

error_reporting = E_ALL
Sets PHP to tell us about all errors.

display_errors = On
PHP tells us about errors rather that just sit there with a blank screen!

register_globals = Off
Stops many possible security issues, and forces the user of the superglobal arrays (ie: $_POST, $_GET, $_COOKIES, etc.).

doc_root = C:Program FilesApache GroupApache2htdocs
This path should be the same as the document root you set in Apache’s httpd.conf file.

;extension= ...
This allows you to include various PHP extensions, a bit like modules in Apache.  You should only turn then on when you need them.

session.save_handler = files
Make sure that this is set to files.

session.save_path = c:/temp
Make sure that this is set to a temp directory that exists on your PC.  It will be used to save data for sessions.


blog comments powered by Disqus
PHP ARTICLES

- Removing Singletons in PHP
- Singletons in PHP
- Implement Facebook Javascript SDK with PHP
- Making Usage Statistics in PHP
- Installing PHP under Windows: Further Config...
- File Version Management in PHP
- Statistical View of Data in a Clustered Bar ...
- Creating a Multi-File Upload Script in PHP
- Executing Microsoft SQL Server Stored Proced...
- Code 10x More Efficiently Using Data Access ...
- A Few Tips for Speeding Up PHP Code
- The Modular Web Page
- Quick E-Commerce with PHP and PayPal
- Regression Testing With JMeter
- Building an Iterator with PHP

Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 



© 2003-2012 by Developer Shed. All rights reserved. DS Cluster 4 - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials