php-general Digest 20 Feb 2011 12:45:28 -0000 Issue 7191

Topics (messages 311443 through 311458):

Re: chat facebook
        311443 by: Brian Waters
        311445 by: fakessh .
        311446 by: fakessh .
        311448 by: Daniel Brown

Array from one form to other?
        311444 by: Yogesh
        311447 by: Daniel Brown
        311449 by: Yogesh
        311450 by: Daniel Brown

Re: New to list and to PHP
        311451 by: Daniel Brown
        311453 by: David Robley
        311454 by: David Hutto

Re: Connection Handling - unreliable at best?
        311452 by: Daniel Brown

Accessing multi-word properties
        311455 by: Florin Jurcovici
        311458 by: bender

Re: 9970318527584
        311456 by: Vlatko Šurlan

Short XDebug tracing video on Youtube
        311457 by: Vlatko Šurlan

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 ---
2011/2/19 fakessh @ <[email protected]>:
> anyone have a recipe for it on facebook chat

a recipe for what?

> and I request a second thing
> how to install PHP API

you're going to have to be more specific than that.

- BW

--- End Message ---
--- Begin Message ---
I'm looking script already written to facebook chat.
I think it must already exist free applications for facebook chat

many return are welcome
Le samedi 19 février 2011 à 18:55 -0500, Brian Waters a écrit :
> 2011/2/19 fakessh @ <[email protected]>:
> > anyone have a recipe for it on facebook chat
> 
> a recipe for what?
> 
> > and I request a second thing
> > how to install PHP API
> 
> you're going to have to be more specific than that.
> 
> - BW
> 
-- 
gpg --keyserver pgp.mit.edu --recv-key 092164A7
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x092164A7

Attachment: signature.asc
Description: Ceci est une partie de message numériquement signée


--- End Message ---
--- Begin Message ---
I just install 
jaxl [1]
http://abhinavsingh.com/blog/2010/08/jaxl-2-0-installation-usage-guide-and-example-apps/
and echobot.php 

and I test a connection with facebook. 
and oddly despite changes in the code echobot.php 
I can not make a connection to the facebook chat
with the correct authentification 

Le dimanche 20 février 2011 à 02:11 +0100, fakessh @ a écrit :
> I'm looking script already written to facebook chat.
> I think it must already exist free applications for facebook chat
> 
> many return are welcome
> Le samedi 19 février 2011 à 18:55 -0500, Brian Waters a écrit :
> > 2011/2/19 fakessh @ <[email protected]>:
> > > anyone have a recipe for it on facebook chat
> > 
> > a recipe for what?
> > 
> > > and I request a second thing
> > > how to install PHP API
> > 
> > you're going to have to be more specific than that.
> > 
> > - BW
> > 
-- 
gpg --keyserver pgp.mit.edu --recv-key 092164A7
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x092164A7

Attachment: signature.asc
Description: Ceci est une partie de message numériquement signée


--- End Message ---
--- Begin Message ---
2011/2/19 fakessh @ <[email protected]>:
> I just install
> jaxl [1]
> http://abhinavsingh.com/blog/2010/08/jaxl-2-0-installation-usage-guide-and-example-apps/
> and echobot.php
>
> and I test a connection with facebook.
> and oddly despite changes in the code echobot.php
> I can not make a connection to the facebook chat
> with the correct authentification

    Then ask in their forums.  Just because it's written in PHP
doesn't mean we can, want to, or will help you.

-- 
</Daniel P. Brown>
Network Infrastructure Manager
Documentation, Webmaster Teams
http://www.php.net/

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

I have two forms. One form helps read an input file into an array. And the
other form needs this array as an input.
I am able to read the input file into an array, but how do I pass it over to
the other form.

Both forms have PHP file as 'action'.

Please help. Thanks

- Yogesh

