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

SitePoint PHP Blog:
Effective PDF Generation in Drupal
Feb 03, 2015 @ 09:43:53

On the SitePoint PHP blog today there's a new post showing you how to create PDFs in a Drupal-based site making use of the Print module for the creation and formatting.

DF generation takes a slight change of mindset. As web developers, we have spent a lot of time convincing designers from a print background to stop producing pixel perfect designs that will be difficult to reproduce on the web. If you want to introduce PDF generation or any form of high designed print output, then we need to relearn some of our old skills we left behind. The nature of print means that it is precise and often needs pixel (or millimeter) perfect design.

He'd initially thought that the Views PDF module would be the natural choice, but after finding some unwanted dependencies, opted for the Print module instead. The Print module only creates the formatted output, though. This is then passed off to wkhtmltopdf to convert into final PDF form. He walks you through the configuration for the Print module and how to create some of the basic HTML structure for the resulting output. Next up is the addition of some styling and the process for exporting the HTML output over to wkhtmltopdf for handling. Output samples are included to help illustrate the final result.

tagged: pdf generation drupal tutorial views print wkhtmltopdf convert

Link: http://www.sitepoint.com/effective-pdf-generation-drupal/

Returning to Print!
Oct 16, 2013 @ 09:29:06

[php]architect magazine has made a big announcement today in response to one major request they've received - the magazine is once again available in a print version!

"Are you going to bring the magazine back to print?" It's the #1 question on everyone's minds. Since musketeers.me first acquired php[architect] at the beginning of 2013, it is the one question that we have constantly been asked. While digital publishing is the future, people still love the feeling of having a printed magazine in hand.

Knowing that our customers wanted it, we've worked hard to figure out a way that we could bring the magazine back to print again. We are extremely excited today to announce that starting with the November 2013 issue, php[architect] will once again be printed!

The print subscription will come in at $119 USD for a year's worth of magazines. They've also updated all current customers to a combined Digital level that includes all three major formats (PDF, ePub and Mobi). You can get more information about your current subscription level by logging in or, if you want to sign up now, check out the subscription information.

tagged: print version phparchitect magazine subscribe digital format

Link: http://www.phparch.com/2013/10/returning-to-print/

Say Hello to Boris: A Better REPL for PHP
Apr 02, 2013 @ 10:34:00

On PHPMaster.com today Shameer C has a new tutorial introducing you to Boris, a REPL (read-eval-print loop tool) that's a bit more enhanced than the basic PHP interactive shell.

As web developers, we know the importance of the JavaScript console provided by the browser in testing out code snippets. We don’t need to write an entire HTML page and JavaScript code just to verify the functioning or logic of a small routine we wrote. Instead, we simply run the expressions in the console and immediately see the results. Similarly, a REPL (Read-Eval-Print Loop) is the console of a programming language in which we can write code line-by-line and see what it does. [...] PHP’s REPL is very good in what it does, although it does have some limitations. [...] And so, Boris tries to solve these problems and other concerns as well.

He walks you through the installation (via a git clone and, later, through Composer) and shows how to run it as well as some sample output. He also shows how to make a custom command-line Boris runner and how to embed it into your application. His example of a tool that would benefit from this is a command-line web service client using Boris and Guzzle.

tagged: boris repl read eval print loop tool commandline github


Wojciech Sznapka:
Export colored Behat scenarios to PDF
Sep 04, 2012 @ 09:42:49

Wojciech Sznapka has shares his technique for creating colorized exports of Behat tests for use in PDF files:

Behat scenarios are one of the best ways to describe system. UML Use Cases or tons of pages in SRS documents are fine, but hard to understand from the begining, and even harder to maintain in the future. Behat eases this process and also gives opportunity to automate requirements verification. To write Behat scenarios you need a text editor. I’ve picked my favourite – Vim, which highlights *.feature files syntax. But business people mostly don’t use Vim, so I need to figure a way, to expose scenarios in easy and pleasant way.

His solution involves setting up some printing options in vim to export the tests as a Postscript file, setting the "colorscheme" to the default setting so the colors will be retained. The result is exported (via the "hardcopy" command) and can be converted into a PDF (with a result like this).

tagged: behat test color export postscript pdf print


Zend Developer Zone:
PHP and Java: Using Java Print Service with Zend Server Community Edition
Jun 25, 2009 @ 11:18:29

On the Zend Developer Zone today there's a new tutorial looking at combining the Zend Server (Community Edition) with the Java Print Service to make printing in your applications (something PHP's not very good at) simpler.

What if you still need to have printing support in your PHP application? With Zend Server, Zend's integrated PHP application stack, the answer might be not what you were expecting. Use the PHP Java Bridge, available in both the community and commercial editions of Zend Server.

Their method combines Java code with some native PHP code to create a "printer" and point your scripts to it. Various options and configuration file information are included as well as two scripts - one to make a simple "one image" document and another to make a more complex PDF containing an interactive form.

tagged: tutorial zendserver java print pdf


Community News:
Interview with Marco Tabini about php|architect Updates
Sep 29, 2008 @ 08:01:45

The php|architect brand is going through a major overhaul with a new website, improvements to the magazine and a few other changes around the company. I caught up with Marco Tabini (CEO of MTA) to ask him a few questions about it all:

Q: Tell me some about the update/restructuring (like what prompted the change)

A: As of December 2008, php|architect will enter its sixth year of publication. Much has changed within the PHP community - and in our company'"since we launched our magazine, and we felt that it was time to ensure that our brand and our flagship product were up-to-date with the market they serve.

The process of change actually started earlier this summer, when we launched our new line of training courses - the first truly comprehensive training program designed specifically for PHP developers. Our brand identity and the magazine were the next logical targets - particularly when you consider how long they have been around and how many people they reach every month.

