Re: [PHP] Re: echo?

2011-03-24 Thread Tamara Temple
On Mar 22, 2011, at 9:50 PM, Jim Giner wrote: Yes - it is J and I. I tried using $i+1 in the echo originally but it wouldn't run. That's why I created $j. Interesting it wouldn't run.. perhaps that's a place to investigate? And just what is wrong with the old cr/lf sequence? How would

Re: [PHP] Re: echo?

2011-03-24 Thread Hans Åhlin
2011/3/23 Jim Giner jim.gi...@albanyhandball.com: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++)    {    $j = $i+1;    $row = mysql_fetch_array($qrslt);    echo

[PHP] Re: echo?

2011-03-23 Thread Geoff Lane
Hi Jim, On Wednesday, March 23, 2011, 1:42:18 AM, you wrote: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++) { $j = $i+1; $row = mysql_fetch_array($qrslt); echo

Re: [PHP] Re: echo?

2011-03-23 Thread Frank Arensmeier
23 mar 2011 kl. 02.42 skrev Jim Giner: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++) { $j = $i+1; $row = mysql_fetch_array($qrslt); echo $j.'-'.$row['userid'];

Re: [PHP] Re: echo?

2011-03-23 Thread Ricardo Martinez
Hi after of the for, u can use it shoulds back the class of variable, by example its is string its is int etc for ($i=0;$i$rows;$i++) echo $i.' '.$row['itemname']; echo gettype($i); Can be that you must define before the class of this variable, because, the system is thinking this is a

Re: [PHP] Re: echo?

2011-03-23 Thread Richard Quadling
On 23 March 2011 07:46, Geoff Lane ge...@gjctech.co.uk wrote: Hi Jim, On Wednesday, March 23, 2011, 1:42:18 AM, you wrote: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++)     {  

Re: [PHP] Re: echo?

2011-03-23 Thread Jim Giner
I am outputting to a textarea on an html page. A br doesn't work, nor does \n, hence the #13#10. Of course, if I don't need the then I've just saved two keystrokes. :) Also - I do believe I tried ($i+1) and that didn't work either. Paul M Foster pa...@quillandmouse.com wrote in message

[PHP] Re: echo?

2011-03-23 Thread Jim Giner
By george - I think you've solved it! As for my coding choice - that's the beauty of programming - everybody has a way of solving a problem/creating a solution. Unless you are concerned with performance(which in this particular case is not a concern), there is no 'wrong way'. Geoff Lane

Re: [PHP] Re: echo?

2011-03-23 Thread Steve Staples
On Wed, 2011-03-23 at 08:28 -0400, Jim Giner wrote: I am outputting to a textarea on an html page. A br doesn't work, nor does \n, hence the #13#10. Of course, if I don't need the then I've just saved two keystrokes. :) Also - I do believe I tried ($i+1) and that didn't work either.

Re: [PHP] Re: echo?

2011-03-23 Thread Jim Giner
not the concern in this posting Richard Quadling rquadl...@gmail.com wrote in message news:aanlktindqu7bzeamtcwh6y9f3m9yjxqpt-ime9ysh...@mail.gmail.com... On 23 March 2011 07:46, Geoff Lane ge...@gjctech.co.uk wrote: Hi Jim, On Wednesday, March 23, 2011, 1:42:18 AM, you wrote: ok - here's

Re: [PHP] Re: echo?

2011-03-23 Thread Jim Giner
it was as complete as need be to demonstrate my dilemma, as Richard has discovered above Frank Arensmeier farensme...@gmail.com wrote in message news:7cfb015a-c530-4712-9ebc-fbdf5b0ed...@gmail.com... 23 mar 2011 kl. 02.42 skrev Jim Giner: ok - here's the code in question. $q = 'select * from

Re: [PHP] Re: echo?

2011-03-23 Thread Jim Giner
Very Interesting - '\n' doesn't work, but \n does work. Steve Staples sstap...@mnsi.net wrote in message news:1300883645.5100.973.camel@webdev01... On Wed, 2011-03-23 at 08:28 -0400, Jim Giner wrote: I am outputting to a textarea on an html page. A br doesn't work, nor does \n, hence the

Re: [PHP] Re: echo?

2011-03-23 Thread Stuart Dallas
http://php.net/manual/en/language.types.string.php -Stuart -- Stuart Dallas 3ft9 Ltd http://3ft9.com/ On Wednesday, 23 March 2011 at 12:39, Jim Giner wrote: Very Interesting - '\n' doesn't work, but \n does work. Steve Staples sstap...@mnsi.net wrote in message

[PHP] Re: echo?

2011-03-23 Thread Jim Giner
As Richard proved my problem was caused by my use of the archaic cr/lf character pair. Once I found the correct syntax for using \n my output of the loop counter worked. thanks for all the suggestions. My first experience on a PHP newsgroup and it was a postiive one. I've spent the last 12+

Re: [PHP] Re: echo?

2011-03-23 Thread Jim Giner
Thanks for the pointer. Had not run across that tidbit before. Stuart Dallas stu...@3ft9.com wrote in message news:b43dfd4fa2ac4489aaf538d1bf7a8...@3ft9.com... http://php.net/manual/en/language.types.string.php -Stuart -- Stuart Dallas 3ft9 Ltd http://3ft9.com/ On Wednesday, 23 March

Re: [PHP] Re: echo?

2011-03-23 Thread Paul M Foster
On Wed, Mar 23, 2011 at 07:46:03AM +, Geoff Lane wrote: Hi Jim, On Wednesday, March 23, 2011, 1:42:18 AM, you wrote: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++)

