News Feed
Jobs Feed
Sections



Recent Jobs

News Archive
feed this:

Andrew Eddie's Blog:
Making the most out of Code Assist in Eclipse/PDT and Zend Studio for PHP
December 01, 2011 @ 12:55:32

Andrew Eddie has posted a helpful tutorial for Eclipse users out there showing how to get the most our of code assist in Eclipse PDT/Zend Studio.

One of the powerful features of an IDE like Eclipse is the ability for it to "read" your code and give you some assistance about your API as you type. This could include things like class property or methods names, constants, functions, argument lists, and so on. Eclipse/PDT and ZendStudio do this by parsing a PHP class directly, but they also look at your docblocks and some other special comments where the raw PHP is not enough. This article is a bag of tricks that help you get the most out of code assistance using Eclipse/PDT or Zend Studio in those awkward corners of your code that you might have through previously inaccessible.

Among his tips are things like adding "@var" declarations to help with code completion, type hinting on methods/functions, using the "@property" annotation and using a "this" trick to override what class the IDE sees as the local object. ,/p>

0 comments voice your opinion now!
eclipse zendstudio ide hint trick docblock annotation codeassist



Tales of a Coder:
DocBlox - Pain Free Documentation
December 01, 2011 @ 09:56:27

On the Tales of a Coder blog there's a recent post about DocBlox, an alternative to the usual phpDocumentor for generating automatic documentation, and how it made it "pain free" for her current project.

Want to generate documentation for your PHP project, but keep putting it off? Can't be bothered wading thigh deep in documentation, screaming WHY WON'T IT WORK as you try to set it up? Look no further. DocBlox is pain free and you'll be up and running, literally in a few minutes.

She includes a guide to getting the latest DocBlox installed and configured to work with your project. The configuration is a straight-forward XML file, so changing the settings to match your needs is easy (more on the config here). Once this is configured, building your documentation is one command away. For more details on DocBlox, check out the project's website.

0 comments voice your opinion now!
docblox phpdocumentor painfree documentation docblock tutorial


Karsten Deubert's Blog:
Zend_MVC, Controller Plugins and Annotations
November 28, 2011 @ 12:02:50

Karsten Deubert has a recent post to his blog looking at annotations in Zend Framework applications to enhance functionality already in the framework.

Recently I had the idea to influence Controller Actions with annotations but discarded it with thoughts like "In PHP I will have to use reflection and some black magic to get this working which will have insane performance hits for my applications"... until I set everything up to see that it costs just 1-2ms in average per request without any form of caching.

He includes a few bits of code to show a simple annotation example (setting a layout) and the controller plugin that performs the translation. In his case, it's hard-coded to look for the "@layout" annotation in the docblock comment, but it'd be relatively trivial to extend it to a more full-featured version.

0 comments voice your opinion now!
zendframework mvc controller annotations docblock comment plugin


King Foo Blog:
Using Complex Type with Zend_Soap
September 23, 2011 @ 08:37:10

New from the King Foo blog there's a tutorial showing how to use complex types in a SOAP request with Zend_Soap, a component of the Zend Framework.

To be able to use complex types with Soap requests, they need to be fully defined in the WSDL file. Zend_Soap can automate this process, if you know how to define those complex types. Let us start without it Zend_Soap's magic and compare it with a fully discovered complex request type afterwards.

In their example, they have a collection of books (objects) that they want to send over to the web service. The code for both the server and client side are included with the WSDL automagically created by the Zend_Soap_Server component. By setting docblock comments on the properties of the Book objects, the SOAP components automatically know what types they are. Their example defines these, and sets up the web service on the other side with a classmap to define where the "tags" information for each book lies.

0 comments voice your opinion now!
zendsoap soap zendframework component autodiscover docblock


DZone.com:
There's no reason not to switch to DocBlox
September 01, 2011 @ 13:35:03

On DZone.com there's a recent post from Giorgio Sironi sharing his opinion on what should be your choice of automatic documentation generation tools in your PHP app, that there's no reason not to switch to DocBlox.

Alessandro Nadalin signals these three options for Api documentation generation, the process of extracting Api informations on classes and methods from a folder full of source code: phpDocumentor, doxygen and DocBlox. A PHP tool, faster than doxygen in implementing new features, and actively developed: these are the factors that made me choose DocBlox as my new default Api documentation mean.

He covers the installation of the tool (from its PEAR channel), some of the features it comes with, a link to their demo and some of his impressions after trying it out on his codebase.

0 comments voice your opinion now!
docblox docblock documentation opinion tool


Matthew Weier O'Phinney's Blog:
Using DocBlox
August 04, 2011 @ 08:08:36

