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

SitePoint PHP Blog:
Contributing to PHP: How to Contribute to PHP's Manual
Apr 11, 2016 @ 17:11:41

On the SitePoint PHP blog there's a tutorial posted helping you get started editing and updating the PHP.net documentation, one of the most widely used parts of the PHP ecosystem.

In this two-part article series, we’ll be covering how to contribute to the PHP project. This will hopefully clarify what steps need to be taken for those looking to become more involved with PHP.

This first part will be covering how to contribute to PHP’s documentation, including how to request a php.net Account and what to do once an account has been granted.

He starts with a bit about why you should contribute back to the PHP project and how the documentation is a great place to start. He then gets into the structure of the documentation, the DocBook structure it uses and points to the online editor for the first time contributors. He includes a video showing how to use the system to resolve this bug showing an incorrect MongoDB Client example. For those that would rather do it locally, he shows how to setup and configure the source and required tools. He then shows the flow of updating the documentation, building the result and verifying the update looks correct.

Finally he talks about requesting a php.net account to push the changes back upstream and provides some general tips on things like style guidelines, page ordering and correctly versioning files.

tagged: contribute project manual tutorial online local edit

Link: http://www.sitepoint.com/how-to-contribute-to-phps-documentation/

SitePoint PHP Blog:
How to Use GitHub's API with PHP
Mar 17, 2015 @ 15:11:39

The SitePoint PHP blog has a new tutorial posted showing you how to interact with the GitHub API via PHP thanks to the KnpLabs library to create a simple automation system to perform some simple tasks.

Github is one of the best ways to share code and collaborate. In this article, we are going to learn how to consume their API and how we can use it to accomplish some of our daily tasks. We are going to explore some of the daily tasks that can be accomplished through the Github API and build a small app using Laravel to illustrate the use cases. You can check the final result on Github.

They walk you through the setup of an application on the GitHub side and how to configure the related settings in your Laravel application. He shows how to bind the GitHub library to the app, set up some sample routes and build out controllers to:

  • List repositories
  • View repository content
  • Editing files
  • Viewing commits

Each item includes the code you'll need to make it happen, an example of the output you'll get from the API and how to use the data on your side in your views.

tagged: github api tutorial knplabs repository edit view content commits

Link: http://www.sitepoint.com/use-githubs-api-php/

Reddit.com:
Where can I find a free place to edit PHP code and see the results?
Jun 15, 2012 @ 14:13:49

In this recent post to Reddit.com, the question is asked "Where can I find a free place to edit PHP code and see the results?"

Hey everyone, Recently I was tasked with coming up with some code for an possible job opportunity. I'm wondering if anyone could point me to a place where I can easily write and edit PHP code and see the actual program run.

Suggestions from the comments include:

tagged: community edit code ide online execute

Link:

PHPBuilder.com:
PHP Simple HTML DOM Parser: Editing HTML Elements in PHP
Sep 08, 2011 @ 15:06:07

On PHPBuilder.com today there's a new tutorial from Vojislav Janjic about using a simple DOM parser in PHP to edit the markup even if it's not correctly W3C-formatted - the Simple HTML DOM Parser

Simple HTML DOM parser is a PHP 5+ class which helps you manipulate HTML elements. The class is not limited to valid HTML; it can also work with HTML code that did not pass W3C validation. Document objects can be found using selectors, similar to those in jQuery. You can find elements by ids, classes, tags, and much more. DOM elements can also be added, deleted or altered.

They help you get started using the parser, passing in the HTML content to be handled (either directly via a string or loading a file) and locating elements in the document either by ID, class or tag. Selectors similar to those in CSS are available. Finally, they show how to find an object and update its contents, either by adding more HTML inside or by appending a new object after it.

tagged: simple html dom parse tutorial selector find replace edit

Link:

ServerGrove Blog:
Editing Twig Templates in Dreamweaver
Mar 04, 2011 @ 16:16:28

On the ServerGrove blog today there's a new post showing how you can set up Dreamweaver to be able to edit Twig templates directly, complete with syntax highlighting.

If you are a designer working with Symfony developers you will soon encounter Twig. Twig is a template engine for PHP that has been adopted by Symfony 2, and from a designers perspective, it’s a major improvement over the way things are done in Symfony! For designers who have used templating systems like Smarty before, Twig is going to be a walk in the park, if you have not used a templating system before, Twig is a great place to start.