--- End Message ---
--- Begin Message ---
On Sat, Feb 19, 2011 at 19:38, Yogesh <[email protected]> wrote:
> Hello,
>
> I have two forms. One form helps read an input file into an array. And the
> other form needs this array as an input.
> I am able to read the input file into an array, but how do I pass it over to
> the other form.
>
> Both forms have PHP file as 'action'.

    What's the method?  GET or POST?

-- 
</Daniel P. Brown>
Network Infrastructure Manager
Documentation, Webmaster Teams
http://www.php.net/

--- End Message ---
--- Begin Message ---
POST





On Sat, Feb 19, 2011 at 9:44 PM, Daniel Brown <[email protected]> wrote:

> On Sat, Feb 19, 2011 at 19:38, Yogesh <[email protected]> wrote:
> > Hello,
> >
> > I have two forms. One form helps read an input file into an array. And
> the
> > other form needs this array as an input.
> > I am able to read the input file into an array, but how do I pass it over
> to
> > the other form.
> >
> > Both forms have PHP file as 'action'.
>
>     What's the method?  GET or POST?
>
> --
> </Daniel P. Brown>
> Network Infrastructure Manager
> Documentation, Webmaster Teams
> http://www.php.net/
>

--- End Message ---
--- Begin Message ---
On Sat, Feb 19, 2011 at 21:50, Yogesh <[email protected]> wrote:
> POST

    Use cURL, look into curl_setopt(), and add square brackets (and
optional key names) to your array.  A quick start:

<?php
$ch = curl_init();
curl_setopt(CURLOPT_POST,1);
curl_setopt(CURLOPT_POSTFIELDS,'firstArr[]=apple&firstArr[]=orange&firstArr[]=banana&secondArr[one]=foo&secondArr[two]=bar');
// etc.
?>

-- 
</Daniel P. Brown>
Network Infrastructure Manager
Documentation, Webmaster Teams
http://www.php.net/

--- End Message ---
--- Begin Message ---
On Fri, Feb 18, 2011 at 14:03, Pete Woodhead <[email protected]> wrote:
> Hi I'm Pete Woodhead.  I'm new to the list and to PHP.  To be honest I very
> new to code writing.
> Thought this would be a good way to learn good habits as well as good code
> writing.
> Looking forward to learning and participating.

    Fantastic.  As the new guy, you're expected to sweep the floors
here each Tuesday and Saturday evening.  Lesson one: buy a broom.

-- 
</Daniel P. Brown>
Network Infrastructure Manager
Documentation, Webmaster Teams
http://www.php.net/

--- End Message ---
--- Begin Message ---
Daniel Brown wrote:

> On Fri, Feb 18, 2011 at 14:03, Pete Woodhead <[email protected]>
> wrote:
>> Hi I'm Pete Woodhead.  I'm new to the list and to PHP.  To be honest I
>> very new to code writing.
>> Thought this would be a good way to learn good habits as well as good
>> code writing.
>> Looking forward to learning and participating.
> 
>     Fantastic.  As the new guy, you're expected to sweep the floors
> here each Tuesday and Saturday evening.  Lesson one: buy a broom.
> 
A shovel might also be useful - Dan forgot to mention the stables...



Cheers
-- 
David Robley

On a radiator repair shop: Best place to take a leak.
Today is Sweetmorn, the 51st day of Chaos in the YOLD 3177. 


--- End Message ---
--- Begin Message ---
On Sat, Feb 19, 2011 at 11:14 PM, David Robley <[email protected]> wrote:
> Daniel Brown wrote:
>
>> On Fri, Feb 18, 2011 at 14:03, Pete Woodhead <[email protected]>
>> wrote:
>>> Hi I'm Pete Woodhead.  I'm new to the list and to PHP.  To be honest I
>>> very new to code writing.
>>> Thought this would be a good way to learn good habits as well as good
>>> code writing.
>>> Looking forward to learning and participating.
>>
>>     Fantastic.  As the new guy, you're expected to sweep the floors
>> here each Tuesday and Saturday evening.  Lesson one: buy a broom.
>>
> A shovel might also be useful - Dan forgot to mention the stables...
>
>
>
> Cheers
> --
> David Robley
>
> On a radiator repair shop: Best place to take a leak.
Right next to the soldering station and the freon vat?

