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

Three Devs & A Maybe Podcast:
The First All-Episode Quiz
August 14, 2014 @ 09:17:35

On the latest episode of the Three Devs & A Maybe podcast Michael Budd, Fraser Hart, Lewis Cains and Edd Mann have their first quiz show (Episode #38).

This week we start our chat off with the myth of just simply 'reskinning' a website, along with the dreaded !important in CSS. Following this, as we love quizzes so much, we decided to dedicate a full show to one. In this weeks quiz we touch upon many areas of PHP, JavaScript, CSS and random computer/programming history. We also now have t-shirts on sale, available via the first link in the show-notes (why don't you treat yourself).

Topics discussed in this episode include AngularJS fundamentals, speed in software development and avoiding burnout. You can listen to this latest episode either through the in-page player or by downloading the mp3 directly. If you enjoy the show also consider subscribing to their feed.

0 comments voice your opinion now!
threedevsandamaybe podcast ep38 quiz episode reskin css history

Link: http://threedevsandamaybe.com/posts/the-first-all-episode-quiz/

SitePoint PHP Blog:
How to Create a Laravel CSS-Minify Command
June 11, 2014 @ 14:58:31

The SitePoint PHP blog has a new post today from Tounes Rafie showing you how, in a Laravel framework based application, to create a minify command with the framework's "artisan" command.

In this article you'll learn how to use Laravel's Artisan command line tool, and how to create a customized command. Note that you need to be familiar with the Laravel framework to get the most of this article. In this tutorial we're going to build a command to minify our css assets.

He starts with a (very) brief look at what Laravel commands are and the options this articular one will include. Next up is the code you'll need to create the command, making use of Laravel's integration of the Symfony Console component. He shows how to register the command with the rest of the application and how to work with the options/arguments for the input. From there he shows how to run the command and how to make some other improvements including colorized output and more information on execution.

0 comments voice your opinion now!
css minify command laravel artisan framework tutorial

Link: http://www.sitepoint.com/create-laravel-css-minify-command

SitePoint PHP Blog:
Getting Started with Assetic
April 14, 2014 @ 10:37:00

The SitePoint PHP blog has a new post from Lukas White today looking at the Assetic asset management library and how you can get started using it in your application.

There was a time when asset management meant little more than inserting a <link> tag or two and a couple of <script> tags into your HTML. Nowadays, though, that approach just won't cut it. There's performance, for one thing. [...] Also, as client-side applications have become more and more sophisticated, managing dependencies amongst scripts and libraries has become increasingly complex. Furthermore, technologies such as Less, Compass and Coffeescript require assets to be compiled, adding yet another step to the process of managing assets. In this article I'm going to look at a PHP package called Assetic which helps manage, compile and optimize assets such as scripts, stylesheets and images.

He briefly discusses asset management first, just to get everyone on the same page as far as what "assets" are and some considerations about their use. Next is an introduction to the Assetic library itself and the install/usage of a simple "AssetCollection" object. He also shows how to add assets to the object and how to configure compression and generation of the files (like with LESS). He also shows how to use the AssetManager and FilterManager object types along with the AssetFactory handler. Finally, he talks about some of the sample output and caching the tool can do with file-based cache handling.

0 comments voice your opinion now!
assetic introduction asset tutorial javascript css less compress

Link: http://www.sitepoint.com/getting-started-assetic

PHPClasses.org:
Using Composer to Install JavaScript, CSS & Images Under the Web Document Directory
January 07, 2014 @ 12:36:07

On the PHPClasses.org site today there's a new post showing how to install more than just PHP packages with Composer including things like Javascript, CSS and image files.

By default Composer installs all package files under the vendor directory. If you want to install asset files in the Web document root directory, you need to resort to another solution. This Asset Manager package is a plugin that extends Composer to install any package files outside the vendor directory. Additionally, it can also read the user names and passwords from a configuration file, so you do not have to enter them every time Composer retrieves packages from repositories that may require authentication, like PHP Classes and JS Classes.

Using an asset manager plugin for Composer, he shows how to include an "extra" section into your "composer.json" for the other files. There's also an example of how to implement a custom installation action that, in this case, was used to implement the "extras" functionality. The post finishes up with a look at handling authentication in the Composer requests, using the same tool to parse a "config" section with Basic HTTP authentication information.

0 comments voice your opinion now!
composer package install javascript css image assets http authentication

Link: http://www.phpclasses.org/blog/package/8429/post/1-Using-Composer-to-Install-JavaScript-CSS-and-Images-Under-the-Web-Document-Directory.html

NetTuts.com:
Building Ribbit in PHP
January 04, 2013 @ 10:22:48

In the first part of a new series on NetTuts.com, they started on the creation of a full web application (a Twitter clone). The first article covered the CSS and using LESS to create an interface. In this second post they get into the PHP backend, opting to create it without a framework on the first shot.

In the initial entry in this series, we took care of the UI-aspect of our Twitter-clone, called Ribbit. Now, we'll begin coding the application in a number of languages. This lesson will leverage standard PHP (with homegrown MVC), but, in future articles, we'll review other implementations, such as with Rails or Laravel.

They provide all the code you'll need, the database table structure to power it (MySQL) and the examples of a model, router and basic MVC stack to handle the requests. They help you make a user creation and login system as well as a few other pages ("buddies", "make a post" and a few others). You can also download the source from their Github account if you want it all in one shot.

0 comments voice your opinion now!
ribbit backend tutorial series css less mvc


Codeception Blog:
The Locator Class
September 27, 2012 @ 09:50:34

The Codeception blog (a BDD testing tool) has a new post on using their Locator class to create more complex tests based on XPath or CSS selectors.

In the latest Codeception 1.1.4 new Locator class was introduced. Basically it should simplify your life in writing complex XPath or CSS locators. Right now it has minimal, yet useful functionality.

The post shows how to combine more than one item for location with either a tag, CSS-based or XPath-based selector. It also shows how to use the "tabindex" method to simulate the movement through a page using the "Tab" key. Finally, there's a quick piece of code showing how to locate an item based on the "href" value. For more information on using Codeception, check out their documentation or the project's main site.

0 comments voice your opinion now!
locator class css xpath combine tab href


ScreenFony.com:
Work with bootstrap, assetic and less
September 25, 2012 @ 10:36:20

On the ScreenFony.com site there's a quick tutorial showing you how to get started with Symfony2+Twitter Bootstrap+Assetic+LESS in a basic application. Assetic is a library that helps with asset management and use and LESS is a CSS pre-processor that makes it simpler to work with your site's CSS.

Bootstrap is a well known and powerful front-end framework for fast prototyping, it uses LESS and it can be easily integrate in your Symfony applications with the help of assetic. In this post I'll show how to: Install bootstrap in you Symfony application, load it using assetic, and compile bootstrap LESS files with lessphp.

Using Composer, creating a new Symfony2 project is just a single command away. The just update the "composer.json" and run the install to get the other needed libraries (LESS and the Twitter Bootstrap). They help you set up some Assetic filters for LESS and provide a simple page to output the Bootstrap in your header.

0 comments voice your opinion now!
symfony2 assetic twitter bootstrap less css tutorial composer


LineshJose.com:
How To Create A Simple CSS Compressor Using PHP
June 06, 2012 @ 08:44:26

In this recent post to his blog Linesh Jose shows you how to create a simple PHP-based compressor for your CSS (using some string replacement methods and a regex or two).

CSS or Cascading Style Sheets is a language used to describe the presentation of a document written in a markup language. If you're developing a very complex design for your site, CSS scripts become very long, and takes too much time to load. But a compressed CSS script can help your website load faster and easily maintain its functionality. Here, I've created a very simple CSS compressor using PHP to compress or reduce CSS script size.

You can read through the example code and see how it all works or you can download the code and see a live demo of it in action. His script does the compression on the fly, but it's not a far stretch to get it set up as a part of a build to output to a file on deployment.

0 comments voice your opinion now!
css compress tutorial strreplace pregreplace


Lee Davis' Blog:
Zend Paginator Example
April 19, 2012 @ 10:31:29

In a recent post to his blog Lee Davis gives an example of using the Zend Framework's pagination functionality, complete with some CSS to style it a bit better than the defaults.

One of the reasons why zend framework has been so popular is due to all the hard work put in to make sure components are extremely configurable. Sure there are default behaviours, but nothing is assumed and anything that needs to be overwritten or reconfigured can be. A strong emphasis on configuration over convention means you'll never be lumbered with code that just can't be changed. Zend Paginator is one of the smaller components of Zend Framework that allows you to get a simple paginator up and running on your listings or search pages in a matter of minutes.

Included in the post is a cut-and-pasteable view that creates the Previous/Next links as well as including the first/last page numbers and a few around the current page.

0 comments voice your opinion now!
zendframework zendpaginator tutorial view css


PHPMaster.com:
Automatic CSS3 Prefixer and Compressor
March 20, 2012 @ 12:38:30

On PHPMaster.com today there's a new tutorial showing how to use a little PHP magic to compress your CSS automatically.

There are many ways to compress CSS files or automatically generate browser-specific CSS3 prefixes, but usually extra tools are used which is very annoying. I'd like to show you how such tasks can be done using only PHP.

Complete code for this small script is included in the article. It uses some regular expressions to parse the CSS and does some replacement and removal of things from the CSS content to slim it down and format it all as one line. There are some images illustrating the process also included.

0 comments voice your opinion now!
css compress tutorial prefixer automatic



Community Events





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


release introduction code podcast interview bugfix framework laravel deployment conference tips threedevsandamaybe community zendserver series language api development list symfony

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