Re: [PHP] Parse errors

2012-03-19 Thread tamouse mailing lists
On Sun, Mar 18, 2012 at 2:18 PM, Tim Streater t...@clothears.org.uk wrote: On 18 Mar 2012 at 17:46, Simon J Welsh si...@welsh.co.nz wrote: This is expected. The error doesn't occur to the second file is included, so everything in the first included file is parsed and run before execution is

[PHP] Parse errors

2012-03-18 Thread Tim Streater
After recently omitting a semicolon from the end of a statement, and having the result be a JavaScript error in an odd place, I'm trying to pin down just what PHP does with such errors. I made a small test script to run at CLI, which does some echoes and then, after that, I miss out a

Re: [PHP] Parse errors

2012-03-18 Thread Simon J Welsh
On 19/03/2012, at 6:32 AM, Tim Streater wrote: After recently omitting a semicolon from the end of a statement, and having the result be a JavaScript error in an odd place, I'm trying to pin down just what PHP does with such errors. I made a small test script to run at CLI, which does some

Re: [PHP] Parse errors

2012-03-18 Thread Tim Streater
On 18 Mar 2012 at 17:46, Simon J Welsh si...@welsh.co.nz wrote: This is expected. The error doesn't occur to the second file is included, so everything in the first included file is parsed and run before execution is halted. Simon, Thanks for that. Looks like I should be able to catch most

Re: [PHP] Parse question

2011-01-21 Thread Joshua Kehn
On Jan 21, 2011, at 7:52 PM, Ron Piggott wrote: Would someone write me a syntax so all the web site addresses in $data turn into links $data = “Visit our web site http://www.site.com, http://www.secondsite.org and http://www.thirdsite.info.”; My desired results for what I am asking

Re: [PHP] Parse question

2011-01-21 Thread Nicholas Kell
On Jan 21, 2011, at 6:52 PM, Ron Piggott wrote: Would someone write me a syntax so all the web site addresses in $data turn into links $data = “Visit our web site http://www.site.com, http://www.secondsite.org and http://www.thirdsite.info.”; My desired results for what I am asking

Re: [PHP] Parse question

2011-01-21 Thread Ron Piggott
On Jan 21, 2011, at 6:52 PM, Ron Piggott wrote: Would someone write me a syntax so all the web site addresses in $data turn into links $data = “Visit our web site http://www.site.com, http://www.secondsite.org and http://www.thirdsite.info.”; My desired results for what I am asking

Re: [PHP] Parse info from 1,000 files to file

2010-06-04 Thread tedd
At 5:03 PM -0700 6/3/10, Jim Lucas wrote: Sam Smith wrote: Can someone briefly point me to the functions I'll need to parse some information from thousands of files in a single directory and then prepare the extracted info into a single file for SQL import? Like file() or readfile()

Re: [PHP] Parse info from 1,000 files to file

2010-06-03 Thread Jim Lucas
Sam Smith wrote: Can someone briefly point me to the functions I'll need to parse some information from thousands of files in a single directory and then prepare the extracted info into a single file for SQL import? Like file() or readfile() and some regex and writefile?? Thanks since

[PHP] Parse info from 1,000 files to file

2010-06-02 Thread Sam Smith
Can someone briefly point me to the functions I'll need to parse some information from thousands of files in a single directory and then prepare the extracted info into a single file for SQL import? Like file() or readfile() and some regex and writefile?? Thanks -- PHP General Mailing List

Re: [PHP] Parse info from 1,000 files to file

2010-06-02 Thread Andre Polykanine
- Original message - From: Sam Smith s...@ssmith.com To: php-general@lists.php.net php-general@lists.php.net Date: Wednesday, June 2, 2010, 9:24:20 PM Subject: [PHP] Parse info from 1,000 files to file Can someone briefly point me to the functions I'll need to parse some information from thousands

[PHP] Parse question

2010-05-13 Thread Ron Piggott
If $message_body contains: $message_body=You are subscribed using u...@domain. To update; How do I capture just the e-mail address? Ron

Re: [PHP] Parse question

2010-05-13 Thread Cemal Eker
Check this out. http://www.regular-expressions.info/email.html --- “Talk is cheap. Show me the code” - Linus Torvalds On Thu, May 13, 2010 at 7:34 AM, Ron Piggott ron.pigg...@actsministries.org wrote: If $message_body contains: $message_body=You are subscribed using u...@domain. To

RE: [PHP] Parse question

2010-05-13 Thread Lawrance Shepstone
-Original Message- From: Ron Piggott [mailto:ron.pigg...@actsministries.org] Sent: 13 May 2010 06:34 AM To: PHP General Subject: [PHP] Parse question If $message_body contains: $message_body=You are subscribed using u...@domain. To update; How do I capture just the e-mail address

[PHP] Parse a string containing name and email

2010-03-06 Thread Don
Hi, I am pulling email values out of a database and the format is as follows: John Smithjohn.sm...@somedomain.com I need to parse the string into two variables as such $name = John Smith $email = john.sm...@somedomain.com What would be the easiest way to do this? Thanks. -- PHP General

Re: [PHP] Parse a string containing name and email

2010-03-06 Thread Kevin Kinsey
Don wrote: Hi, I am pulling email values out of a database and the format is as follows: John Smithjohn.sm...@somedomain.com I need to parse the string into two variables as such $name = John Smith $email = john.sm...@somedomain.com What would be the easiest way to do this? Thanks. [36]

[PHP] parse date field

2010-01-14 Thread John Taylor-Johnston
How do I parse a date field from mysql? I was hoping this would work: $mydata-birthday = 2007-02-13; #What month is it? echo date(F, $mydata-birthday); #What year is it? echo date(Y, $mydata-birthday); What am I missing? All I get is December 1969. Hmmm? I am looking at the manual:

Re: [PHP] parse date field

2010-01-14 Thread vikash . iitb
Use strttotime() function. This will work as intended. $mydata-birthday = strtotime(2007-02-13); #What month is it? echo date(F, $mydata-birthday); #What year is it? echo date(Y, $mydata-birthday); - -- Vikash Kumar http://vika.sh On Thu, Jan 14, 2010 at 3:31 PM, John Taylor-Johnston

Re: [PHP] parse date field

2010-01-14 Thread Lester Caine
John Taylor-Johnston wrote: How do I parse a date field from mysql? I was hoping this would work: $mydata-birthday = 2007-02-13; This just stores a string to the variable $mydata-birthday - where did you define $mydata-birthday as a data object? $mydata-birthday = date(2007-02-13); #What

Re: [PHP] parse date field

2010-01-14 Thread John Taylor-Johnston
Super, thanks. 5:14 a.m. - My head is fogging :p vikash wrote: Use strttotime() function. This will work as intended. $mydata-birthday = strtotime(2007-02-13); #What month is it? echo date(F, $mydata-birthday); #What year is it? echo date(Y, $mydata-birthday); On Thu, Jan 14, 2010 at 3:31 PM,

Re: [PHP] parse date field

2010-01-14 Thread Michael Kjeldsen
On 01/14/2010 11:01 AM, John Taylor-Johnston wrote: How do I parse a date field from mysql? I was hoping this would work: $mydata-birthday = 2007-02-13; #What month is it? echo date(F, $mydata-birthday); #What year is it? echo date(Y, $mydata-birthday); What am I missing? All I get is

Re: [PHP] Parse Question Using list()

2009-10-02 Thread Gerardo Benitez
Use the tool that PHP provides for such problems. http://php.net/fgetcsv fgetcsv is very useful, here a example: ?php $row = 1; /* load file*/ $handle = fopen(log.csv, r); /* read line by line */ while (($data = fgetcsv($handle, 1000, ,)) !== FALSE) { $num = count($data); echo p

[PHP] Parse Question Using list()

2009-10-01 Thread c...@hosting4days.com
newbie import csv question file is like: stuff1,stuff2,stuff3 stuff1,stuff2,stuff3 stuff1,stuff2,stuff3 stuff1,stuff2,stuff3 etc. Problem: when I try to parse out the 3 fields and display them using list() it just gets just 1st char of each field ... Q: How do I get it to set $col1 - 2

Re: [PHP] Parse Question Using list()

2009-10-01 Thread Ben Dunlap
$line = fgets($handle); list($col1, $col2, $col3) = $line; [8] echo c1 is $col1 and c2 is $col2 and c3 is $col3.'br'; // this shows just 1st char of each field That's odd, I would have expected $col1, $col2, and $col3 to be NULL. That's what I get when I try to assign a string to list(). It

Re: [PHP] Parse Question Using list()

2009-10-01 Thread c...@hosting4days.com
On Oct 1, 2009, at 5:02 PM, Ben Dunlap wrote: You could tackle this in a couple of different ways. Either split your string into an array first: $line = fgets($handle); $columns = explode(,, trim($line)); Thanks Ben - the explode() command worked great! - Now a bit of another

Re: [PHP] Parse Question Using list()

2009-10-01 Thread Jim Lucas
c...@hosting4days.com wrote: On Oct 1, 2009, at 5:02 PM, Ben Dunlap wrote: You could tackle this in a couple of different ways. Either split your string into an array first: $line = fgets($handle); $columns = explode(,, trim($line)); Thanks Ben - the explode() command worked great! Use

[PHP] Parse error: syntax error, unexpected ''

2009-09-23 Thread Haig Davis
Good morning Everyone, I'm have trouble with a simple HTML Checkbox list. I keep getting *Parse error*: syntax error, unexpected ''. I'm sure I'm doing something really simple and basic wrong I just cannot seem to see what it is, any assistance is appreciated. Script: form method=post

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-20 Thread Stuart
2009/7/19 Paul M Foster pa...@quillandmouse.com: On Sun, Jul 19, 2009 at 07:18:34PM +0100, Stuart wrote: 2009/7/19 Paul M Foster pa...@quillandmouse.com: On Sun, Jul 19, 2009 at 09:30:33AM +0530, kranthi wrote: You do realize that PHP does not parse HTML files, right? The web server

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Stuart
2009/7/19 Jim Lucas li...@cmsws.com: Govinda wrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past..  but it is eluding me just now.. I can't figure out why files with the .html extension ARE being parsed by PHP when they are in the

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Ashley Sheridan
On Sat, 2009-07-18 at 23:09 -0600, Govinda wrote: i never used x-mapp-php5, but most of a forums say it is specific to 1and1 hosting service. php recommends application/x-httpd-php http://us2.php.net/manual/en/install.unix.apache2.php try adding AddType application/x-httpd-php .html in

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Eddie Drapkin
On Sun, Jul 19, 2009 at 2:53 AM, Ashley Sheridana...@ashleysheridan.co.uk wrote: On Sat, 2009-07-18 at 23:09 -0600, Govinda wrote: i never used x-mapp-php5, but most of a forums say it is specific to 1and1 hosting service. php recommends application/x-httpd-php

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Govinda
Generally, if a file has a .html extenstion, then it should really just contain html. .php extensions are meant for php code containing html. File extension has absolutely no bearing at all on the contents of the file. There's valid reasons to not expose what's what under the hood,

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Stuart
2009/7/19 Govinda govinda.webdnat...@gmail.com: Generally, if a file has a .html extenstion, then it should really just contain html. .php extensions are meant for php code containing html. File extension has absolutely no bearing at all on the contents of the file.  There's valid reasons to

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Govinda
Most security issues have nothing to do with the programming language and everything to do with the code. Just because facebook uses the .php extension certainly does not mean their code has no security holes and even if it's clean it certainly doesn't mean your code will be secure. Stuart I

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Adam Shannon
On Sun, Jul 19, 2009 at 10:00 AM, Govinda govinda.webdnat...@gmail.comwrote: Most security issues have nothing to do with the programming language and everything to do with the code. Just because facebook uses the .php extension certainly does not mean their code has no security holes and

Re: [PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Lenin
On Sun, Jul 19, 2009 at 10:00 AM, Govinda govinda.webdnat...@gmail.com wrote: * You turn expose_php off in your php.ini what does this one ^^^ do exactly ? expose_php boolean Decides whether PHP may expose the fact that it is installed on the server (e.g. by adding its signature

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Paul M Foster
On Sun, Jul 19, 2009 at 09:30:33AM +0530, kranthi wrote: You do realize that PHP does not parse HTML files, right? The web server does that. In fact, the web server also parses PHP files, using a different library. Kindly elaborate If you are saying that PHP cant parse files with

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Ashley Sheridan
On Sun, 2009-07-19 at 14:07 -0400, Paul M Foster wrote: On Sun, Jul 19, 2009 at 09:30:33AM +0530, kranthi wrote: You do realize that PHP does not parse HTML files, right? The web server does that. In fact, the web server also parses PHP files, using a different library. Kindly

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-19 Thread Stuart
2009/7/19 Paul M Foster pa...@quillandmouse.com: On Sun, Jul 19, 2009 at 09:30:33AM +0530, kranthi wrote: You do realize that PHP does not parse HTML files, right? The web server does that. In fact, the web server also parses PHP files, using a different library. Kindly elaborate If you

[PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Govinda
Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past.. but it is eluding me just now.. I can't figure out why files with the .html extension ARE being parsed by PHP when they are in the main doc root dir/, or in one subdirectory down from

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Govinda
On Jul 18, 2009, at 6:36 PM, Adam Shannon wrote: On Sat, Jul 18, 2009 at 7:01 PM, Govinda govinda.webdnat...@gmail.com wrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past.. but it is eluding me just now.. I can't figure out why

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Adam Shannon
On Sat, Jul 18, 2009 at 7:54 PM, Govinda govinda.webdnat...@gmail.comwrote: On Jul 18, 2009, at 6:36 PM, Adam Shannon wrote: On Sat, Jul 18, 2009 at 7:01 PM, Govinda govinda.webdnat...@gmail.comwrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Adam Shannon
On Sat, Jul 18, 2009 at 7:01 PM, Govinda govinda.webdnat...@gmail.comwrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past.. but it is eluding me just now.. I can't figure out why files with the .html extension ARE being parsed by PHP

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Paul M Foster
On Sat, Jul 18, 2009 at 06:01:14PM -0600, Govinda wrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past.. but it is eluding me just now.. I can't figure out why files with the .html extension ARE being parsed by PHP when they are in the

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread kranthi
i never used x-mapp-php5, but most of a forums say it is specific to 1and1 hosting service. php recommends application/x-httpd-php http://us2.php.net/manual/en/install.unix.apache2.php try adding AddType application/x-httpd-php .html in your root htaccess if that dosent help you'll have to add

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Govinda
Just add this to your root .htaccess AddType x-mapp-php5 .html Thanks Adam. But still no luck. I did add that line to the .htaccess file in my doc root, but my file.html in subdir/ is still not being parsed by PHP. ?? Try to put that same line of .htaccess into the sub directory. Your

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Govinda
You do realize that PHP does not parse HTML files, right? The web server does that. In fact, the web server also parses PHP files, using a different library. I understand. I just was saying it that way. Actually I rarely think too deeply about that specifically, but now that you pointed

[PHP] need to get .html files parsed by PHP. -- WAS: why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Govinda
i never used x-mapp-php5, but most of a forums say it is specific to 1and1 hosting service. php recommends application/x-httpd-php http://us2.php.net/manual/en/install.unix.apache2.php try adding AddType application/x-httpd-php .html in your root htaccess hmmm. Darn! I just did try what

Re: [PHP] why does PHP parse *.html files in one subdir/ but not in another?

2009-07-18 Thread Jim Lucas
Govinda wrote: Hi all, ..sitting here thinking this is so easy, and I must have been over this already in the past.. but it is eluding me just now.. I can't figure out why files with the .html extension ARE being parsed by PHP when they are in the main doc root dir/, or in one subdirectory

Re: [PHP] Parse ini file problem

2009-05-21 Thread Jim Lucas
Thodoris wrote: I am trying to parse an ini conf file using parse_ini_file but fails without returning something. I found this which is probably the reason: http://bugs.php.net/bug.php?id=44544 (the $ in the values) The problem is that this file has more than 7500 lines so it's kind of

[PHP] Parse ini file problem

2009-05-15 Thread Thodoris
I am trying to parse an ini conf file using parse_ini_file but fails without returning something. I found this which is probably the reason: http://bugs.php.net/bug.php?id=44544 (the $ in the values) The problem is that this file has more than 7500 lines so it's kind of difficult to use

RE: [PHP] Parse domain from URL

2007-06-08 Thread Brad Fuller
Tijnema wrote: On 6/7/07, Brad Fuller [EMAIL PROTECTED] wrote: Robin Vickery wrote: In that case you can't do it just by parsing alone, you need to use DNS. ?php function get_domain ($hostname) { dns_get_record($hostname, DNS_A, $authns, $addt); return $authns[0]['host']; }

Re: [PHP] Parse domain from URL

2007-06-07 Thread Robin Vickery
On 06/06/07, Brad Fuller [EMAIL PROTECTED] wrote: Daniel Brown wrote: On 6/6/07, Brad Fuller [EMAIL PROTECTED] wrote: I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the hostname. And my first thought was to take the last 2

Re: [PHP] Parse domain from URL

2007-06-07 Thread Daniel Brown
On 6/7/07, Robin Vickery [EMAIL PROTECTED] wrote: On 06/06/07, Brad Fuller [EMAIL PROTECTED] wrote: Daniel Brown wrote: On 6/6/07, Brad Fuller [EMAIL PROTECTED] wrote: I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the

RE: [PHP] Parse domain from URL

2007-06-07 Thread Brad Fuller
Robin Vickery wrote: In that case you can't do it just by parsing alone, you need to use DNS. ?php function get_domain ($hostname) { dns_get_record($hostname, DNS_A, $authns, $addt); return $authns[0]['host']; } print get_domain(www.google.com) . \n; print get_domain(google.com) .

Re: [PHP] Parse domain from URL

2007-06-07 Thread Tijnema
On 6/7/07, Brad Fuller [EMAIL PROTECTED] wrote: Robin Vickery wrote: In that case you can't do it just by parsing alone, you need to use DNS. ?php function get_domain ($hostname) { dns_get_record($hostname, DNS_A, $authns, $addt); return $authns[0]['host']; } print

[PHP] Parse domain from URL

2007-06-06 Thread Brad Fuller
Hey guys, I'm faced with an interesting problem, and wondering if there's an easy solution. I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the hostname. And my first thought was to take the last 2 segments of the hostname to get the

Re: [PHP] Parse domain from URL

2007-06-06 Thread Robert Cummings
On Wed, 2007-06-06 at 11:43 -0400, Brad Fuller wrote: Hey guys, I'm faced with an interesting problem, and wondering if there's an easy solution. I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the hostname. And my first thought

Re: [PHP] Parse domain from URL

2007-06-06 Thread Daniel Brown
On 6/6/07, Brad Fuller [EMAIL PROTECTED] wrote: Hey guys, I'm faced with an interesting problem, and wondering if there's an easy solution. I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the hostname. And my first thought was to take

RE: [PHP] Parse domain from URL

2007-06-06 Thread Brad Fuller
Daniel Brown wrote: On 6/6/07, Brad Fuller [EMAIL PROTECTED] wrote: Hey guys, I'm faced with an interesting problem, and wondering if there's an easy solution. I need to strip out a domain name from a URL, and ignore subdomains (like www) I can use parse_url to get the hostname. And

Re[2]: [PHP] Parse domain from URL

2007-06-06 Thread Richard Davey
Hi Brad, Wednesday, June 6, 2007, 5:04:41 PM, you wrote: Yes, that's basically what my code already does. The problem is that what if the url is http://yahoo.co.uk/; (note the lack of a subdomain) Your script thinks that the domain is co.uk. Just like my existing code does. So we can't

RE: [PHP] Parse domain from URL

2007-06-06 Thread Stefan Wixfort
From: Brad Fuller [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 06, 2007 5:44 PM Subject: [PHP] Parse domain from URL Hey guys, I'm faced with an interesting problem, and wondering if there's an easy solution. I need to strip out a domain name from a URL, and ignore subdomains

RE: [PHP] parse error

2007-05-04 Thread Brad Sumrall
] Sent: Friday, May 04, 2007 9:43 PM To: Brad Sumrall Subject: Re: [PHP] parse error }else{ Brad Sumrall wrote: Hi folk, I am writing a login in script and get the following: Parse error: parse error, unexpected T_ELSE in /home/content/c/u/t/cuteirka/html/commonlogin_new.php on line 37 I am

RE: [PHP] parse error

2007-05-04 Thread Brad Sumrall
, 2007 9:43 PM To: Brad Sumrall Subject: Re: [PHP] parse error }else{ Brad Sumrall wrote: Hi folk, I am writing a login in script and get the following: Parse error: parse error, unexpected T_ELSE in /home/content/c/u/t/cuteirka/html/commonlogin_new.php on line 37 I am basically pulling

RE: [PHP] parse error

2007-05-04 Thread Brad Sumrall
Maybe not The following passes me on without error, but does not actually log me on? Put in a fake name, and it still passes me on to the index page. I took this straight off the phpbb help files? Brad ?php if(!isset($_SESSION[userid])) { ? form action=/phpbb/index.php

[PHP] Parse error on a basic call?

2007-04-28 Thread Brad Sumrall
$SESSION = get_include_contents'/phpbb/login.php'; I pulled this tright out of the text book. I am trying to pull a phpbb session on an outside page. Any suggestions? Here is the error! Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in

Re: [PHP] Parse error on a basic call?

2007-04-28 Thread Edward Vermillion
On Apr 28, 2007, at 9:08 PM, Brad Sumrall wrote: $SESSION = get_include_contents'/phpbb/login.php'; I pulled this tright out of the text book. I am trying to pull a phpbb session on an outside page. Any suggestions? Here is the error! Parse error: parse error, unexpected

[PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Hi everyone, i am new to PHP, but not a programmer.., i got this php code to workout on something on my blog, but it seems that it gives me the following error: Parse error: syntax error, unexpected ';' in /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15 ul class=labels

Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Davi
Em Sexta 30 Março 2007 18:55, Ian escreveu: Parse error: syntax error, unexpected ';' in /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15 ul class=labels ?php 1 define('PREFIX', 'http://.x.com/labels'); 2

Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Tijnema !
On 3/30/07, Ian [EMAIL PROTECTED] wrote: Hi everyone, i am new to PHP, but not a programmer.., i got this php code to workout on something on my blog, but it seems that it gives me the following error: Parse error: syntax error, unexpected ';' in

Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Hehe.., didn't i told i am poor in this, actually, never learn PHP before.. :) No more such errors anymore thank you Tijnema! =) Ian Tijnema ! [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On 3/30/07, Ian [EMAIL PROTECTED] wrote: Hi everyone, i am new to PHP, but not a

Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Thanks very much for the help, Davi,, no more such errors.. :) Ian Davi [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Em Sexta 30 Março 2007 18:55, Ian escreveu: Parse error: syntax error, unexpected ';' in /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15 ul

[PHP] Parse

2007-03-14 Thread al phillips
I keep getting a parse error line x when trying view php info() Can you help please? - Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games.

Re: [PHP] Parse

2007-03-14 Thread Andrei
al phillips wrote: I keep getting a parse error line x when trying view php info() Can you help please? - Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. . And the code you use would look like?

[PHP] Re: [!! SPAM] [PHP] Parse

2007-03-14 Thread Andrei
al phillips wrote: I keep getting a parse error line x when trying view php info() Can you help please? - Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. . Or maybe you should try with phpinfo() ?

Re: [PHP] Parse

2007-03-14 Thread Németh Zoltán
2007. 03. 14, szerda keltezéssel 07.53-kor al phillips ezt írta: I keep getting a parse error line x when trying view php info() Can you help please? no, if you don't post the exact error message and your code here btw, it is probably a typo in your code at line x, but we cannot see it as

Re: [PHP] Re: [!! SPAM] [PHP] Parse

2007-03-14 Thread Tijnema !
On 3/14/07, Andrei [EMAIL PROTECTED] wrote: al phillips wrote: I keep getting a parse error line x when trying view php info() Can you help please? - Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. .

Re: [PHP] Parse

2007-03-14 Thread Richard Lynch
?php phpinfo();? No space in the function name 'phpinfo' If that's not it, show us your source code. On Wed, March 14, 2007 9:53 am, al phillips wrote: I keep getting a parse error line x when trying view php info() Can you help please? - Be a PS3

[PHP] Parse Errors with 5.2 on Linux

2006-11-07 Thread Michael Caplan
Hi there, I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse error: Parse error: syntax error, unexpected $end in /xxx/xxx/xxx/functions.php on line 1213 This very script parses just

Re: [PHP] Parse Errors with 5.2 on Linux

2006-11-07 Thread Richard Lynch
On Tue, November 7, 2006 11:30 am, Michael Caplan wrote: I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse error: Parse error: syntax error, unexpected $end in /xxx/xxx/xxx/functions.php on

RE: [PHP] Parse Errors with 5.2 on Linux

2006-11-07 Thread Michael Caplan
To: Michael Caplan Cc: php-general@lists.php.net Subject: Re: [PHP] Parse Errors with 5.2 on Linux On Tue, November 7, 2006 11:30 am, Michael Caplan wrote: I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse

Re: [PHP] Parse Errors with 5.2 on Linux

2006-11-07 Thread Stut
Richard Lynch wrote: I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] Certainly hasn't changed, and I hope it never does. Having to find an errant space or carriage return at the end of an include file that is one of

Re: [PHP] Parse Errors with 5.2 on Linux

2006-11-07 Thread Robert Cummings
On Tue, 2006-11-07 at 21:18 +, Stut wrote: Richard Lynch wrote: I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] Certainly hasn't changed, and I hope it never does. Having to find an errant space or carriage

[PHP] parse text file

2006-07-23 Thread Benjamin Adams
how would I read a file one line at a time: ?php if($lines $alllines){ $newline .= $lines; } ? something like that, I'm cofused on if I use fread, something which will do one line at a time? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] parse text file

2006-07-23 Thread Joe Wollard
Benjamin, Use the file() function, it will read a file then return each line as a new element in an array. http://php.net/file - Joe On 7/23/06, Benjamin Adams [EMAIL PROTECTED] wrote: how would I read a file one line at a time: ?php if($lines $alllines){ $newline .= $lines; } ?

Re: [PHP] parse text file

2006-07-23 Thread Sameer N Ingole
Joe Wollard wrote: Benjamin, Use the file() function, it will read a file then return each line as a new element in an array. http://php.net/file And if file is big (biiig) then you want http://php.net/fgets -- Sameer N. Ingole http://weblogic.noroot.org/ --- Better to light one candle

Re: [PHP] parse text file

2006-07-23 Thread Stut
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Joe Wollard wrote: Use the file() function, it will read a file then return each line as a new element in an array. http://php.net/file This will not read the file one line at a time. Try http://php.net/fgets. - -Stut On 7/23/06, Benjamin Adams

Re: [PHP] parse text file

2006-07-23 Thread Benjamin Adams
Thanks, fgets works great didn't know the function before. On Mon, 2006-07-24 at 01:56 +0530, Sameer N Ingole wrote: Joe Wollard wrote: Benjamin, Use the file() function, it will read a file then return each line as a new element in an array. http://php.net/file And if file is big

[PHP] parse error

2006-07-10 Thread Schalk
Greetings All, Please have a look at the following code: if ($numrows 1) // the member does not exist { include ($adminfolderpath./include/headeradmin.php); echo pThat email does not exist in the members list./p; echo pa href='login.php'Please login/a./p; include

Re: [PHP] parse error

2006-07-10 Thread Jochem Maas
Schalk wrote: Greetings All, Please have a look at the following code: your missing a closing brace some where - by the looks of things not in the code you sent. if ($numrows 1) // the member does not exist { include ($adminfolderpath./include/headeradmin.php); echo pThat email

Re: [PHP] parse error

2006-07-10 Thread Schalk
Thanks everyone. Jochem Maas wrote: Schalk wrote: Greetings All, Please have a look at the following code: your missing a closing brace some where - by the looks of things not in the code you sent. if ($numrows 1) // the member does not exist { include

Re: [PHP] parse error

2006-07-10 Thread Paul Novitski
At 08:11 AM 7/10/2006, Schalk wrote: I am getting the following error:* Parse error*: parse error, unexpected $ in */home/httpd/vhosts/demo.bdiverse.com/httpdocs/accessible/processlogin.php* on line *69 In my code the last line i.e. ? is marked as line 69 I don't see anything wrong with

[PHP] Parse error: syntax error, unexpected '}'

2006-06-02 Thread Mark Sargent
Hi All, can anone see what's wrong with the below code? I get this error, *Parse error*: syntax error, unexpected '}' in */usr/local/apache2/htdocs/moviedata2.php* on line *18 * $age=1; while($age=100) { $insert = INSERT INTO age (age_label) VALUES ($age); $results = mysql_query($insert) or

Re: [PHP] Parse error: syntax error, unexpected '}'

2006-06-02 Thread Rick Emery
Quoting Mark Sargent [EMAIL PROTECTED]: Hi All, can anone see what's wrong with the below code? I get this error, *Parse error*: syntax error, unexpected '}' in */usr/local/apache2/htdocs/moviedata2.php* on line *18 * $age=1; while($age=100) { $insert = INSERT INTO age (age_label) VALUES

RE: [PHP] Parse error: syntax error, unexpected '}'

2006-06-02 Thread Bagus Nugroho
how about like this --- $insert = INSERT INTO age (age_label) VALUES ('$age'); --- From: Mark Sargent [mailto:[EMAIL PROTECTED] Sent: Sat 03-Jun-2006 10:02 To: PHP List Subject: [PHP] Parse error: syntax error, unexpected '}' Hi All, can anone see what's

Re: [PHP] Parse error: syntax error, unexpected '}'

2006-06-02 Thread Mark Sargent
Hi All, sorry, found it. Forgot the ; after $age++. Cheers. Mark Sargent. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Recall: [PHP] Parse error: syntax error, unexpected '}'

2006-06-02 Thread Bagus Nugroho
Bagus Nugroho would like to recall the message, [PHP] Parse error: syntax error, unexpected '}'.

[PHP] Parse string with variables

2006-05-31 Thread Merlin
Hi there, I am trying to parse a plain text which contains variables. The string looks like this: P=1 U=test T=ok P=2 U=test2 T=anything How could I create arrays out of this. To be able to access the values like this: echo $P[1]; parse_str does not work here and I could not find another

[PHP] Parse error: syntax error, unexpected T_VARIABLE, expecting ',' or ';' in

2006-05-25 Thread Mark Sargent
Hi All, I get the error for line 15 for this code, ?php 15 echo font face='$_SESSION['font']'; 16 echo size='$_SESSION['size']'; 17 echo color='$_SESSION['colour']'; 18 echo $_SESSION['text']; 19 echo /font; 20 ? I have put ' ' quotes around the quotes for each font

Re: [PHP] Parse error: syntax error, unexpected T_VARIABLE, expecting ',' or ';' in

2006-05-25 Thread Ryan Creaser
Mark Sargent wrote: Hi All, I get the error for line 15 for this code, ?php 15 echo font face='$_SESSION['font']'; 16 echo size='$_SESSION['size']'; 17 echo color='$_SESSION['colour']'; 18 echo $_SESSION['text']; 19 echo /font; 20 ? I have put ' ' quotes around

  1   2   3   4   5   6   >