It's a simple two-step process to get things up and working. You just need to tell Dreamweaver that ".twig" files should be recognized as code and set up the syntax highlighting in the "MMDocumentTypes" XML configuration file (might be a little tricky for non-development types). This change tells the program to open them with HTML syntax highlighting.

tagged: edit tig template dreamweaver syntax highlight html

Link:

Webitech.net:
Create an Impressive Content Editing System with jQuery and PHP
Mar 10, 2010 @ 17:22:40

On Webitech.net there's a new tutorial showing how to combine PHP and jQuery to create a simple content editing system when you don't need a full-blown CMS to manage the pages of your site.

I'm going to show you how to use jQuery and PHP to build a content editing system that will allow you or your client to easily edit .html pages visually. [...] Our file structure is going to be really simple – just admin.php, the wymeditor package and jquery together in the demo directory.

The tool uses PHP's file_get_contents to pull in the source of the page into a textarea and edit it with jQuery and the WYM Editor. Full code is included for your cut and paste pleasure but if you need a quicker fix, you can download the source. There's also a demo to see it in action.

tagged: jquery content edit tutorial

Link:

Community News:
phpanywhere (Online PHP IDE)
Apr 29, 2009 @ 16:12:18

The phpanywhere site boasts itself as "the easiest way to bring work with you anywhere you go - without bringing anything". The free (still in beta) service offers online PHP editing through a web browser interface.

PHPanywhere is a web based free Integrated Development Environment or IDE for the PHP language, in other words it is an application that gives developers all the code editing capabilities they need to develop PHP applications online. It includes a real-time syntax code editor with support for all web formats and a powerful FTP editor.

You can add in FTP servers and pull files directly from them to edit and upload back over. You can also use the project sharing to allow others to see the current state of your code (real-time collaboration is "coming soon"). You can see screenshots of the editor interface, setting up FTP sites and modifying permissions for the files.

tagged: phpanywhere online ide edit ftp share

Link:

Jamie Hammett's Blog:
Open ID edit one page on Wordpress
Mar 20, 2009 @ 15:52:47

Want the "quick and dirty" way to get OpenID support up and running on your WordPress blog? Check out this new post from Jamie Hemmett - short, sweet and to the point.

Some of the tools you'll need are the OpenID plugin, RoleScoper, Adminimise and some knowledge of working with the WordPress files directly to add in the OpenID support. You'll also need to set up your blog to accept new registrations.

Sample code is included for "OpenID-ing" the page with a new kind of login form.

tagged: openid wordpress login example edit rolescoper adminimise

Link:

CSSGallery.info:
Textmate - php syntax check
Jan 27, 2009 @ 18:55:22

If you're a fan of the Textmate editor for the Mac platform, you might want to check out this new post from the cssgallery website. It shows how you can get your favorite editor to check your PHP syntax for you.

A nice "hidden" feature that Textmate has, is to check the syntax of the php files you are writing, and display a popup with the result. [...] Each time you save, a syntax check will be done, and a popup will show you the result

You'll need to edit the PHP bundle slightly to get things working, but that's as easy as going through the UI and changing a drop-down value to activate the check. You'll need to have a php binary where the editor can use it, but most OS X installs will have that in place anyway. Check out this image to see the end result.

tagged: textmate editor bundle edit syntax check save

Link:

DevShed:
Building Your Own Desktop Notepad Application Using PHP-GTK
Sep 23, 2008 @ 18:07:36

In this new tutorial from DevShed, they show how to take that PHP-GTK introductory knowledge a step further and create a simple desktop "notepad" application (corss-platform, of course).

If you think building a desktop application such as Notepad is difficult, think again. If you use PHP-GTK, it's almost ridiculously easy. This article will show you how. By the time you're done, you'll have a full cross-platform application in about 100 lines.

You need to already have the latest PHP-GTK version installed and have a basic knowledge of how to make an application before you start. All code is included as well as explanations as to where all of the parts go (including a simple find, time/date output, select all and how to tell if the user has modified the contents of the file).

tagged: phpgtk tutorial text edit notepad application crossplatform

Link:


Trending Topics: