Showing posts with label PHP Tutorials. Show all posts
Showing posts with label PHP Tutorials. Show all posts

Developers' Best Friends

Here are some tools and softwares I found useful in my job. You may share yours.

Hardwares:

- PC / laptop
- Internet Connection - Sun Broadband
- Cellphone
- Mug - for my coffee

Softwares:

- Linux OS - Centos
- Putty
- Zend Studio
- Notepad
- WinSCP
- Tortoise SVN
- Izarc

PHP Best Practices

Source: http://laurat.blogs.com/talks/best_practices_apachecon.pdf

Definition: Best Practices

- Knowing what’s in the toolbox
- Knowing the strengths and weaknesses of your tools
- Using the tools appropriately, and in the most efficient fashion
- Having a working, consistent, repeatable process.

Your PHP should

- be simple
- get the job done
- be secure
- be scalable and performant
- be producible and maintainable

Write good code

- Above all, code needs to be readable and maintainable

Beware clever code:
- cool design patterns
- obscure performance tweaks
- niche language features

Coding Standards

- Have and use a coding standard
- Zend Framework, PEAR, homebrew
- Legacy code always a problem

Don'ts

- Make the rules awkward and difficult to remember
- Apps Hungarian
- Force millions of include files (performance hit)
- Force complete OO (c.f. Simple)

Source: http://laurat.blogs.com/talks/best_practices_apachecon.pdf

Joomla!

Source: http://joomla.org"

What is Joomla?

Joomla is an award-winning content management system (CMS), which enables you to build Web sites and powerful online applications. Many aspects, including its ease-of-use and extensibility, have made Joomla the most popular Web site software available. Best of all, Joomla is an open source solution that is freely available to everyone.

What's a content management system (CMS)?

A content management system is software that keeps track of every piece of content on your Web site, much like your local public library keeps track of books and stores them. Content can be simple text, photos, music, video, documents, or just about anything you can think of. A major advantage of using a CMS is that it requires almost no technical skill or knowledge to manage. Since the CMS manages all your content, you don't have to.

What are some real world examples of what Joomla! can do?

Joomla is used all over the world to power Web sites of all shapes and sizes. For example:

* Corporate Web sites or portals
* Corporate intranets and extranets
* Online magazines, newspapers, and publications
* E-commerce and online reservations
* Government applications
* Small business Web sites
* Non-profit and organizational Web sites
* Community-based portals
* School and church Web sites
* Personal or family homepages

Who uses Joomla?

Here are just a few examples of Web sites that use Joomla:

* MTV Networks Quizilla (Social networking) - http://www.quizilla.com
* IHOP (Restaurant chain) - http://www.ihop.com
* Harvard University (Educational) - http://gsas.harvard.edu
* Citibank (Financial institution intranet) - Not publicly accessible
* The Green Maven (Eco-resources) - http://www.greenmaven.com
* Outdoor Photographer (Magazine) - http://www.outdoorphotographer.com
* PlayShakespeare.com (Cultural) - http://www.playshakespeare.com
* Senso Interiors (Furniture design) - http://www.sensointeriors.co.za

More examples of companies using Joomla can be found in the Joomla Community Site Showcase.

LINKS:
http://extensions.joomla.org/
http://www.joomla.org/download.html
http://demo.joomla.org/
http://docs.joomla.org/
http://www.joomla.org/about-joomla.html
http://forum.joomla.org/
http://www.joomla.org/announcements/release-news/5226-joomla-159-security-release-now-available.html
http://help.joomla.org/

Source: http://joomla.org

PHP 6

Source: http://www.ibm.com/developerworks/opensource/library/os-php-future/

New PHP V6 features

PHP V6 is currently available as a developer snapshot, so you can download and try out many of the features and changes listed in this article. For features that have been implemented in the current snapshot, see Resources.

Improved Unicode support

Much improved for PHP V6 is support for Unicode strings in many of the core functions. This new feature has a big impact because it will allow PHP to support a broader set of characters for international support.

Namespaces

Namespaces are a way of avoiding name collisions between functions and classes without using prefixes in naming conventions that make the names of your methods and classes unreadable. So by using namespaces, you can have class names that someone else might use, but now you don't have to worry about running into any problems. Listing 1 provides an example of a namespace in PHP.

Web 2.0 features

Depending on how you use PHP and what your scripts look like now, the language and syntax differences in PHP V6 may or may not affect you as much as the next features, which are those that directly allow you to introduce Web 2.0 features into your PHP application.

SOAP

SOAP is one of the protocols that Web services "speak" and is supported in quite a few other languages, such as the Java programming language and Microsoft® .NET. Although there are other ways to consume and expose Web services, such as Representational State Transfer (REST), SOAP remains a common way of allowing different platforms to have interoperability.

XML

As of PHP V5.1, XMLReader and XMLWriter have been part of the core of PHP, which makes it easier for you to work with XML in your PHP applications. Like the SOAP extensions, this can be good news if you use SOAP or XML because PHP V6 will be a better fit for you than V4 out of the box.

Things removed

In addition to having new features, PHP V6 will not have some other functions and features that have been in previous versions. Most of these things, such as register_globals and safe_mode, are widely considered "broken" in current PHP, as they may expose security risks.

Features that will be removed from the PHP version include:

* magic_quotes
* register_globals
* register_long_arrays
* safe_mode

magic_quotes

Citing portability, performance, and inconvenience, the PHP documentation discourages the use of magic_quotes. It's so discouraged that it's being removed from PHP V6 altogether, so before upgrading to PHP V6, make sure that all your code avoids using magic_quotes. If you're using magic_quotes to escape strings for database calls, use your database implementation's parameterized queries, if they're supported.

Source: http://www.ibm.com/developerworks/opensource/library/os-php-future/