> Today is Sweetmorn, the 51st day of Chaos in the YOLD 3177.
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



-- 
According to theoretical physics, the division of spatial intervals as
the universe evolves gives rise to the fact that in another timeline,
your interdimensional counterpart received helpful advice from me...so
be eternally pleased for them.

--- End Message ---
--- Begin Message ---
On Fri, Feb 18, 2011 at 10:21, James Green <[email protected]> wrote:
> Been reading through
> http://uk.php.net/manual/en/features.connection-handling.php and
> trying to implement a solution using it. So far the documented
> behaviour rarely occurs.
>
> This code is a minimal test case: http://codepad.org/GqNlcWiM
>
> I run this behind Apache 2.2 with PHP 5.3 on Linux. The in-line
> comments explain the problem. I load in the browser and hit stop
> pretty much immediately but PHP does not get signalled that the user
> has aborted and continues.
>
> From memory of having to restart apache after hitting long-running
> scripts in the past, I don't ever believe I've had a script terminate
> on a user abort. And I've never switched the behaviour from default.
>
> I read several people explain this behaviour would only ever work in
> writing back to the client and to flush the buffer, which is included
> in the test case. I've also removed any compression from within
> Apache.
>
> Can anyone explain what I've seeing? I've tried this using Lighttpd/Windows 
> too.

    Look at line #4.  You're telling PHP that you don't give a damn if
someone tries to quit, you're going to continue anyway.  You storm
trooper, you.

    If PHP is instructed to ignore the user's (futile) attempts to
abort, why should it try to gentlemanly and politely respect a
shutdown function?  Essentially, you're damning it to zombiehood.

-- 
</Daniel P. Brown>
Network Infrastructure Manager
Documentation, Webmaster Teams
http://www.php.net/

--- End Message ---
--- Begin Message ---
Hi.

I have a JSON, let's say "{\"a b\": 13}".

json_decode() handles it properly. However, then resulting object has
a property composed of two words.

What I did to access this property was the following:

$json = "{\"a b\": 13}";
$decoded = json_decode($json);
$tag = "a b";
print($decoded->$tag);

However, this seems clumsy. Is there another, nicer way to access
multi-word props in PHP? I suppose there should be, due to the loosely
typed nature of PHP, where everything is a map, but I couldn't find
it.

br,

flj

-- 
Fine counsel is confusing, but example is always clear. (Edgar A.
Guest, The Light of Faith)

--- End Message ---
--- Begin Message ---
Am 20.02.2011 11:32, schrieb Florin Jurcovici:
Hi.

I have a JSON, let's say "{\"a b\": 13}".

json_decode() handles it properly. However, then resulting object has
a property composed of two words.

What I did to access this property was the following:

$json = "{\"a b\": 13}";
$decoded = json_decode($json);
$tag = "a b";
print($decoded->$tag);

However, this seems clumsy. Is there another, nicer way to access
multi-word props in PHP? I suppose there should be, due to the loosely
typed nature of PHP, where everything is a map, but I couldn't find
it.

br,

flj


Ahoi,


print($decoded->{"a b"});


Gruß

--- End Message ---
--- Begin Message ---
John Taylor-Johnston wrote:
9970318527584
Could this number refer to a date()? In late 2009?
How could I calculate it?

How did you get the number?

--- End Message ---
--- Begin Message --- I've just posted a short tracing tutor on youtube. It details how to quickly use XDebug tracing to answer questions like 'Where did this value appear for the first time?' This stuff is very useful when you are facing large unfamiliar codebase and need to quickly find your way around. I've also included reference to my backport of XDebug to Debian stable which includes the GET trigger for the trace functionality.

The video is here: http://www.youtube.com/watch?v=WBDh4VpuLWM
The bug report where I posted my backport is here: 
http://bugs.xdebug.org/view.php?id=517 (look at the bottom)

--- End Message ---

Reply via email to