Win32API extension for PHP Cool Windows Stuff for PHP
Aren’t Desktop Apps Dead? <ul><li>People aren’t always online </li></ul><ul><li>Some applications would be bandwidth prohi...
PHP Advantages <ul><li>No Compiling </li></ul><ul><li>Instant Changes </li></ul><ul><li>No learning curve for a new langua...
PHP Disadvantages <ul><li>Speed </li></ul><ul><li>Additional Extensions/Libraries needed </li></ul><ul><li>Speed </li></ul...
So what are your options? <ul><li>PHP-GTK2 </li></ul><ul><li>PHP-QT </li></ul><ul><li>PHP-WxWidgets (vaporware) </li></ul>...
Things to Decide <ul><li>OS support  (only PHP-GTK2 is truly cross-platform at the moment – you can even run it on Solaris...
What has gone Before <ul><li>What *nix has that we don’t </li></ul><ul><li>Semaphores </li></ul><ul><li>Shared Memory (not...
What’s Hiding in PECL <ul><li>Win32Std – resource files as streams, basic dialog boxes, registry access </li></ul><ul><li>...
Reinventing the Wheel <ul><li>Problems with Winbinder </li></ul><ul><li>Thread safety issues </li></ul><ul><li>PHP4 style ...
So what works? <ul><li>PHP 5.3 target  (we will release when they do) </li></ul><ul><li>NAMESPACES </li></ul><ul><li>Intel...
Beyond Thunderdome <ul><li>Goal is ALL (and I do mean all) of the win32api </li></ul><ul><li>An extension system (similar ...
Resources <ul><li>http://svn.bluga.net/win32api </li></ul><ul><li>Subversion repository </li></ul><ul><li>http://gtk.php.n...
Upcoming SlideShare
Loading in …5
×

Win32 api extension for php

2,254 views
2,113 views

Published on

My first talk ever, given at the Microsoft Web Dev Summit in 2007

Project is now winapiforphp on bitbucket

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,254
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
3
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Win32 api extension for php

  1. 1. Win32API extension for PHP Cool Windows Stuff for PHP
  2. 2. Aren’t Desktop Apps Dead? <ul><li>People aren’t always online </li></ul><ul><li>Some applications would be bandwidth prohibitive </li></ul><ul><li>Some data is too sensitive to be passed on the wire </li></ul><ul><li>Embedded OS’s don’t always work well with websites </li></ul><ul><li>Browsers are just Quirky (I’m looking at you, IE6) </li></ul>
  3. 3. PHP Advantages <ul><li>No Compiling </li></ul><ul><li>Instant Changes </li></ul><ul><li>No learning curve for a new language </li></ul><ul><li>Plug into PHP extensions </li></ul><ul><li>Easy to Use </li></ul><ul><li>Fast to Write </li></ul>
  4. 4. PHP Disadvantages <ul><li>Speed </li></ul><ul><li>Additional Extensions/Libraries needed </li></ul><ul><li>Speed </li></ul><ul><li>Distribution (phar is helpful there) </li></ul><ul><li>Speed </li></ul><ul><li>Security </li></ul><ul><li>(do you see a theme?) </li></ul>
  5. 5. So what are your options? <ul><li>PHP-GTK2 </li></ul><ul><li>PHP-QT </li></ul><ul><li>PHP-WxWidgets (vaporware) </li></ul><ul><li>Winbinder (so not thread safe) </li></ul><ul><li>Win32API – Win::Ui </li></ul><ul><li>Who is your audience? </li></ul>
  6. 6. Things to Decide <ul><li>OS support (only PHP-GTK2 is truly cross-platform at the moment – you can even run it on Solaris if you’re insane) </li></ul><ul><li>Distribution mechanism (you need to distribute PHP, your extension, plus your code) </li></ul><ul><li>Upgrading </li></ul><ul><li>Security </li></ul><ul><li>Size </li></ul>
  7. 7. What has gone Before <ul><li>What *nix has that we don’t </li></ul><ul><li>Semaphores </li></ul><ul><li>Shared Memory (not shmop) </li></ul><ul><li>IPC Functions </li></ul><ul><li>Process Control Functions </li></ul>
  8. 8. What’s Hiding in PECL <ul><li>Win32Std – resource files as streams, basic dialog boxes, registry access </li></ul><ul><li>Win32service – services control </li></ul><ul><li>Win32scheduler – windows scheduled tasks </li></ul><ul><li>Win32ps - PSAPI (Process Status Helper) to get information </li></ul><ul><li>IISfunc - Provides IIS functions </li></ul>
  9. 9. Reinventing the Wheel <ul><li>Problems with Winbinder </li></ul><ul><li>Thread safety issues </li></ul><ul><li>PHP4 style API </li></ul><ul><li>No BC breaks allowed </li></ul><ul><li>Few developers </li></ul><ul><li>Differences in Direction </li></ul>
  10. 10. So what works? <ul><li>PHP 5.3 target (we will release when they do) </li></ul><ul><li>NAMESPACES </li></ul><ul><li>Intelligent, easy to use message handling using callbacks </li></ul><ul><li>Locking CLI into a loop (modal process) </li></ul><ul><li>Garbage Collection!! </li></ul>
  11. 11. Beyond Thunderdome <ul><li>Goal is ALL (and I do mean all) of the win32api </li></ul><ul><li>An extension system (similar to PHP’s extensions) that allow only the “modules” of the API you intend to use </li></ul><ul><li>Low level system items (such as threads, processes, IPC) are the “core” and available in all SAPIS </li></ul><ul><li>Some features (Win::Ui) are specific to certain SAPI’s (embed, CLI) </li></ul>
  12. 12. Resources <ul><li>http://svn.bluga.net/win32api </li></ul><ul><li>Subversion repository </li></ul><ul><li>http://gtk.php.net </li></ul><ul><li>PHP-GTK2 Extension </li></ul><ul><li>http://php-qt.org </li></ul><ul><li>PHP-QT Extension </li></ul><ul><li>http://perisama.net </li></ul><ul><li>Windows Builds for all kinds of PHP stuff (win32api binaries to play will be here) </li></ul>

×