Send Windows message with PostMessage(HWND_BROAD... from PHP

XML, Perl, Python, and other languages can be discussed here, even if it isn't PHP (We might forgive you).

Moderator: General Moderators

Post Reply
lnoll
Forum Newbie
Posts: 2
Joined: Thu Dec 18, 2008 1:58 pm

Send Windows message with PostMessage(HWND_BROAD... from PHP

Post by lnoll »

I am trying to send a Windows message from a PHP script using PostMessage(HWND_BROADCAST... but having no success. I built a small console exe that sends the message and it works fine from the Windows command line. But when I call the exe from PHP with system, exec, passthru, shell_exec, I can get the writeln string that the exe generates on completion back to PHP but the message is not detected by my monitoring exe.

My goal is to alert an exe when a MySql table's contents are modified by PHP. MySql doesn't provide any means that I've found. So I was trying to send something from the PHP script after it modifies the table.

I am using xampp 1.6.8 PHP and MySql versions and Windows XP.

Any ideas?

+Les
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

Re: Send Windows message with PostMessage(HWND_BROAD... from PHP

Post by alex.barylski »

Have you tried SendMessage?
lnoll
Forum Newbie
Posts: 2
Joined: Thu Dec 18, 2008 1:58 pm

Re: Send Windows message with PostMessage(HWND_BROAD... from PHP

Post by lnoll »

I just tried SendMessage and it doesn't get through either. I am going to try UDP sockets instead, for which PHP has a define function.
Post Reply