php-general Digest 10 Dec 2007 10:53:26 -0000 Issue 5173

Topics (messages 265593 through 265599):

Re: build a multi chat server with php
        265593 by: Børge Holen

Re: proc_open fclose streams..
        265594 by: Chris

Shipping Address on Paypal
        265595 by: Javed Chauhan
        265596 by: Chris

Mysqli support - test or complain?
        265597 by: Dave M G
        265599 by: Per Jessen

LoadXML trouble
        265598 by: Dani Castaños

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
On Sunday 09 December 2007 23:46:44 Jochem Maas wrote:
> Nathan Rixham wrote:
> > Anybody up for (or indeed see a need for) a multi threaded php
> > daemonised jabber client? Looks like an interesting challenge!
>
> u know the old saying, if you build it they will come ;-)

lol, for true...



-- 
---
Børge Holen
http://www.arivene.net

--- End Message ---
--- Begin Message ---
Nathan Rixham wrote:
Hi Guys,

Hoping somebody out there may have come across this one, possible functionality request depending on responses.


$descriptor = array(
   0 => array("pipe", "r"),
   1 => array("pipe", "w"),
   2 => array("pipe", "w")
);
$process = proc_open('mysql', $descriptor, $pipes);

fwrite($pipes[0], 'show databases;');
echo stream_get_contents($pipes[1]); //won't work, crash, time out.. nothing returns as we need to..

fwrite($pipes[0], 'show databases;');
fclose($pipes[0]); // note the fclose
echo stream_get_contents($pipes[1]);

I don't want to fclose pipes[0] though, as i want to keep it open and keep writing to it, alternating with reading from pipes[1] and [2]..
so a replacement for fclose, or an fflush on stdout that works?

The problem appears to be that nothing is returned to php until the stdin pipe is closed, even if I write hundreds of commands to it.

I think that's controlled by the process you're calling rather than a php thing.

For example, smtp connections do this until you enter a '.' on a single line.

ie the process you're calling doesn't know when to stop reading from stdin until you close the conn.

--
Postgresql & php tutorials
http://www.designmagick.com/

--- End Message ---
--- Begin Message ---
Hello Friends,

As i am integrating Paypal pro (For CC) in my site. Our client has a
merchant account. We have a kit for paypal integration with client
'credential certificate'. 

We are getting success and payment is completed.
We have a problem that shipping address is not displayed on paypal site in
merchant account in order detail page.
Ship to: tab is blank.
We tried a lot to send the shipping address from our site but could not
succeed.
So please help us to send the shipping address to the paypal so our merchant
can see the shipping address in order detail page with other details.
If any code please post it will be help to us and also to the others.

Thansk,
Javed


-- 
View this message in context: 
http://www.nabble.com/Shipping-Address-on-Paypal-tp14247826p14247826.html
Sent from the PHP - General mailing list archive at Nabble.com.

--- End Message ---
--- Begin Message ---
Javed Chauhan wrote:
Hello Friends,

As i am integrating Paypal pro (For CC) in my site. Our client has a
merchant account. We have a kit for paypal integration with client
'credential certificate'.
We are getting success and payment is completed.
We have a problem that shipping address is not displayed on paypal site in
merchant account in order detail page.
Ship to: tab is blank.
We tried a lot to send the shipping address from our site but could not
succeed.
So please help us to send the shipping address to the paypal so our merchant
can see the shipping address in order detail page with other details.
If any code please post it will be help to us and also to the others.

https://www.paypal.com/IntegrationCenter/ic_home.html

Ask paypal how to do it. They have api's and even an area for support tickets.

--
Postgresql & php tutorials
http://www.designmagick.com/

--- End Message ---
--- Begin Message ---
PHP List,

Based on what seemed to be good advice to switch to using mysqli for interacting with a MySQL database, I built a content management system that uses mysqli for all it's calls.

It works great on a lot of my servers. However, I just discovered that one web hosting service I use does not have mysqli enabled. I ran the phpinfo() command and they are running 5.2.5, but the configure command does not contain "--with-mysqli".

I would like the scripts I've written to be somewhat portable, but I'm unsure of whether or not I should assume that mysqli is in use.

I see it as being a situation of essentially two options.

One is based on the assumption that mysqli is as likely not to be available as it is to be installed. In this case I should write my scripts to test whether it exists and then use either mysqli or straight mysql commands as appropriate. If this is the way to go, what do I do to test for the existence of mysqli from within a PHP script?

The other is to assume that recent installs and upgrades of PHP > 5 should have mysqli because that's the currently preferred way of doing things, and therefore I should contact the web host and ask that they install it, or I find a different host.

Which assumption should I be proceeding with?

Thank you for any advice or assistance.

--
Dave M G

--- End Message ---
--- Begin Message ---
Dave M G wrote:

> One is based on the assumption that mysqli is as likely not to be
> available as it is to be installed. In this case I should write my
> scripts to test whether it exists and then use either mysqli or
> straight mysql commands as appropriate. If this is the way to go, what
> do I do to test for the existence of mysqli from within a PHP script?

In my opinion, that is overkill.  If you need mysqli and a provider does
not provide it, simply chose another provider.  A lot less effort.

> The other is to assume that recent installs and upgrades of PHP > 5
> should have mysqli because that's the currently preferred way of doing
> things, and therefore I should contact the web host and ask that they
> install it, or I find a different host.
> 
> Which assumption should I be proceeding with?

Find a provider/hoster that meets your requirements.  You're the
customer. 


/Per Jessen, Zürich

--- End Message ---
--- Begin Message ---
Hi list!

I have a problem with DOMDocument loadXML method. I used Windows to develop my applications, and nothing happens on it when i do something like

$xml = new DOMDocument();
$xml->loadXML( $request );

Obviously, request is not empty...

But when I have upload this code to production machine ( which runs under Debian ) it doesn't works properly, The DOMDocument Object is empty...

Any ideas?

Thank you in advance

--- End Message ---

Reply via email to