On his blog today Matthew Weier O'Phinney has a new post looking at an alternative to some of the other PHPDoc-based documentation tools, DocBlox, a tool written in PHP.

Until a few years ago, there were basically two tools you could use to generate API documentation in PHP: phpDocumentor and Doxygen. [...] phpDocumentor is practically unsupported at this time (though a small group of developers is working on a new version), and Doxygen has never had PHP as its primary concern. As such, a number of new projects are starting to emerge as replacements.

He introduces DocBlox as one of these alternatives and points out where you can get the latest version (from one of many sources including github, PEAR or by just grabbing a release. He includes instructions on how to run the tool on your code, use it to identify missing docblock comments and how to use the class diagrams feature that gives a more visual sense of how things fit together. He also mentions changing the title of the output, using different templates and how it uses a local SQLite database to cache the parsed information about your code (making it simpler and faster to do updates in the future).

0 comments voice your opinion now!
docblox docblock comment parse introduction


Michelangelo van Dam's Blog:
Quality Assurance on PHP projects - PHPDocumentor
July 27, 2011 @ 08:51:48

Michelangelo van Dam has posted the latest in his "quality assurance in PHP projects" series today with a look at something that can make your life and documentation easier - PHPDocumentor.

Unfortunately I've come across too many lines of code that were just lines of code, no comments or annotations provided. So, in best cases I could guess the types and parameters, but in many it was too obfuscated. I already talked about usage of a code sniffer like PHP_CodeSniffer in my previous post where you can validate the usage of comments in the code. But forcing developers (using a pre-commit checker) into writing documentation with their code is not really a good thing.

He suggests using something like PHPDocumetor (there's other PHPDoc parsers including DocBlox and Doxygen out there) to automatically generate documentation for your code based on its comments, giving your developers easier web-based access to the contents. He includes some sample docblocks for a class/method and gives an example command line call to build docs based on a project. A screencast and screenshot of the generated site shows the results of the run.

0 comments voice your opinion now!
phpdocumentor docblock parse quality assurance documentation


Slawek Lukasiewicz's Blog:
Zend Framework Reflection
May 31, 2011 @ 08:18:56

Slawek Lukasiewicz has a recent post to his blog looking at a tool that comes bundled with PHP that can help you find out more about your own code (or really any other piece of code out there) - the Reflection API. In his post he looks specifically at the functionality the Zend Framework has built on top of the base PHP API.

Zend Framework has own Reflection extension. It is mostly build upon genuine PHP Reflection API and extends existing features. The completely new Zend_Reflection module feature is introspection of docBlock tags.

He includes two code examples using this component of the framework - grabbing the docblock off of a specific method (and even how to grab specific tags from inside it) and how to grab the body content out of a given method, with or without the docblock attached.

0 comments voice your opinion now!
zendframework reflection docblock method


Mike van Riel's Blog:
Introducing DocBlox
February 02, 2011 @ 13:48:14

Frustrated with some of the limitations the phpDocumentor tool has - mostly dealing with the memory issues - Mike van Riel has introduced how own tool that works similar but takes better advantage of advancements in PHP to keep things bit more manageable - Docblox.

Right before or during the Dutch PHP Conference 2010 the issue had arisen again and this time I was determined on solving it. In the end I chose to build a new Documentation Generation Application (may I coin DGA?) for PHP [...] With [a list of key] requirements written down in a small TODO file I started designing the new project (which at the time was still nameless) After spending some hours designing, coding, prototyping, designing, coding and testing is now the time to reveal the fruits of my labour: DocBlox

Currently the project is in a pre-release state but is quickly headed to a 1.0 release. The current codebase is completely able to parse files and output the results to HTML files. PDF support is planned for the future. You can find the current feature list here and can download/clone the latest source from it's github repository.

0 comments voice your opinion now!
docblox phpdocumentor parse docblock comment output


Francesco Montefoschi's Blog:
PHPADD abandoned docblocks detector
December 14, 2010 @ 13:34:34

Francesco Montefoschi has a recent post to his blog looking at a tool you could use to ensure the quality of your code comments - PHPADD, the abandoned docblock detector.

PHPADD can analyze a directory with PHP source code and detect (for each file, for each class, for each method) if the parameters in the function declaration are compatible with the parameters found in the docblock, reporting the outdated ones. This can be easily integrated in your build script and the result can be published in build result. Using Hudson, you just need HTML Publisher plugin.

The include the (super simple) installation instructions for pulling it in via the PEAR installer and running it on your codebase. There's even some sample output included. If you're interested in the source, check out (or fork) the latest code on github.

0 comments voice your opinion now!
phpadd abandoned docblock comment detector github



Community Events





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


development application test interview custom series language package community introduction release api conference phpunit manifesto opinion podcast framework symfony2 unittest

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