Re: [PHP] concatenating

2011-08-11 Thread Andre Polykanine
Hello Chris, CS> Is it possible to concatenate a string and an element from a CS> mysql_fetch_assoc array? I haven't had much luck searching google. CS> Such as concatenating "results" with ' . $posts_row['store_tptest'] . CS> ' so that if there are no elements returned nothing will be d

Re: [PHP] concatenating

2011-08-10 Thread Ken Robinson
At 12:03 AM 8/11/2011, Chris Stinemetz wrote: Is it possible to concatenate a string and an element from a mysql_fetch_assoc array? I haven't had much luck searching google. Such as concatenating "results" with ' . $posts_row['store_tptest'] . ' so that if there are no elements returned nothing

Re: [PHP] concatenating

2011-08-10 Thread Negin Nickparsa
read the manual http://www.php.net/manual/en/ref.strings.php A comprehensive concatenation function, that works with array and strings $arg) { if(is_array($arg)) { if(!isset($dim)) $dim = count($arg) ; elseif($dim != count($arg)) return FALSE ; $args[$key] =

Re: [PHP] Concatenating PDF using FPDI

2008-09-29 Thread giga501
Bastien - Thanks for the tip. I tried setting auto_detect_line_endings=ON on my PHP.ini file (I am on a shared host - siteground), but the problem persists. The auto_detect_line_endings parameter on my local machine is OFF. Bastien Koert-3 wrote: > > On Sun, Sep 28, 2008 at 3:33 AM, giga

Re: [PHP] Concatenating PDF using FPDI

2008-09-28 Thread Bastien Koert
On Sun, Sep 28, 2008 at 3:33 AM, giga501 <[EMAIL PROTECTED]> wrote: > > Hi - > > I am trying to attach a pre-defined PDF to a file generated at runtime > (invoice.pdf). > I have attached the test.php that I used to concatenate 2 pdfs. > http://www.nabble.com/file/p19709464/test.php test.php > > I

Re: [PHP] concatenating with "." or ","

2008-08-27 Thread Robert Cummings
On Wed, 2008-08-27 at 13:13 -0400, tedd wrote: > At 12:17 PM -0400 8/27/08, Robert Cummings wrote: > >What does random have to do with > > Oh no! > > Someone mentioned the R word in front of Rob. > > We should put this in a list of things not to do on this list. *heheh* well in the above I'm no

Re: [PHP] concatenating with "." or ","

2008-08-27 Thread tedd
At 12:17 PM -0400 8/27/08, Robert Cummings wrote: What does random have to do with Oh no! Someone mentioned the R word in front of Rob. We should put this in a list of things not to do on this list. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.

Re: [PHP] concatenating with "." or ","

2008-08-27 Thread Robert Cummings
On Wed, 2008-08-27 at 12:27 +0200, Bernhard Kohl wrote: > tedd wrote: > > There are significant orders of magnitude difference between your results > > and mine. > > For example, it didn't make any difference if you used a comma or > > concatenation, but in my system concatenation was 15 times fast

Re: [PHP] concatenating with "." or ","

