News Feed
Sections




News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

NetTuts.com:
Five Hidden Gems of Laravel
August 22, 2014 @ 11:51:20

The NetTuts.com site has posted a list of their five hidden gems in Laravel, a popular PHP framework. They look at a wide range of these "hidden" features that can help make your Laravel experience even better.

Many developers who use Laravel are probably only barely scratching the surface of what the framework has to offer. While the documentation does cover the most common use cases and the obvious features, it doesn't cover everything. Don't get me wrong, the documentation is fine, it's just that there's so much you can do, it's hard to document everything. Because of that, we're going to take a look at some of the hidden gems that lurk within Laravel.

The five items on their list come complete with summaries about the feature, when they were added, if they're documented and a code sample with them in use:

  • Cascading Views
  • Collections (with sorting, filtering and pagination)
  • Regular Expression Filters
  • The Message Bag
  • Fluent
0 comments voice your opinion now!
hidden gems laravel framework views collections regex filter message fluent

Link: http://code.tutsplus.com/articles/five-hidden-gems-of-laravel--cms-21907

Derick Rethans:
Contributing Advent 1 Xdebug and hidden properties
December 02, 2013 @ 09:16:50

As a part of his "Advent Contribution" series Derick Rethans has posted about an update to XDebug that fixes a bug reported around hidden properties.

This first contribution is for bug #987: "Hidden property names not shown". In PHP it is possible to convert an array to an object. [...] Xdebug's standard HTML var_dump() as well as the CLI, the coloured CLI and the debugger interface DBGp all suffered from the same issues that numerical properties were not showing in output.

With the committed fix the output of the var_dump now shows these special property names with curly braces around them and makes them available via the property_get method. If you're interested in the actual commit, you can check it out here.

0 comments voice your opinion now!
advent contribute hidden properties xdebug vardump propertyget

Link: http://derickrethans.nl/advent01.html

Stefan Koopmanschap's Blog:
PHP Hidden Gem similar_text()
July 13, 2009 @ 09:37:50

Stefan Koopmanschap has written about a hidden gem he discovered in PHP to help locate blocks of text that seem similar from one or more sources - similar_text.

I am working on a hobby project where I aggregate feeds from several different sources. With the blogs I work it right now, it often happens that an author posts the same post to a few different sites. However, because of site formats and sometimes also quick edits an author makes on one site but not on the author, the article contents are usually not identical strings. So I needed something that would help me figure out whether or not two strings are nearly identical.

After Googling around and finding things like the xdiff extension and soundex, he discovered the two functions he needed - levenshtein and similar_text.

I am still trying to figure out which percentage will catch the duplicates but not catch too many posts which are only similar but not actually duplicates, but with the above 75% I seem to catch quite a few duplicates so far.
0 comments voice your opinion now!
similartext gem hidden


Johannes Schluter's Blog:
A hidden gem in PHP 5.3 fileinfo
December 17, 2008 @ 09:35:59

Johannes Schluter has pointed out a "hidden gem" for PHP 5.3 in his latest blog post - the fileinfo extension.

This series is not meant to be complete but some personal choice, these blog postings are also no replacement for documentation, but just pointers. My goal is that you try out 5.3 right now so we can fix bugs as soon as possible before releasing it The NEWS file has a quite short entry for my first subject: Added fileinfo extension as replacement for mime_magic extension. (Derick)

He looks at one situation where the extension could come in very handy - getting the content type of the file for a download push - as well as why its better than the older mime_content_type function.

0 comments voice your opinion now!
php5 gem fileinfo mimecontenttype function extension hidden


Zend Developer Zone:
Zend Framework Hidden Gems Zend_Db
December 18, 2006 @ 10:04:00

Aaron Wormus and the Zend Developer Zone have posted the latest edition of their "Hidden Gems" series looking at the lesser-known features of the Zend Framework. This time, it's a look at Zend_Db (database abstraction).

Zend_Db is a layer which sits above the native PDO database extension. Before PDO (pre-PHP5.1) all we had to connect to databases were libraries that were developed in individual cycles and development teams, with little regard to what other database extensions were doing.

Taking this speed benefit of using PDO to do a majority of the work, PDO wrapper libraries like Zend_Db can supplement PDO with their own wrapper code leaving you with a fairly lightweight yet feature-rich database abstraction layer.

Aaron looks at connecting to a database (using both the PDO and DSN connections) and some example code showing how to work with the database using them - including queries and using transactions.

0 comments voice your opinion now!
hidden gem zend framework zenddb database abstraction hidden gem zend framework zenddb database abstraction


Zend Developer Zone:
Zend Framework Hidden Gems Zend_Config
November 24, 2006 @ 11:43:00

The Zend Developer Zone has posted another in the "Hidden Gems" series by Aaron Wormus, this time looking at the Zend_Config component.

Managing configuration is a pretty simple thing to do in PHP, in fact, I'd bet that at some point in their programming career every php programmer has written code. But as soon as you get a bit bigger you realize that you're going to have trouble accessing your configuration variable.

There are many reasons to manage your configuration data indepenantly from your business logic. One common reason is that you don't want to enter your configuration data into the public versioning system that you use.

Aaron looks at how you can use the component in your application easily including an example using the built-in inheritance functionality to easily manage a move from development to production.

0 comments voice your opinion now!
zend framework hidden gem zendconfig inheritance zend framework hidden gem zendconfig inheritance


Zend Developer Zone:
Zend Framework Hidden Gems Zend_Cache
November 17, 2006 @ 12:38:42

The Zend Developer Zone has its next in its "Inside Look" series at the Zend Framework and its components - this look at the Zend_Cache component.

Caching isn't one of those things that many people think of when designing their first applications. However once they launch their new AJAX enabled web2.0 application, they might start wondering what they can do to get this beast to move faster. The answer is caching.

Aaron Wormus gets started with the basics - why use caching and some of what it's for - before getting into the actual code example. His simple example just shows how to cache a bit of information and get when it was cached. He also talks about implementing tagging for more complex caches (different pieces for different times), and the drivers that are available for the component - both frontend and backend.

0 comments voice your opinion now!
zendcache component zend framework hidden gem cache zendcache component zend framework hidden gem cache


Zend Developer Zone:
Zend Framework Hidden Gems Introduction
November 08, 2006 @ 15:36:00

Cal Evans, of the Zend Developer Zone, is taking a different path than the large number of Zend Framework tutorials that he's seen out there:

Zend Framework looked like an interesting platform, but each tutorial that I read started out with explaining how to set up your front controller, and moved form there into writing an entire application. I am not starting any new projects, and have no need for that.

Instead, he's chosen to look a bit "behind the scenes" at what really makes the Framework tick and why it would be a good choice for any number of web applications out there. It's going to become a series on the ZDZ, so he starts it off right with a comparison between PEAR and the Zend Framework, specifically when it comes to error handling.

It's more of a compare and contrast kind of thing than a contest, but it does seem that Cal favors one's approach a bit more. Which one? Well, you'll just have to go read and find out...

0 comments voice your opinion now!
zend framework hidden gem pear error handling exception simplicity zend framework hidden gem pear error handling exception simplicity



Community Events





Don't see your event here?
Let us know!


code install api configure series symfony list application laravel podcast community wordpress threedevsandamaybe introduction unittest release interview library developer language

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework