[PHP] Re: Newbie Question about Conditionals

2010-03-31 Thread Shawn McKenzie
Matty Sarro wrote: > Hey all! > This is probably my second post on the list, so please be gentle. Right now > I am running through the "Heads First PHP and MySQL" book from O'Reilly. > It's been quite enjoyable so far, but I have some questions about some of > the code they're using in one of the c

Re: [PHP] Re: newbie question - php parsing

2009-07-23 Thread Sebastiano Pomata
Thanks, it's now much more clear. I thought that html parts outside php tags were just dumped to output, no matter of if-else statements and other conditions. I was *definitely* wrong 2009/7/23 Peter Ford : > In response to Sebastiano: > > There would be not much point in using something like PHP

[PHP] Re: newbie question - php parsing

2009-07-23 Thread Peter Ford
João Cândido de Souza Neto wrote: > You made a mistake in your code: > > > > must be: > > > Not necessarily: what if you have function the_title() { echo "Title"; } for example... In response to Sebastiano: There would be not much point in using something like PHP if it ignore

[PHP] Re: newbie question - php parsing

2009-07-22 Thread Shawn McKenzie
João Cândido de Souza Neto wrote: > You made a mistake in your code: > > > > must be: > > > I haven't used worpress in a long time, but the the_title() function might echo the title unless you pass the FALSE parameter, in which case it just returns it. -- Thanks! -Shawn http://www.spidea

Re: [PHP] Re: newbie question - php parsing

2009-07-22 Thread Martin Scotta
This is how I'd write this snippet ', $title, ''; } ?> On Wed, Jul 22, 2009 at 6:31 PM, Lenin wrote: > Ted Turner > - > "Sports is like a war without the killing." > > 2009/7/23 Shane Hill > > > 2009/7/22 João Cândido

Re: [PHP] Re: newbie question - php parsing

2009-07-22 Thread Lenin
Ted Turner - "Sports is like a war without the killing." 2009/7/23 Shane Hill > 2009/7/22 João Cândido de Souza Neto > > > You made a mistake in your code: > > > > > > > > must be: > > > > > > > Short tag and not recommended

Re: [PHP] Re: newbie question - php parsing

2009-07-22 Thread Shane Hill
2009/7/22 João Cândido de Souza Neto > You made a mistake in your code: > > > > must be: > > also works. -Shane > > > -- > João Cândido de Souza Neto > SIENS SOLUÇÕES EM GESTÃO DE NEGÓCIOS > Fone: (0XX41) 3033-3636 - JS > www.siens.com.br > > "Sebastiano Pomata" escreveu na men

[PHP] Re: newbie question - php parsing

2009-07-22 Thread Jo�o C�ndido de Souza Neto
You made a mistake in your code: must be: -- João Cândido de Souza Neto SIENS SOLUÇÕES EM GESTÃO DE NEGÓCIOS Fone: (0XX41) 3033-3636 - JS www.siens.com.br "Sebastiano Pomata" escreveu na mensagem news:70fe20d60907221355m3fa49a75ua053d2f1b9aca...@mail.gmail.com... > Hi all, > > A lit

[PHP] Re: Newbie Question - Form To Email Needed

2007-05-05 Thread itoctopus
1st page: 2nd page: $str_body = $_POST['thebody']; mail('[EMAIL PROTECTED]', 'This is the subject', $str_body); Of course you can have the email and the subject fields come also from the 1st page. Hope that helps! -- itoctopus - http://www.itoctopus.com "revDAVE" <[EMAIL PROTECTED]>

Re: [PHP] Re: newbie question about storing big5 codes into mysql-5.0.24a

2007-03-25 Thread Jochem Maas
Man-wai Chang wrote: >> queries in the command-line MySQL client. If it works there but not >> through mysqli_query() then you might have a case for asking here. > > For the 13081 chinese alphabets I tried, only 1 one failed, and it's > 0x9f54. mysqli_query() should have escaped the string for me.

[PHP] Re: newbie question about storing big5 codes into mysql-5.0.24a

2007-03-25 Thread Man-wai Chang
> queries in the command-line MySQL client. If it works there but not > through mysqli_query() then you might have a case for asking here. For the 13081 chinese alphabets I tried, only 1 one failed, and it's 0x9f54. mysqli_query() should have escaped the string for me. So ... I suppose most PHP p

Re: [PHP] Re: newbie question about storing big5 codes into mysql-5.0.24a

2007-03-25 Thread Stut
Man-wai Chang wrote: >>> create table temp ( big5 char(2) ) character set big5 collate big5_bin; >>> insert into temp ( big5 ) values ( 0x9f54 ); >>> insert into temp ( big5 ) values ( 0x9f53 ); >>> The 2nd query will report duplicated key. How should I fix the problem? >> What does this has to do

[PHP] Re: newbie question about storing big5 codes into mysql-5.0.24a

2007-03-24 Thread Man-wai Chang
>> create table temp ( big5 char(2) ) character set big5 collate big5_bin; >> insert into temp ( big5 ) values ( 0x9f54 ); >> insert into temp ( big5 ) values ( 0x9f53 ); >> The 2nd query will report duplicated key. How should I fix the problem? > What does this has to do with PHP? > First of all I

[PHP] Re: newbie question

2007-03-21 Thread itoctopus
Means you're passing the variable as reference. This means that any change in the variable inside your function will affect the variable outside your function, in other terms: if you have function myfunc(&$var){ $var = 5; } $a = 6; myfunc($a); will result in having $a=5 after the function a

Re: [PHP] Re: Newbie question about

2006-09-11 Thread tedd
At 5:36 PM +0100 9/11/06, Stut wrote: tedd wrote: Opinions? I would have to agree. Having watched the server CPU load while playing with this test script it would appear that the performance can be skewed a lot more by that than by the method you use for squidging out the output. As a cu

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Satyam
- Original Message - From: "Stut" <[EMAIL PROTECTED]> To: "Satyam" <[EMAIL PROTECTED]> Cc: Sent: Monday, September 11, 2006 6:32 PM Subject: Re: [PHP] Re: Newbie question about Satyam wrote: I admit I'm totally surprised about the buffered res

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Stut
Jon Anderson wrote: Stut wrote: How bored am I? This bored: http://dev.stut.net/phpspeed/ Server is running PHP 5.1.2 (really should upgrade that) with no caches of any sort. Just looking through the source, could you try changing the first example to put the output all on one line? It's th

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Stut
tedd wrote: At 4:56 PM +0100 9/11/06, Stut wrote: How bored am I? This bored: http://dev.stut.net/phpspeed/ Server is running PHP 5.1.2 (really should upgrade that) with no caches of any sort. -Stut Which begs the question, does it make much of a difference? (not you being bored, but the

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Stut
Satyam wrote: I admit I'm totally surprised about the buffered results. Nevertheless, may I sugest you add the following to the series of tests?: Using line-by-line single-quoted echowith comma separated arguments There seems to be one thing rarely anybody remembers, echo admits mu

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Satyam
are the second best option. Satyam - Original Message - From: "Stut" <[EMAIL PROTECTED]> To: "Jon Anderson" <[EMAIL PROTECTED]> Cc: "Satyam" <[EMAIL PROTECTED]>; Sent: Monday, September 11, 2006 5:56 PM Subject: Re: [PHP] Re: Newbie que

Re: [PHP] Re: Newbie question about

2006-09-11 Thread tedd
At 4:56 PM +0100 9/11/06, Stut wrote: How bored am I? This bored: http://dev.stut.net/phpspeed/ Server is running PHP 5.1.2 (really should upgrade that) with no caches of any sort. -Stut Which begs the question, does it make much of a difference? (not you being bored, but the rather speed

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Stut
How bored am I? This bored: http://dev.stut.net/phpspeed/ Server is running PHP 5.1.2 (really should upgrade that) with no caches of any sort. -Stut -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Newbie question about

