15
Php

Extend Laravel Eloquent Collection Object

According to Laravel, all multi-result sets returned by Eloquent, either via the get method or a relationship, will return a collection object. This object implements the IteratorAggregate PHP interface so it can be iterated over like an array. However, this object also has a variety of other helpful methods for working with result sets. For […]

4
Php

Extend Input Class in Laravel – 4

There is no Input class in Laravel, instead it uses Request class for any Input::method() calls. Basically, we extend a class in OOP language to add some extra functionalities to a base (already created) class and in PHP, for example, if you have following class

Now, if you need to extend this class then […]

7
Php

Advanced Date Queries in WordPress – 3.7

On October 24, 2013, WordPress Version 3.7, named for Count Basie, was released. It has some cool new features and one of those is that, developers can now query for posts within a date range, or that are older than or newer than a specific point in time using date_query . For example, to get […]

0

Taste Of JavaScript In Php Part-2 (Php 5.4+)

A few days ago I’ve posted an article, titled Taste Of JavaScript In Php (as my random ideas) where I wrote a class to create dynamic Php objects in the run time and it requires Php 5.4+ and this is another follow up of that article, the updated version of stdObject class, which requires Php […]

2
Php

Iconfig – Instant config manager for PHP

Iconfig (Instant config) is a stand alone component/package for any PHP application, which is built to easily manage configurations for any PHP application, available on Packagist.  How To Use : At first, install it using composer, if you don’t know how to use composer then learn to use it and add following to require section […]

2

Taste of JavaScript in Php

Well, It’s true that Php was not matured enough in it’s early days but now Php become very so much powerful and recently Php 5.5.x has been arrived with some cool new features which are really powerful additions to Php so thanks to Php who are working hard to make this language powerful and robust. […]

4
Php

Php 5.5.x and New Features

On 20-Jun-2013, the PHP development team has announced the immediate availability of PHP 5.5.0 and this release includes a large number of new features and bug fixes. The new features of PHP 5.5.0 includes : Generators : Support for generators has been added via the yield keyword. Generators provide an easy way to implement simple […]

ob-image
6
Php

Headers Already Sent Error in WordPress

In WordPress admin/back end it says : Warning: cannot modify header information – headers already sent by (output started at /home/…../header.php:3) in /home/…. on line xxx Well, this is a very common problem and old too, which has been discussed/resolved in so many places on the WEB (IMO) and it happens, when developing a plugin […]

4
Php

Pretty Url in WordPress Search Result

In WordPress, the search url is not pretty, I mean it’s not search engine friendly (uses query string), it looks something like http://example.com?s=foo and it’s doesn’t look very professional. So, if you want to change the url to something like http://example.com/search/foo then it’s possible and very easy, just 2 steps. Step 1 : Create a […]

0
Php

GetSetGo-Php Dynamic Setter Getter Library

GetSetGo is a dynamic setter-getter library for PHP 5.4+. Its developed by me and Muhammed Usman, and yes, it’s well unit tested. You can use methods like setFoo(‘bar’) and getFoo(), which you don’t have to create (in your class). GetSetGo will make these methods work for you automatically as long as you have a $foo […]