In addition, one problem that we have always had with the magazine has been its publication schedule - we initially created php|architect as a PDF-only publication, and since we've switched to the print format we've been struggling with the management of our publication timelines. The unfortunate reality is that postal services throughout the world sometimes take a *really* long time to deliver third-class mail and, historically. we have never done as good a job of taking that into account as we could'"something that we intend to fix with this relaunch.

Finally, our aim with php|architect has always been to create a resource capable of providing the PHP community with the educational tools and knowledge needed by professionals who work and operate in world-class, enterprise-level environments. We felt that our current price point and distribution strategy had moved away from this core goal, and that a major adjustment was needed to bring us back on track.

Q: What does this mean for current readers/subscribers?

A: A lot of good things! First of all, the cost of a subscription goes down to as low as $29.99 for twelve issues - and that includes both the print *and* the PDF versions of the magazine. Naturally, we're going to make good on all our current subscribers and extend their subscriptions based on the cost of the magazine when they signed up for it - thus, most people should see their remaining issue counts go up considerably at no extra cost, and new subscribers will be able to finally get access to the magazine at a very reasonable price.

In addition, our current subscribers (as well as the new ones!) will enjoy better delivery times, and all the advantages that come with the new format.

Q: What all is involved in the change? Are there any changes to the magazine(s)?

A: Much of the work that is involved in the relaunch of our activities will go on behind the scenes, but visitors to our websites will note lots of changes over the coming months'"starting with a minor redesign of our site to accommodate the new logo and brand identity, as well as the new pricing and subscription strategy for the magazine.

Starting with the January issue, we are targeting a 45-day window for shipment of the magazine'"meaning that the print copies of the January issue, for example, will be mailed out to subscribers around the beginning of December - thus ensuring more prompt delivery in everybody's mailboxes. In addition, the entire magazine will switch to full-colour printing throughout - thus providing a richer experience for our users and a more challenging and fun environment for us to develop our work in. We will continue to support the PDF version using our popular DRM-free distribution and personalization system, and try to synchronize the arrival of the print issue with the release of the PDF file as closely as possible.

Also for the first time, we are publishing our editorial calendar for all of 2009. This will help readers know what's coming, advertisers better plan their campaigns and authors draw inspiration for their writing activities.

Q: Will there be new things available immediately after the change?

Once the initial brand relaunch is complete, we are planning to re-engineer our site to provide a smoother shopping experience and better account management facilities. Since we relaunched our website almost a year ago, our web-based sales have more than doubled, and our back-end infrastructure has handled the growth without any problems. On the front-end side, however, we have done a considerable amount of research on the habits and needs of our customers and have discovered areas ripe for improvements that we couldn't even imagine before, and we will be redesigning some areas of our website to reflect the lessons we have learned.

In addition, we have some great promotions planned between here and New Year's - including a comeback for our greatly popular "Seven Days of Christmas" series of offers over the holidays. We skipped 7DOX last year, and our users gave us an earful for it, so we'll make sure to keep our priorities straight this time!

The new php|architect website has already been launched along with new training courses for the Zend Framework Certified Exam.

To subscribe to the new and improved php|architect magazine, visit their subscription page and signup. Find out more in this post on their site.

tagged: community phparchitect website training print pdf magazine


Announcing our new Magento book
Apr 28, 2008 @ 13:43:41

php|architect has announced the release of a new book - the Guide to Programming Magento, now up for preorder:

We're happy to announce the upcoming release of php|architect's Guide to Programming Magento, the first comprehensive guide for developers who want to learn more about the Magento e-commerce platform.

The book, by Mark Kimsal shows you how to install and successfully deploy a Magento installation on your website. The preorder is available right now for a 15% discount and the full PDF version will be released on May 15th, 2008 (print on May 31st). Check out the product page for more information and to reserve your copy today.

tagged: magento ecommerce book release pdf print programming


PHP in Action Blog:
PHP in Action Book in Print
Jul 26, 2007 @ 07:05:00

The PHP in Action blog has a new note about something that's been a long time coming - the release of the print version of their book.

Again a somewhat belated announcement: PHP in Action is in print. [...] Strenuously objective as always, I have to say that it's a pretty good book. I've had to read it about fifteen times already, and I still sort of enjoyed it the last time.

You can get more information on the book from its page on the Manning Publishing website as well as purchase a copy - $39.99 USD for the print version (plus PDF ebook) or just $20.00 USD for the PDF ebook by itself.

tagged: phpinaction book print ebook pdf phpinaction book print ebook pdf


PHP in Action Blog:
PHP in Action Book in Print
Jul 26, 2007 @ 07:05:00

The PHP in Action blog has a new note about something that's been a long time coming - the release of the print version of their book.

Again a somewhat belated announcement: PHP in Action is in print. [...] Strenuously objective as always, I have to say that it's a pretty good book. I've had to read it about fifteen times already, and I still sort of enjoyed it the last time.

You can get more information on the book from its page on the Manning Publishing website as well as purchase a copy - $39.99 USD for the print version (plus PDF ebook) or just $20.00 USD for the PDF ebook by itself.

tagged: phpinaction book print ebook pdf phpinaction book print ebook pdf


Community News:
PHP in Action Book Released
Jul 03, 2007 @ 15:23:00

In a note from the PHP in Action blog, they point out the release of their ebook in PDF format:

Manning Publications has released the book PHP In Action as ebook in PDF format. I wrote it with help from my co-authors Marcus Baker and Chris Shiflett. The print version is due out June 30.

You can order both the ebook only or a combo of the ebook plus the print version directly from Manning.

tagged: phpinaction eboook print order release phpinaction eboook print order release