2006-09-11 Thread Jon Anderson
Satyam wrote: for ($x=0;$x<1000;$x++) { echo ' X is ' , $x , ''; } This seems to be a hair faster. I extended the test to 1 requests (still concurrency 10) to make the test a little more reproducible: echo str,var,str did 604.65 requests a second where ?> did 599.63 requests a second. I

Re: [PHP] Re: Newbie question about

2006-09-10 Thread Satyam
- Original Message - From: "Jon Anderson" <[EMAIL PROTECTED]> To: Cc: "Al" <[EMAIL PROTECTED]> Sent: Sunday, September 10, 2006 9:16 PM Subject: Re: [PHP] Re: Newbie question about Al wrote: Structurally, there is a far better way to compile you

Re: [PHP] Re: Newbie question about

2006-09-10 Thread Jon Anderson
Al wrote: Structurally, there is a far better way to compile your html pages. This approach is easier to design and debug and it is faster since it sends one complete packet instead of one for every short tag. And, it saves using ob_start() and ob_flush(). Consider: $report= ''; $report .=

Re: [PHP] Re: Newbie question about

2006-09-10 Thread Satyam
- Original Message - From: "Al" <[EMAIL PROTECTED]> To: Sent: Sunday, September 10, 2006 5:52 PM Subject: [PHP] Re: Newbie question about Mike Borrelli wrote: Good day, While I've been using php for more than a little while now, I've never understood w

[PHP] Re: Newbie question about

2006-09-10 Thread Al
Mike Borrelli wrote: Good day, While I've been using php for more than a little while now, I've never understood why the use of the "" short tag is noted "to be avoided". Or rather, I understand that there's an option to disable it, and that's why it's noted in this way, but I don't understand

[PHP] Re: Newbie question

2004-11-28 Thread Brad Ciszewski
try, www.BradTechnologies.com 99.9% Uptime 24/7 FREE Support Plans starting at $3.50 per month www.BradTechnologies.com "Pascal Platteeuw" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello everyone, > > Here is a newbie question for you guys who are much more advanced than me

[PHP] Re: Newbie question about operators