2008-08-27 Thread tedd
At 7:56 PM -0600 8/26/08, Govinda wrote: I never thanked all the people who answered my Q in so many helpful ways and on so many levels.I see that this list if chock full of really quality people with loads of expertise and many other fine qualities (tedd sperling's broad perspective, for o

Re: [PHP] concatenating with "." or ","

2008-08-27 Thread Bernhard Kohl
tedd wrote: > There are significant orders of magnitude difference between your results > and mine. > For example, it didn't make any difference if you used a comma or > concatenation, but in my system concatenation was 15 times faster than using > a comma. Interesting, I would have guessed it woul

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread Robert Cummings
On Tue, 2008-08-26 at 19:56 -0600, Govinda wrote: > >> > I never thanked all the people who answered my Q in so many helpful > ways and on so many levels.I see that this list if chock full of > really quality people with loads of expertise and many other fine > qualities (tedd sperling's

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread Govinda
I never thanked all the people who answered my Q in so many helpful ways and on so many levels.I see that this list if chock full of really quality people with loads of expertise and many other fine qualities (tedd sperling's broad perspective, for one) ... I would be tempted to than

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread Yeti
>> Bernhard wrote: >> echo $test_string, $array_value; It seems like they echoed them -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread Robert Cummings
On Tue, 2008-08-26 at 12:07 -0400, tedd wrote: > At 10:37 PM +0200 8/25/08, Bernhard Kohl wrote: > ># Ok tedd, if you insist .. > > Bernhard: > > I wasn't insisting, but it's nice you picked up the Gauntlet. > > Good work and it validates (but of course, you didn't think I would check?). > > Yo

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread Lupus Michaelis
tedd a écrit : The cycle of programming continues. And the algorithm era crunch down ;) The test isn't accurate because it focuses on two strings of the same length. And all programmers know that some algorithms depends on the size of the data handled, and the number of it. Obviously,

Re: [PHP] concatenating with "." or ","

2008-08-26 Thread tedd
At 10:37 PM +0200 8/25/08, Bernhard Kohl wrote: # Ok tedd, if you insist .. Bernhard: I wasn't insisting, but it's nice you picked up the Gauntlet. Good work and it validates (but of course, you didn't think I would check?). Your results: Comma took: 0.0191585 milliseconds on average. Conca

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Bernhard Kohl
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> http://www.w3.org/1999/xhtml";> Test for Tedd Comma took: '.(abs($e_t - $s_t)*1000/$iterations).' milliseconds on average.'; # <-- Concatenation ob_start(); $s_t = microtime(true); foreach ($test_array as $array_value) {

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread tedd
At 5:34 PM +0200 8/25/08, Yeti wrote: That is why i love this list. Always something new to learn. What I am still wondering about is if it is faster to use commas or the "{}" brackets? ( I don't know how that technique is called, since I'm not a walking dictionary) Example: $var = "blah blah";

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Robert Cummings
On Mon, 2008-08-25 at 17:34 +0200, Yeti wrote: > That is why i love this list. Always something new to learn. > What I am still wondering about is if it is faster to use commas or > the "{}" brackets? ( I don't know how that technique is called, since > I'm not a walking dictionary) Here is the or

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Yeti
That is why i love this list. Always something new to learn. What I am still wondering about is if it is faster to use commas or the "{}" brackets? ( I don't know how that technique is called, since I'm not a walking dictionary) Example: $var = "blah blah"; echo $var,"test"; echo "{$var}test"; -

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Stut
On 25 Aug 2008, at 16:09, Govinda wrote: Good, understood. To deepen (for me): why does this: echo '$_POST[\'SNGstep\']='.var_dump($_POST['SNGstep']).'^p>'."\n"; spit out: "NULL $_POST['SNGstep']=^" while this: echo '$_POST[\'SNGstep\']=',var_dump($_POST['SNGstep']),'^p>'."\n"; spits out: "$

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Govinda
Good, understood. To deepen (for me): why does this: echo '$_POST[\'SNGstep\']='.var_dump($_POST['SNGstep']).'^'."\n"; spit out: "NULL $_POST['SNGstep']=^" while this: echo '$_POST[\'SNGstep\']=',var_dump($_POST['SNGstep']),'^'."\n"; spits out: "$_POST['SNGstep']=NULL ^" ? I think it must be

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Andreas J.
hi, here it is described in detail: http://blog.libssh2.org/index.php?/archives/28-How-long-is-a-piece-of-string.html Govinda schrieb: easy to find our about concatenating with "." in the docs... but not so with "," what is the difference? -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] concatenating with "." or ","

2008-08-25 Thread Thiago Melo de Paula
Govinda, please, consider the following code: With that, you can see that the comma isn't a concatenation symbol as the period. When you use it with echo, you're actually passing more than one argument to the echo construct (why construct and not function? please, refer to http://us.php.net/ma

Re: [PHP] concatenating strings

2004-05-22 Thread Matt
> From: "Richard Davey" <[EMAIL PROTECTED]> Saturday, May 22, 2004 6:46 AM > Subject: Re: [PHP] concatenating strings > BF> how do I add newline commands in the middle of a text string? > > $message = "My name is " . $myname . "\nMy favorite color

Re: [PHP] concatenating strings

2004-05-22 Thread Richard Davey
Hello Bill, Saturday, May 22, 2004, 11:43:17 AM, you wrote: BF> how do I add newline commands in the middle of a text string? BF> How do I write it so the email message text is on two lines, BF> My name is BILL BF> My favorite color is RED $message = "My name is " . $myname . "\nMy favorite col

RE: [PHP] concatenating 2 resultsets [SOLVED]

2004-03-15 Thread Angelo Zanetti
solved guys -Original Message- From: Angelo Zanetti [mailto:[EMAIL PROTECTED] Sent: Monday, March 15, 2004 12:30 PM To: [EMAIL PROTECTED] Subject: [PHP] concatenating 2 resultsets Hi all, is it possible to concatenate two resultsets, to form a big resultset. both resultsets will return

Re: [PHP] concatenating 2 resultsets

2004-03-15 Thread Marek Kilimajer
Angelo Zanetti wrote: Hi all, is it possible to concatenate two resultsets, to form a big resultset. What database are you using? both resultsets will return the same columns. eg query 1 returns NAME| ADDRESS| EMAIL query 2 returns NAME| ADDRESS| EMAIL but they have different data however the

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread Ankur Verma
you will need to use "\r\n" instead of only "\n", I guess hope that helps best regards Ankur Verma HCL Technologies A1CD, Sec -16 Noida, UP India - Original Message - From: "Larry Rosenman" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, February 15, 2001 12:51 AM Subject

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread Larry Rosenman
* CC Zona <[EMAIL PROTECTED]> [010214 21:21]: > [restored to bottom-posting, for clarity] > > > > > I was trying to build up a multi-line body to use with the mail > > > > command, using code similar to: > > > > $mailbody = $mailbody . '\n' . $HTTP_POST_VARS["somefield"]; > > > > > >

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread CC Zona
[restored to bottom-posting, for clarity] > > > I was trying to build up a multi-line body to use with the mail > > > command, using code similar to: > > > $mailbody = $mailbody . '\n' . $HTTP_POST_VARS["somefield"]; > > I think you can do it like this: > > > > $mailbody="$varname\n$

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread 'Larry Rosenman'
* Janet Valade <[EMAIL PROTECTED]> [010214 18:33]: > I think you can do it like this: > > $mailbody="$varname\n$varname2"; That works. Hmm. I wonder why the concatenation didn't? Thanks! LER > > Janet > > > > -Original Message- > > From: Larry Rosenman [SMTP:[EMAIL PROTECTED

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread Larry Rosenman
* Lewis Bergman <[EMAIL PROTECTED]> [010214 13:50]: > On Wed, 14 Feb 2001, you wrote: > > Greetings, > > I was trying to build up a multi-line body to use with the mail > > command, using code similar to: > > $mailbody = $mailbody . '\n' . $HTTP_POST_VARS["somefield"]; > > > > when I s

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread Larry Rosenman
* Christian Cresante <[EMAIL PROTECTED]> [010214 13:27]: > You need to use "\n" for interpolation. Tried that too... Didn't work for me... > > --- Larry Rosenman <[EMAIL PROTECTED]> wrote: > > Greetings, > > I was trying to build up a multi-line body to > > use with the mail > > command, usi

Re: [PHP] concatenating strings and \n's for mail...

2001-02-14 Thread Christian Cresante
You need to use "\n" for interpolation. --- Larry Rosenman <[EMAIL PROTECTED]> wrote: > Greetings, > I was trying to build up a multi-line body to > use with the mail > command, using code similar to: > $mailbody = $mailbody . '\n' . > $HTTP_POST_VARS["somefield"]; > > when I sent the