Re: [PHP] Re: echo?

2011-03-23 Thread David Robley
Jim Giner wrote: I am outputting to a textarea on an html page. A br doesn't work, nor does \n, hence the #13#10. Of course, if I don't need the then I've just saved two keystrokes. :) Also - I do believe I tried ($i+1) and that didn't work either. Paul M Foster

[PHP] Re: echo?

2011-03-22 Thread Al
On 3/22/2011 6:22 PM, Jim Giner wrote: Kinda new to this, but I've been puttering/writing for about 3 weeks now and have some good working screens up. Ran into something new while I was debuggina script today. Tried to echo the $i value within a for loop as part of the list of items I was

[PHP] Re: echo?

2011-03-22 Thread Jim Giner
ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++) { $j = $i+1; $row = mysql_fetch_array($qrslt); echo $j.'-'.$row['userid']; if ($row['user_priv'] ) echo '

Re: [PHP] Re: echo?

2011-03-22 Thread Tamara Temple
On Mar 22, 2011, at 8:42 PM, Jim Giner wrote: ok - here's the code in question. $q = 'select * from director_records '; $qrslt = mysql_query($q); $rows = mysql_num_rows($qrslt); for ($i=0; $i$rows; $i++) { $j = $i+1; Am i reading this correctly: the first variable is j (jay) the second

Re: [PHP] Re: echo?

2011-03-22 Thread Jim Giner
Yes - it is J and I. I tried using $i+1 in the echo originally but it wouldn't run. That's why I created $j. And just what is wrong with the old cr/lf sequence? How would you have done it? What do you mean 'this alone .'? Tamara Temple tamouse.li...@gmail.com wrote in message

Re: [PHP] Re: echo?

2011-03-22 Thread Paul M Foster
On Tue, Mar 22, 2011 at 10:50:54PM -0400, Jim Giner wrote: Yes - it is J and I. I tried using $i+1 in the echo originally but it wouldn't run. That's why I created $j. Yes, the substitution creates a syntax error unless surrounded by parentheses or the like. And just what is wrong with

[PHP] Re: Echo result in a loop on each instance

2009-06-23 Thread Peter Ford
Anton Heuschen wrote: I have a question regarding echo of a var/string in a loop on each instance A shortened example: Lets say I have an array of values (rather big), and then I loop through this array: for or foreach : { $value = $arrValAll[$i]; echo test.$i.-- .$value; }

Re: [PHP] Re: ECHO

2006-12-19 Thread Satyam
Sent: Tuesday, December 19, 2006 6:46 AM Subject: [PHP] Re: ECHO I have written a framework for internationalization. Now i have incoorperate it into and existing system that is huge and it will take alot of time to change ECHO to a function call, so i want to override its implementation so

[PHP] Re: ECHO

2006-12-19 Thread Fahad Pervaiz
Satyam - Original Message - From: Fahad Pervaiz [EMAIL PROTECTED] To: php-general@lists.php.net Sent: Tuesday, December 19, 2006 6:46 AM Subject: [PHP] Re: ECHO I have written a framework for internationalization. Now i have incoorperate it into and existing system that is huge

[PHP] Re: ECHO

2006-12-18 Thread Fahad Pervaiz
I have written a framework for internationalization. Now i have incoorperate it into and existing system that is huge and it will take alot of time to change ECHO to a function call, so i want to override its implementation so that i can use it for my own purposes with having to change all the

Re: [PHP] Re: ECHO

2006-12-18 Thread Casey Chu
You could try to manipulate what the echo's output by ob_start(), etc. Or maybe you could change the standard output? On 12/18/06, Fahad Pervaiz [EMAIL PROTECTED] wrote: I have written a framework for internationalization. Now i have incoorperate it into and existing system that is huge and it

[PHP] Re: ECHO

2006-12-18 Thread Fahad Pervaiz
Manipulating out with Output Control Functions sounds a good idea but it can become cumbersome. Do you know any good methods to control standard output?? On 12/19/06, Casey Chu [EMAIL PROTECTED] wrote: You could try to manipulate what the echo's output by ob_start(), etc. Or maybe you could

Re: [PHP] Re: ECHO

2006-12-18 Thread Paul Novitski
On 12/18/06, Fahad Pervaiz [EMAIL PROTECTED] wrote: I have written a framework for internationalization. Now i have incoorperate it into and existing system that is huge and it will take alot of time to change ECHO to a function call, so i want to override its implementation so that i can use

[PHP] Re: echo

2005-11-19 Thread Oliver Grätz
Alex Alfonso schrieb: echo I need a space here; echo space; *g* -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Echo array string index?

2005-07-14 Thread Joe Harman
Hey Matt, you can print out the contents of your array by using print_r($arr) but more useful is using this foreach ($arr as $key = $value) { echo Key : .$key. Value : .$value; } Adios Joe On 7/13/05, Adam Hubscher [EMAIL PROTECTED] wrote: Matt Darby wrote: I have an array setup as

RE: [PHP] Re: Echo array string index?

2005-07-14 Thread yanghshiqi
Yeah, you can use foreach. But *may be* you just find sth called array_keys(). Best regards, Shiqi Yang -Original Message- From: Joe Harman [mailto:[EMAIL PROTECTED] Sent: Thursday, July 14, 2005 4:45 PM To: php-general@lists.php.net Subject: Re: [PHP] Re: Echo array string index

[PHP] Re: Echo array string index?

2005-07-13 Thread Adam Hubscher
Matt Darby wrote: I have an array setup as such: *$arr['generated text']='generated number';* What would be the best way to echo the key in a loop? Seems pretty easy but I've never attempted... Thanks all! Matt Darby I'm not sure I understand the question. You could do foreach($arr as $key

[PHP] Re: echo

2004-11-30 Thread Christopher Weaver
OK, I get it now. I had forgotten that PHP output is text, as opposed to the result produced by HTML. When the documentation states that the newlines will be output as well it means that literally -- not that the browser will output the newlines. Thanks for jumping onto this. Chris. --

[PHP] Re: echo to rtf format

2004-09-24 Thread Manuel Lemos
Hello, On 09/24/2004 11:16 PM, John Taylor-Johnston wrote: I know there is a way to print to pdf. Wh«t about rtf? I'm getting real tired of doing it myself. Must be an easier answer? You may want to try this RTF generator class: http://www.phpclasses.org/rtfgenerator -- Regards, Manuel Lemos PHP

Re: [PHP] Re: Echo HTML code Verses breaking out of ?php ?

2003-11-25 Thread Curt Zirzow
* Thus wrote tkwright ([EMAIL PROTECTED]): Just warming the timer This Is HTML ### # Total Time: 0.000114 seconds # # Start Time: 1069732578.575586 seconds # # Ending Time: 1069732578.575700 seconds #

[PHP] Re: Echo HTML code Verses breaking out of ?php ?

2003-11-24 Thread tkwright
I dont think you are going to belive this, but here are the results from a php-class I made(for code see bottom of message): Just warming the timer This Is HTML ### # Total

[PHP] Re: Echo HTML code Verses breaking out of ?php ?

2003-11-21 Thread DvDmanDT
?HTML? is almost double as fast according to some stats I saw a while ago (at phpbeginner.com).. But that's compared to HTML, using singlequotes is faster ('HTML')... But I haven't confirmed those stats... -- // DvDmanDT MSN: dvdmandt¤hotmail.com Mail: dvdmandt¤telia.com

Re: [PHP] Re: Echo $PHP_SELF not working

2003-10-11 Thread Justin French
Actually, that should make no difference... you don't need a ; if it's the last instruction before the close of PHP. Try ?php echo $_SEVER['PHP_SELF']? or ?=$_SEVER['PHP_SELF']? Justin On Saturday, October 11, 2003, at 09:29 AM, Al wrote: Put a ; [no quotes] after such as: echo $PHP_SELF;

[PHP] Re: Echo $PHP_SELF not working

2003-10-10 Thread Paul van Schayck
Hello, Here we go again ;) [EMAIL PROTECTED] (Jeff McKeon) wrote I've just published a new website and something is wrong. I suspect the PHP.ini on the server but I can't seem to find anything. register_globals is on off. Which is a good idea, keep it there! On the dev server ECHO

RE: [PHP] Re: Echo $PHP_SELF not working

2003-10-10 Thread Jeff McKeon
']'?? Jeff -Original Message- From: Paul van Schayck [mailto:[EMAIL PROTECTED] Sent: Friday, October 10, 2003 8:24 AM To: [EMAIL PROTECTED] Subject: [PHP] Re: Echo $PHP_SELF not working Hello, Here we go again ;) [EMAIL PROTECTED] (Jeff McKeon) wrote I've just published a new

Re: [PHP] Re: Echo $PHP_SELF not working

2003-10-10 Thread Shawn McKenzie
Message- From: Paul van Schayck [mailto:[EMAIL PROTECTED] Sent: Friday, October 10, 2003 8:24 AM To: [EMAIL PROTECTED] Subject: [PHP] Re: Echo $PHP_SELF not working Hello, Here we go again ;) [EMAIL PROTECTED] (Jeff McKeon) wrote I've just published a new website and something is wrong

[PHP] Re: Echo $PHP_SELF not working

2003-10-10 Thread Al
Put a ; [no quotes] after such as: echo $PHP_SELF; Jeff McKeon wrote: I've just published a new website and something is wrong. I suspect the PHP.ini on the server but I can't seem to find anything. The line: form method='post' action='?PHP ECHO $PHP_SELF ?' Doesn't seem to work. If I

[PHP] Re: echo statements

2003-07-18 Thread Kevin Stone
Jay Fitzgerald [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] When echoing html code that will include variables from a while or if loop, which method is best? Method 1: echo td align=\left\ VALIGN=\top\font class=\dbtables\$employer/font/td; OR Method 2: td align=left

[PHP] re: echo w/ here document

2002-11-12 Thread Craig Buxton
I'm still having a problem with including a here document. Trying this code: ?php echo ENDOFECHO HTML BODY hello... hello... hello... hello... /BODY /HTML ENDOFECHO; ? I get a parse error on line 7. Please help. I have a major project that has ground to a halt. Craig Buxton Gravity Pilot

Re: [PHP] re: echo w/ here document

2002-11-12 Thread Aaron Gould
Buxton [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 5:32 AM Subject: [PHP] re: echo w/ here document I'm still having a problem with including a here document. Trying this code: ?php echo ENDOFECHO HTML BODY hello... hello... hello... hello... /BODY /HTML

Re: [PHP] re: echo w/ here document

2002-11-12 Thread Marco Tabini
- Original Message - From: Craig Buxton [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 5:32 AM Subject: [PHP] re: echo w/ here document I'm still having a problem with including a here document. Trying this code: ?php echo ENDOFECHO HTML BODY

RE: [PHP] re: echo w/ here document

2002-11-12 Thread Troy May
Newbie here. Works fine for me too. -Original Message- From: Marco Tabini [mailto:marcot;tabini.ca] Sent: Tuesday, November 12, 2002 5:31 AM To: Aaron Gould Cc: Craig Buxton; Subject: Re: [PHP] re: echo w/ here document Works fine on my system. As Aaron said, make sure

[PHP] Re: Echo Regular Expression Pattern

2002-10-10 Thread Mike Smith
Nevermind. This works: ereg(Q+[0-9]{6},$Data[$n],$qarticle); $GetLine = explode(\r, ereg_replace(Q+[0-9]{6},a href=\http://support.microsoft.com/default.aspx?scid=kb;[LN];$qarticle[0]\; target=\blank\$qarticle[0]/a,$Data[$n])); Mike Smith [EMAIL PROTECTED] wrote in message [EMAIL

[PHP] Re: echo HTML code ;

2002-01-31 Thread Daniel Grace
André wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I have a PHP file that I show values of variables in several parts, and for that I put in almost the whole page echo... HTML code + PHP codes (variables, functions, etc.) + HTML code... ; I don't know nor why I put, I

[PHP] Re: echo/printing html within a function - best method

2001-09-16 Thread speedboy
How do you echo your html, do you put the html in your functions and escape the double quotes? There is some extra load there echoing all the html? echo HTML? I do this: ? php stuff..? HTML stuff ? more php stuff ? I drop out of PHP mode to display raw HTML. If I have a

Re: [PHP] Re: echo/printing html within a function - best method

2001-09-16 Thread Rasmus Lerdorf
How do you echo your html, do you put the html in your functions and escape the double quotes? There is some extra load there echoing all the html? echo HTML? I do this: ? php stuff..? HTML stuff ? more php stuff ? I drop out of PHP mode to display raw HTML. If I

Re: [PHP] Re: echo/printing html within a function - best method

2001-09-16 Thread Jason Bell
, September 16, 2001 9:32 PM Subject: Re: [PHP] Re: echo/printing html within a function - best method I try to avoid having my functions generate HTML. But yes, when they do I use the same approach. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED

Re: [PHP] Re: echo vs printf

2001-07-17 Thread brother
Steve Brett wrote: don't echo and printf do different jobs ? as i understand it echo will dump anything to screen, fprint will accept formatted text args like you owe me %d dollars,$owed_amount) or something like that. i kind of use print by itself (harking back to the old days of

[PHP] Re: echo vs printf

2001-07-16 Thread Steve Brett
don't echo and printf do different jobs ? as i understand it echo will dump anything to screen, fprint will accept formatted text args like you owe me %d dollars,$owed_amount) or something like that. i kind of use print by itself (harking back to the old days of basic etc) but use echo quite a

RE: [PHP] Re: echo vs printf

2001-07-16 Thread Gonyou, Austin
. -- Austin Gonyou Systems Architect, CCNA Coremetrics, Inc. Phone: 512-796-9023 email: [EMAIL PROTECTED] -Original Message- From: Steve Brett [mailto:[EMAIL PROTECTED]] Sent: Monday, July 16, 2001 10:38 AM To: [EMAIL PROTECTED] Subject: [PHP] Re: echo vs printf don't echo