Am I really restricted by programming languages? I can imagine that, to use Bonjour, I need to have special libraries which could be not available for any language. So, then I need to use those languages which have corresponding libraries. As the second option, I can imagine, that Bonjour provide an interface which can be used almost by any language (for example Bonjour saves information in a special file or in environment variables and than I can use most of the languages to access this information).
P.S. I have a particular interest in PHP.
You will have better luck searching for "ZeroConf", which is the name of the actual protocol, rather than "Bonjour", which is Apple's specific implementation of the protocol.
Plenty of languages have ZeroConf bindings, including Java and .Net, and there's an example of using it in Python here. It uses D-Bus to talk to the daeomon. This list of bindings for D-Bus includes PHP, Python, Perl, Java, .Net, C++, Haskell, OCaml, Squeak, and plenty more besides. There's even a Pascal binding!
So no, you are not very restricted by programming languages.
Apple's Bonjour for Windows SDK is installed as a COM component, which can be called from PHP via the COM functions.
Sample code in several languages is installed with the SDK. While PHP is not one of them, the examples should be readable.
Another source of information on the API is the Bonjour documentation in the Mac OS X reference Library.
Roman, since you're particularly interested in PHP, you might checkout the php5-avahi extension: http://code.google.com/p/php5-avahi/
I've not used it yet (just begun researching this same question for myself), but it looks like what you're looking for: a way to write Bonjour (aka, Avahi, Zeroconf, Rendevous, mDNS) messaging/broadcasting/consuming in PHP.
Sadly, it looks like a fairly stagnant project (4 commits, all in 2009). Hopefully, though, it will help get you started.
Hope that helps, Benjamin