2004-04-08 Thread Gabe
Thanks Ligaya "Ligaya Turmelle" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > it is refering to the associative array, specifically the $key => $value . > Note here (http://www.php.net/manual/en/language.types.array.php). > > Respectfully, > Ligaya Turmelle > > "Gabe" <[EMAIL PROT

[PHP] Re: Newbie question about operators

2004-04-07 Thread Ligaya Turmelle
it is refering to the associative array, specifically the $key => $value . Note here (http://www.php.net/manual/en/language.types.array.php). Respectfully, Ligaya Turmelle "Gabe" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Looking at the code below, what exactly is happening wit

[PHP] Re: Newbie question on Array

2004-03-28 Thread DvDmanDT
You can't do it that way.. You'll probably get parse error.. -- // DvDmanDT MSN: dvdmandt¤hotmail.com Mail: dvdmandt¤telia.com <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > > Sorry, I am new and could not supply the correct search strings on search > sites to answer by question.

[PHP] Re: Newbie question on arrays

2004-03-28 Thread ma.siebeneicher
you need to declare your $monthname var as global, now you can use it! function show_lang_date($timestamp, $country) { GLOBAL $monthname; $date = getdate($timestamp); echo "mday = ". $date['mday'] . " "; echo "country = $country "; $mon = $date["mon"]; echo "mon = ". $mon . " "; ech

[PHP] Re: Newbie question

2004-01-13 Thread Luke
it sounds like maybe you dont have the mysql php extension turned on in the php ini file, or your php doesnt have mysql support? Luke "James Marcinek" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello Everyone, > > I'm new to this so forgive my ignorance. I'm trying to use php w

[PHP] Re: newbie question about scope

2003-11-12 Thread pete M
things to check.. check the register_globals flag in php.ini - you can also set this using ini_set() Check the short_open_tags are either on/off - again this chan be changes in ini_set() pete News.Comcast.Giganews.Com wrote: I am an experienced web developer who is just getting into php. I h

[PHP] Re: newbie question

2002-09-03 Thread Richard Lynch
>How do I get PHP to automatically open another PHP page in a browser if a >condition is met? > > I have a pull down HTML table that submits a form to a PHP script. That >script then uses a little logic to figure out which web page to go to. I >have 5 different pages, and each has different cont

[PHP] Re: Newbie question about SQL result formatting

2002-08-09 Thread Kristoffer Strom
There we go :) If there's any consolation, you just helped NataliePortman.com become a better website :) Thx /Kris "Philip Hallstrom" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > see nl2br(). You might also want to convert spaces to  's > > On Fri, 9 Aug

[PHP] Re: Newbie question about SQL result formatting

2002-08-09 Thread Philip Hallstrom
see nl2br(). You might also want to convert spaces to  's On Fri, 9 Aug 2002, Kristoffer Strom wrote: > Ok, this is totally newbie but I just started messing around with PHP after > programming IBM's NetData for a while. > > My first big problem I haven't been able to solve myself is how to for

Re: [PHP] Re: Newbie question : PHP variables are not posted by this

2002-05-31 Thread Stuart Dallas
On Friday, May 31, 2002, 5:17:49 PM, you wrote: > Can you send the code that is failing to the list - it will help in working > out the problem... And include your platform details (OS, PHP version, etc). -- Stuart -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP] Re: Newbie question : PHP variables are not posted by this

2002-05-31 Thread Michael Davey
Can you send the code that is failing to the list - it will help in working out the problem... Mikey "FréDéRick St-Hilaire" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > It a BASIC question, > > With the following: > > ENCTYPE="multipart/form-data"> >

[PHP] Re: Newbie question about PHP and Oracle

2002-05-28 Thread Markus Mirsberger
Hi, I think you mean hwo u can get the data into an array well here is an example : $query = "select ..."; $stmt = ociparse( $connectionhandle, $query ); if( ociexecute( $stmt, OCI_DEFAULT ) ){ ocifetchinto( $stmt, $row, OCI_ASSOC+OCI_RETURN_NULLS ); } and now you got 1 resultset in an

[PHP] Re: Newbie question to everybody....PHP

2002-05-11 Thread Austin Marshall
R wrote: > Greetings people, > Special greetings to all of you who have helped me in the past. > > As most of you know i am a newbie, I learned a bit of PHP via webmonkey and > a few other places, seeing the power of PHP i decided to convert from Java > servlets and JSP (JSP coz its expensive to

[PHP] Re: Newbie Question

2002-04-08 Thread Michael Virnstein
try this: Solid "); print("".$data[0].""); print(""); print("."$data[2].""); print("".$data[3].""); print("".$data[4].""); print("".$data[5].""); print(""); } } ?> "Hubert Daul" <[EMAIL PROTECTED]> schrieb im Newsbeitra

[PHP] Re: newbie question: how to recompile PHP?

2002-04-03 Thread Craig Donnelly
Strange..U sure you got the Win32 version?? Heres a mirror where u can get the installer: http://www.evilwalrus.com/downloads/php/4.1.2/php-4.1.2-installer.exe All the best, Craig "Bogdan Popescu" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hello all, >

Re: [PHP] Re: Newbie question...

2002-02-22 Thread Thalis A. Kalfigopoulos
On Fri, 22 Feb 2002, J Smith wrote: > > Try wget if it's installed. If not, lynx, a shell-based web browser, is > installed on quite a few machines. > > J > > > > > Ben Turner wrote: > > > This may be a bit off topic but I am trying to install the pdflib package > > for Linux so I can ma

[PHP] Re: Newbie question...

2002-02-22 Thread J Smith
Try wget if it's installed. If not, lynx, a shell-based web browser, is installed on quite a few machines. J Ben Turner wrote: > This may be a bit off topic but I am trying to install the pdflib package > for Linux so I can make pdfs through php and I was wondering if anyone > might know

Re: [PHP] Re: Newbie: Question about filesize()

2002-02-06 Thread Lars Torben Wilson
On Wed, 2002-02-06 at 15:33, Jeff Sheltren wrote: > At 10:27 AM 2/6/2002 -0500, Ben Crawford wrote: > >You also seem to have an extra equals. Your loop should read: > > > >while (false != ($file=readdir($handle))){ > > I think you could eliminate the "false !=" in the while condition... > > It s

Re: [PHP] Re: Newbie: Question about filesize()

2002-02-06 Thread Lars Torben Wilson
On Wed, 2002-02-06 at 07:27, Ben Crawford wrote: > You also seem to have an extra equals. Your loop should read: > > while (false != ($file=readdir($handle))){ > > It should come up as an error, but I'm not sure. > > Ben No, that's the 'identical' operator, which returns true when its operands

Re: [PHP] Re: Newbie: Question about filesize()

2002-02-06 Thread Jeff Sheltren
At 10:27 AM 2/6/2002 -0500, Ben Crawford wrote: >You also seem to have an extra equals. Your loop should read: > >while (false != ($file=readdir($handle))){ I think you could eliminate the "false !=" in the while condition... It should be just the same if you write while (($file = readdir($handl

RE: [PHP] Re: Newbie: Question about filesize()

2002-02-06 Thread Martin Towell
L PROTECTED] Subject: [PHP] Re: Newbie: Question about filesize() You also seem to have an extra equals. Your loop should read: while (false != ($file=readdir($handle))){ It should come up as an error, but I'm not sure. Ben Manuel Ritsch wrote: > Hello There > > I'm n

[PHP] Re: Newbie: Question about filesize()

2002-02-06 Thread Ben Crawford
You also seem to have an extra equals. Your loop should read: while (false != ($file=readdir($handle))){ It should come up as an error, but I'm not sure. Ben Manuel Ritsch wrote: > Hello There > > I'm new to PHP and trying to code a function that reads all teh files out of > a directory and p

[PHP] Re: Newbie: Question about filesize()

2002-01-31 Thread Jim Winstead
Manuel Ritsch <[EMAIL PROTECTED]> wrote: > $file_s = filesize($file); you want $file_s = filesize("images/$file"). jim -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To c

[PHP] Re: Newbie question on Tutorials?

2001-12-06 Thread The Big Roach
Bunch of them! Check php.net's links and sift through those. Web Monkey has a good primer on PHP & MySQL. "Geoff E" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Okay, probably been asked zillions of times already, but I couldn't find > reference to it in the

[PHP] Re: Newbie Question

2001-11-21 Thread Lee Willmann
Ok, I think I have the solution to your problem. Try using nl2br() on the data in that field.. Example: I have a message table that allows one user to send an instant message to another user on my site. There are several fields, one of which being a TEXT column (MySQL db). I use a simple textare

[PHP] Re: Newbie question pleeze help

2001-11-15 Thread Richard Lynch
Rvb Pixels wrote: > Hi, > > I'm new to the list and I have a problem with PHPNUKE 5.2 and W98. > > After installing some categories and links in the Web Links section, and > then clicking on one of the links created I keep getting the following > message error in W98SE. > > "PHP caused an inva

[PHP] Re: Newbie Question re: Select boxes

2001-08-23 Thread jimw
Lb <[EMAIL PROTECTED]> wrote: > 1) I thought that PHP automatically created variables for all form elements > on a page. When I run this, the dropdown box contains the first item, but > $Report evaluates as null. I am unclear why. > > > 1 Test Report A > 2 Test Report B > 3 Test Repo

[PHP] Re: Newbie question: Page Counter

2001-04-19 Thread yanto
this counter'll increment the counter, no matter where are you go the page from. If you only want that the counter increment for the first time visitor visit the website, put the code at mainpage file, and check also the page referrer weather it's a local url or not. -toto- Adam writes: > mak