 | News Feed |
 | Jobs Feed |
Sections
|
| feed this: |  |
PHPMaster.com: Create a Poll with PHPixie
by Chris Cornutt February 05, 2013 @ 12:53:44
PHPMaster.com has a new tutorial posted showing you how to create a simple poll using the PHPixie PHP framework, a MySQL backend and a little bit of Javascript.
When choosing a PHP framework you need to make sure that it emphasizes features which are the most important to you. If you are looking for something fast, simple, and easy to learn than PHPixie may be a perfect choice. To illustrate the basics of developing with PHPixie we will create a small polling application. By the end of this tutorial you will have a working poll application and an understanding of how easy it is to code projects using PHPixie.
They provide you with all of the parts you'll need - the database table definition, the code for the modules/views/controllers and the Javascript to handle the addition of new options. You can find the full code on the PHPMaster github account.
voice your opinion now!
poll phpixie framework mvc tutorial javascript
PHPMaster.com: Authenticate Users with Mozilla Persona
by Chris Cornutt December 03, 2012 @ 11:18:09
On PHPMaster.com there's a new tutorial from Vito Tardia about using the Mozilla Persona authentication system in your PHP application - an abstracted authentication system that keeps only a token representing the user in your system.
Mozilla Persona is built upon the BrowserID technology also developed by Mozilla. You can find an expanded explanation of the concepts in the article How BrowserID Works by Lloyd Hilaiel. [...] An email address is an identity and it's verified by the email provider [then the] authentication takes place in the browser.
He talks about the three steps in the process (certificate provisioning, assertion generation and assertion verification) and includes some sample code that does the work for you with some PHP, HTML and Javascript. In his example he just authenticates the user and returns the success/fail back to the calling script. You could take it one step further and integrate it with the session handler as well.
voice your opinion now!
authenticate user mozilla persona javascript sso browserid
Grzegorz Godlewski: PHP.Kryptik.AB - Give me your FTP!
by Chris Cornutt November 20, 2012 @ 14:14:04
Grzegorz Godlewski has written up a post about a piece of PHP-related malware that, if it gets into your application, can render your site inaccessible (not to mention blocked by Google's "safe browsing") - PHP.Kryptik.AB.
One could think a PHP Developer is free from viruses and malware - and be wrong. Meet PHP.Kryptik.AB - the PHP malware. If you already know this bastard - high five! But if you don't - be prepared! Basically the story starts from a standard computer trojan which (I suppose) attacks popular FTP clients that store FTP login credentials unencrypted. Then it sends fetched informations to a remote host which (by the cover of night) logs into the FTP servers and infects PHP base web-pages by injecting a piece of JavaScript code, that gets executed when a user enters a site.
He describes the injected code, what kind of files the malware looks for when it executes and how you can fix the problem if you've already been infected. There's also a bit about how you can prevent yourself from being infected (including the suggestion of using something like KeePass or 1Password to manage and create harder to crack passwords).
voice your opinion now!
malware javascript infect phpkryptikab ftp
NetTuts.com: 20 All Too Common Coding Pitfalls For Beginners
by Chris Cornutt November 12, 2012 @ 14:52:59
On NetTuts.com there's a great list of tips and things to keep in mind if you're a budding programmer - a set of common pitfalls to watch out for as you hone your skills.
Regardless of our current skill level, we all were beginners at one point in time. Making classic beginner mistakes comes with the territory. Today, we've asked a variety of Nettuts+ staff authors to chime in with their list of pitfalls and solutions - in a variety of languages. Learn from our mistakes; don't do these things!
The article starts off with some Javascript tips, but quickly gets into some more PHP specific things like:
- Use Ternary When Appropriate
- Use Guard Clauses
- Keep Methods Maintainable
- Avoid Deep Nesting
- Don't Overuse Variables
There's also two "extras" thrown in more concerning general programming practices - using methods to represent actions and some basic code readability suggestions.
voice your opinion now!
common issue beginner developer javascript general
We Love PHP Blog: Using V8 Javascript engine as a PHP extension
by Chris Cornutt July 25, 2012 @ 11:50:36
From the "Web Love PHP" blog there's a new post showing how to use the V8 Javascript engine as a PHP extension in your application.
Just got to something described as: This extension embeds the V8 Javascript Engine into PHP. It is called v8js and the documentation is already available on php.net, examples and the sources are here. V8 is known to work well in browsers and webservers like node.js, but does it work inside PHP? YES!
They show how to get it installed (on Ubuntu) via a PECL install and a test script with some Javascript in a string variable that's parsed by the "executeString" function on a V8 object. There's also an example of how you can mix the functionality between the two - a simple script that uses a PHP PDO object fron inside the Javascript to perform a SQL query and set some information into the session.
voice your opinion now!
v8 javascript extension integration tutorial
Jeff Carouth's Blog: Micro Framework and JavaScript Applications
by Chris Cornutt July 06, 2012 @ 14:26:48
Jeff Carouth has posted some of his thoughts about the PHP micro-framework and Javascript combination (following a recent presentation on the subject).
As I mentioned, I was accepted as a speaker at LoneStarPHP 2012 to give a session on MicroPHP Framework and JavaScript Applications. The session went reasonably well and I received some decent feedback both at the conference and on joind.in. I will address a couple issues with the talk to, hopefully, inspire you as I intended with this talk.
He talks about some of the things that need fixing about his presentation (like the lack of time to get into the needed depth) and how his talk should "inspire the attendees" to create apps with this powerful combination. His goal was to describe the use of the micro-framework (Slim) as a RESTful interface into your application, not to make the application inside of it.
He also mentions that maybe making an introduction to the MicroPHP Manifesto and describing how to use a framework that applies to it in one shot might have been too much.
voice your opinion now!
microframework javascript presentation lsp12 followup
|
Community Events
Don't see your event here? Let us know!
|