 | News Feed |
 | Jobs Feed |
Sections
|
| feed this: |  |
PHPMaster.com: Localizing PHP Applications "The Right Way", Part 1
by Chris Cornutt October 31, 2011 @ 08:38:25
PHPMaster.com has a new tutorial sharing what they call the right way for localizing PHP applications with the help of PHP's gettext functionality.
Localizing software applications in general used to be a cumbersome and error-prone task resulting in a lot of messy code. Some developers even use different versions of code for the same application but for different locales, which makes managing the codebase practically impossible. Enter gettext, the wonderful open-source tool that will make your life easier by allowing you to concentrate on your code. Localization becomes a matter of writing separate translation files for the target language, which can easily be done by a translator using Poedit.
They help you get your environment set up - PHP and a href="http://poedit.net/">Poedit, a gettext catalog editor - for both linux- and Windows-based OSes. They walk you through the creation of a simple project and a few basic "hello world" tokens. Using the files is as easy as setting the correct locale and default domain for your application. Then output is just a basic echo away.
voice your opinion now!
localize application gettext poedit series part1
DevShed: Introduction to Creating Command Objects with PHP 5
by Chris Cornutt December 12, 2006 @ 14:32:00
DevShed starts off a new series today in this first part of the series looking at the creation of and working with command objects in PHP5.
In this article, the first part of a series, you'll learn the basics of applying the command pattern with PHP 5. As always, plenty of hands-on examples are included.
A command class involves having a commander and the implementers that work together to do things like (what they illustrate) manipulating strings. They create the commander class and give a simple example of a subclass that implements it. They create a few more and tie them all into a master class to work together. Finally, they give an illustration of the code in action - uppercasing a string and inverting it to read backwards, then output.
voice your opinion now!
command object design pattern php5 part1 command object design pattern php5 part1
DevShed: Defining the Core Structure of a PHP Blogger
by Chris Cornutt November 21, 2006 @ 15:33:00
Yet another new series is starting over at DevShed today with part one of a look at the creation of a blogging application in PHP 5.
Assuming that building a blogger with PHP is really an interesting topic for you, let's learn together how this useful application can be developed in a few easy steps.
These easy steps include:
- defining the structure of the application
- creating the insertBlog method
- creating the updateBlog method
- creating the deleteBlog method
Each of the above functions provides just the basics of the functionality needed to make a more fully-developed blogging system, but there's more to come in future parts of the series. You can download a zip file of the current code here.
voice your opinion now!
tutorial part1 blogger application core structure php5 tutorial part1 blogger application core structure php5
Developer.com: Scaffolding with CakePHP - Managing Your Fantasy Football Team
by Chris Cornutt October 09, 2006 @ 16:25:00
With frameworks growing more and more popular, especially in the PHP community, it's good that major sites are working up tutorials to shwo their readers how to work with them. One such tutorial is this look at the CakePHP framework over on Developer.com.
In this first installment of a two-part series I'll introduce to how the aptly-named CakePHP framework can make implementing such features a total breeze, using the theme of a fantasy football application as the basis for introduction. In this article I'll implement the first two aforementioned features, and in the second we'll build additional features into the application, adding user authentication and allowing others to maintain their roster.
They don't teach you about the MVC pattern of design (Model/View/Controller), so you'll need to become aquainted with it. After that, though, they give you all you'll need - the table schemas, how to set up the scaffolding, creating the models and controller, and some data to help you fill in the details.
voice your opinion now!
cakephp framework tutorial part1 fantasy football team manage cakephp framework tutorial part1 fantasy football team manage
Felix Geisendörfer's Blog: Learning from the CakePHP Source Code (Part 1)
by Chris Cornutt September 26, 2006 @ 07:24:48
In his his latest blog entry, Felix Geisendörfer makes a recommendation for anyone working with the CakePHP framework. He suggests doing something that most might avoid - diving into the source to find out how things work.
When hanging out in #cakephp I usally try to answer questions people have as good as I can. A lot of the times I have no idea what the answer is and in most cases the fastest way to find out is by looking at the core code. Ok, the manual is pretty decent these days and I would recommend most people to look for an answer in there first. But if you take the time to study the core code, you'll be able to answer almost any question by yourself, no matter if it has been answered somewhere before.
He talks about other advantages like finding those hidden, undocumented features already supported by the framework. Since this is the first part of the series, he just looks at how to get into the source. He starts off with the basic index.php file that comes installed with the distribution and a chunk of code that helps run the index file and is at the heart of how CakePHP works - the Dispatcher.
voice your opinion now!
cakephp framework source learn tutorial part1 cakephp framework source learn tutorial part1
|
Community Events
Don't see your event here? Let us know!
|