Friday, November 16, 2007

PHP Developers

Choosing The Best PHP Host For Your Website Or Blog
By [http://ezinearticles.com/?expert=Darren_Lambert]Darren Lambert

Choosing the right PHP web hosting company for your website or blog is critical. The downtime and lack of configuration offered by the low-end hosting providers can be severely detrimental to the performance and success of your website.

With so many PHP hosting companies advertising their services on the internet it can be difficult to chose which is the right one for your website or blog. If you chose the wrong host, and subsequently suffer problems, moving your website to a new host can be a painful and time consuming task.

I'll discuss the key features to look at when assessing a potential hosting company:

Bandwidth

Bandwidth is the total amount of data that your website can deliver in a single month. If you exceed the bandwidth limit your account may be suspended until you buy more bandwidth, or upgrade your account. Ensure you select a hosting package that allows you enough bandwidth for your current traffic, and for the foreseeable future.

Disk space

This is the amount of space you are allocated on the web server to store all of your files. Media rich websites can often use up disk space quickly. Ensure your potential PHP hosting package offers enough disk space for your current website, and its future growth.

Domains

Most people use one domain on a single hosting account. However, some people like to run several websites, or domains, from a single hosting account. If you intend to do this ensure the hosting package allows add-on and parked domains.

Databases

PHP hosts set a limit on the number of database you can use. If you are using a Web 2.0 application, or any other type of PHP application than uses MySql databases, ensure the hosting package has sufficient databases for your needs.

Uptime

This is the amount of time that the web server will be able to deliver your website to readers. 99% is ideal, cheaper hosting often offers less.

Fantastico

Fantastico is a system that quickly and easily installs popular Web2.0 applications into your hosting package. Most hosts include Fantastico, which allows you to easily install WordPress, Drupal and other blog and CMS systems.

Taking the time to chose the correct PHP web hosting company and package can save you a great deal of time and money as your website or blog grows.

Compare the [http://www.ascenddirectory.com/best-php-hosting ]best PHP hosting companies and packages. Darren is an experienced webmaster and PHP developer, and has worked with many PHP hosting companies.

Article Source: http://EzineArticles.com/?expert=Darren_Lambert http://EzineArticles.com/?Choosing-The-Best-PHP-Host-For-Your-Website-Or-Blog&id=812052

Posted By: Illusion Technologies
http://www.illusiontechnologies.com

Thursday, November 15, 2007

PHP Developers

How to Learn PHP and MySQL as Quickly as Possible
By [http://ezinearticles.com/?expert=Clint_Lenard]Clint Lenard

Learning Programming is a tough subject, no matter which language you choose.

It took me months to figure out php and MySQL enough to build real, quality, Websites that were "good enough".

Eventually I figured out the easiest way to learn. It took me MONTHS to figure it out... but I did.

So what does it take to learn a Programming Language such as PHP?

"Doing" is what it takes. 90% of the people who try to take on such a task end up feeling "dumb" or "slow". This usually is NOT the case. I've found that, like myself, most people try to learn PHP from reading and going through code to "understand" what it means.

I was the same way until I was told "just do it". My mentor must have been the most patient man on the face of this earth - because I was constantly telling him I could not do it. But he kept on me telling me the same line I'm telling you: "just do it".

What does this mean? It means trying to create your very own scripts, whether small or of decent size. Start out with printing out the date to the browser. Continue with Loops. Create scripts that create mathematical equations. Print out your name, last name, etc.

Once you figure out the basics, make sure you continue to learn by doing! You will never be able to take your skills to the next level just by reading.

I also stress to other newbies that they need to learn by watching as well. Writing code can become quite a task and it's better to see someone else do that, if possible (which it is by watching videos).

It's quite easy to get caught up in bad practices while writing code if you do not follow good programming standards. Sloppy (spaghetti) code seems to be the evil of the programming world that occurs from newbies who read online tutorials by so called "programmers". Most of these "programmers" are NOT what they claim to be. So be careful of whom you choose to learn from.

PHP and MySQL (database) go together like peanut butter and jelly. I cannot tell you how important it is to learn these two languages together. MySQL may not be the "best" Database in the world but it is very easy to learn and very capable of building large scale applications.

So remember: if you're not "doing", you're not learning. Start learning PHP basics and make sure you're following along and trying to code your own small scripts when starting out. I know, I know... it LOOKS like it's too hard. It's not. This is not something you're going to learn overnight, but it's quite possible that you can learn enough to do what you need to do in just a matter of weeks!

Keep learning and continue doing.

Want to learn PHP at rapid speed? [http://learnbyvideo.blogspot.com/2007/11/learn-php-by-video.html]Check out these awesome Video Tutorials I've found!

If you're looking to become a PHP programmer - you need to see [http://learnbyvideo.blogspot.com/2007/11/learn-php-by-video.html]these videos!

Article Source: http://EzineArticles.com/?expert=Clint_Lenard http://EzineArticles.com/?How-to-Learn-PHP-and-MySQL-as-Quickly-as-Possible&id=819035

Wednesday, November 14, 2007

Introduction to PHP

Introduction to PHP
By [http://ezinearticles.com/?expert=Gagandeep_Singh_Tathgar]Gagandeep Singh Tathgar

What is PHP?

PHP stands for "PHP: HyperText Preprocessor". PHP is a server side scripting language for making dynamically driven websites. PHP written scripts can be used to keep track of your visitor’s activities on your site, send out emails to your subscribers, let your users upload files or images to your site, and drive the content on your site dynamically using databases. The possibilities are endless. Most of the social networking websites you visit are writing in PHP. Yep! PHP is that powerful.

What are PHP benefits?

PHP is a free open source language. That means you don't have to pay thousands of dollars in licensing fee to acquire PHP. Best of all, it is easy to install. The most striking feature of it is that it is easy to learn. PHP is used by millions of people and developers around the world. There are thousands of websites on the internet which are written using PHP. One primary example is Yahoo! Bookmarks.

What PHP can do for me?
PHP can greatly enhance the functionality of your website. It allows you to write scripts which let your visitors interact with you through your website. If you run a small business website, you can use PHP to let your users send you feed back to you on your products ad services or create a form which will allow your customers to send you emails, etc, etc.

Is PHP easy to learn?

Thou PHP will allow you to almost do anything complicated on your website. But you can implement simple forms or logic on your site very easily. At [http://php-learn-it.com]PHP-Learn-It.com, i explain some of those techniques with examples.

Article Source: http://EzineArticles.com/?expert=Gagandeep_Singh_Tathgar http://EzineArticles.com/?Introduction-to-PHP&id=556967


Posted By: Illusion Technologies
http://www.illusiontechnologies.com

Friday, November 2, 2007

PHP Developers

Speeding PHP using APC PHP Cache
By [http://ezinearticles.com/?expert=Jon_Murray]Jon Murray

If you look at a PHP source file you will notice one thing. It's a source file. Not particularly surprising, but think about when you deploy a PHP application, what do you deploy? PHP source files. Now for many other languages; Java, C, etc when you deploy an application you deploy the compiled file. So, the question that you want to ask yourself is this, how much time does a PHP application spend compiling source files vs running the code? I'll answer that for you, a lot.

There are advantages to being able to deploy source files though. It makes it easy to do on the fly modifications or bug fixes to a program, much like we used to do in the early BASIC languages. Just change the file and the next time it's accessed your change is reflected. So, how do we keep the dynamic nature of PHP, but not recompile our files every time they are accessed?

A PHP cache. It's surprising to me that this concept isn't built into the base PHP engine, but perhaps that's because some company's can sell this add on to speed up PHP. Luckily for us, some companies/open source projects provide this plug in to PHP at no charge. These plug ins are generally known as PHP accelerators, some of them do some optimization and then caching and some only do caching. I'm not going to pass judgement on which one is the best, any of them are better than nothing, but I decided to use APC, the Alternative PHP Cache. I chose this one because it is still in active development and is open source and free.

Alternative php cache can be found at php.net, just look down the left column for APC. It comes in source form, so you will need to compile it before installing it, don't worry about that part. If you're using Red Hat 4 or CentOS4 I'll tell you exactly how to do it. If you're using something else, you'll need the same tools, but getting the tools might be a bit different.

1. The Tools
Do you know how many web sites, forums and blogs I went to with my error messages before I found the answers as to what I was missing when I was trying to install APC - Alternative PHP Cache? Two days worth, but I finally found the correct combination and it's really quite obvious as is everything once you know the answer. There are three sets of dev tools that you will need.

1a. You'll need a package called "Development Tools" this will include all the important dev tools like the GCC compiler, etc.
1b. You'll need a package called php-devel which as you might guess are development tools for PHP
1c. You'll need a package called httpd-devel which of course are dev tools for Apache web server.

On Red Hat or CentOS getting these should be as easy as the following 3 commands:

yum groupinstall "Development Tools"
yum install php-devel
yum install httpd-devel

You'll do these three one at a time and follow any instructions (usually just saying yes).

Now it's time to follow the instructions contained in the APC package. Since these may change over time I'm not going to go through them. They are very complete. If you follow the instructions and get an apc.so file out of it, then you're all set, just modify your php.ini file and you're good to go.

There are two problems that I encountered that you may encounter too. The first is an error when running phpize. I ignored this error and everything succeeded okay, but not before I spent hours looking for the solution to this error. Here is the error.

configure.in:9: warning: underquoted definition of PHP_WITH_PHP_CONFIG


run info '(automake)Extending aclocal'


or see http://sources.redhat.com/automake/automake.html#Extending-aclocal

configure.in:32: warning: underquoted definition of PHP_EXT_BUILDDIR

configure.in:33: warning: underquoted definition of PHP_EXT_DIR

configure.in:34: warning: underquoted definition of PHP_EXT_SRCDIR

configure.in:35: warning: underquoted definition of PHP_ALWAYS_SHARED

acinclude.m4:19: warning: underquoted definition of PHP_PROG_RE2C


People would have had me updating my PHP version from 4.3.9 and everything else under the sun to get rid of this error, but in the end it didn't matter. My APC compiled and installed nicely and I am good to go.

The other slight problem that I ran into was the location of php-config. The install instructions wanted me to do the following:

./configure --enable-apc-mmap --with-apxs --with-php-config=/usr/local/php/bin/php-config

However my php-config is in /usr/bin/php-config. Making that change allowed this part to work.

So, have at it, once it's done you can expect to see huge improvements in your web site response times and reductions on your CPU load. One more quick note, My server hosts about 20 web sites, but only 3 or 4 are really busy. To reduce the memory footprint of caching everything for all 20 sites I used the apc.filters property. Although this property is slightly flawed for non qualified includes, it worked nicely for my Serendipity blogs. Your mileage with this property will vary according to the software you are using and how it does it's includes.

Jon runs UFC fan site [http://www.ufcresultslive.com/categories/39-UFC-Results/]UFC Results come to UFC Results at http://www.ufcresultslive.com for UFC Results, Predictions, News and of course Fighter Rankings.

Article Source: http://EzineArticles.com/?expert=Jon_Murray http://EzineArticles.com/?Speeding-PHP-using-APC-PHP-Cache&id=800655

Posted By: Illusion Technologies
http://www.illusiontechnologies.com

Template Design | Elque 2007