Re: [PHP] Mysql search

2008-10-22 Thread Ryan S
clipp Am hoping someone out there can recommend a better script or maybe share some of your own code? Any help would be appreciated. Do it right... read up on MySQL's fulltext matching. Cheers, Rob. /clipp Did some searching based on your tip, got what i was looking for, just didnt

Re: [PHP] Mass email

2008-10-22 Thread Andrew Johnstone
Before considering outsourcing this you should consider the following. 1. Frequency of emails, I.e daily, weekly, monthly etc. 2. Hosting, are you on dedicated servers, shared hosting. a) do you control the domain name, enough to enable rDNS. b) does your hosting company restrict out going

Re: [PHP] ZendOptimizer + APC

2008-10-22 Thread Sancar Saran
On Tuesday 21 October 2008 19:35:53 Jochem Maas wrote: anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts of problems ... I know it did in the past but I can't find any very recent stuff about the issues online. You have to buy Zend Performance platform. Thats

Re: [PHP] ZendOptimizer + APC

2008-10-22 Thread Jochem Maas
Sancar Saran schreef: On Tuesday 21 October 2008 19:35:53 Jochem Maas wrote: anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts of problems ... I know it did in the past but I can't find any very recent stuff about the issues online. You have to buy Zend

[PHP] Re: PHP Dev Facts

2008-10-22 Thread Peter Ford
Nathan Rixham wrote: Evening All, I'd be /really/ interested to know who uses what! *Procedural or OOP?* OOP - I have a Java background... *Dev OS* OpenSuSE 10.3 *Dev PHP Version* 5.2.5 *Live Server OS* OpenSuSE 10.3 *Live Server PHP Version* 5.2.5 (of course - why dev on

Re: [PHP] ZendOptimizer + APC

2008-10-22 Thread Jochem Maas
Nathan Nobbe schreef: On Tue, Oct 21, 2008 at 10:35 AM, Jochem Maas [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts of problems ... I know it did in the past but I can't find any very

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 00:22, Jochem Maas wrote: Stut schreef: I use destructors to update dirty objects in memcache. care to eloborate ... sounds interesting. Nothing complicated. The core objects in my application are all cached in memcache. If anything changes in an object it changes an

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Jochem Maas
Stut schreef: On 22 Oct 2008, at 00:22, Jochem Maas wrote: Stut schreef: I use destructors to update dirty objects in memcache. care to eloborate ... sounds interesting. Nothing complicated. The core objects in my application are all cached in memcache. If anything changes in an object it

Re: [PHP] Politics

2008-10-22 Thread David Robley
Jim Lucas wrote: Chrome wrote: -Original Message- From: Amy [mailto:[EMAIL PROTECTED] Sent: 21 October 2008 11:58 To: php-general@lists.php.net Subject: [PHP] Politics representations emphasizing leksr matching thirds painfully wakesleep ekswiezeezeewie accompanied Have you

[PHP] Re: -help

2008-10-22 Thread David Robley
devta singh wrote: -help: invalid argument Cheers -- David Robley I used to have a handle on life, then it broke. Today is Setting Orange, the 3rd day of The Aftermath in the YOLD 3174. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] redeclare classes dynamically

2008-10-22 Thread viraj
i'm trying to dynamically initialize bunch of classes from different paths but with the same class and file names. while ($register-request-m != 'exit') { $controlFile = './core/' . $register-request-m . '/controller.class.php'; if (is_file($controlFile)) {

[PHP] Re: Singletons

2008-10-22 Thread Carlos Medina
Hi, here is in my opinion, what you can do: class Base { private $foo; private function __construct() {} public function getFoo() { return $this-foo; } public function setFoo( $foo ) { $this-foo = $foo; } } class Singleton extends Base { public function

Re: [PHP] Re: -help

2008-10-22 Thread Yeti
-help: invalid argument I like the way you handle input errors in your php-general subroutines David. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] How to Execute Exe File from PHP

2008-10-22 Thread Ian
On 22 Oct 2008 at 2:14, Alice Wei wrote: HI, To answer your questions, I run this on Windows. What is so weird is that when I do $a= shell_exec(C:\Inetpub\wwwroot\/test.exe -m$market -d$length); echo $a; It works, and echoes everything as it is supposed to, and the file is

[PHP] Half way

2008-10-22 Thread Ron Piggott
I am tweaking a blog application I have programmed. I am trying to display a Google ad half through the blog entry, at the first available br /. The code I use so far is: $half_way = strlen( nl2br(stripslashes($entry))) /2 ; $ad_position = strpos ( nl2br(stripslashes($entry)) , br / ,

Re: [PHP] Half way

2008-10-22 Thread Ian
On 22 Oct 2008 at 6:34, Ron Piggott wrote: I am tweaking a blog application I have programmed. I am trying to display a Google ad half through the blog entry, at the first available br /. The code I use so far is: $half_way = strlen( nl2br(stripslashes($entry))) /2 ; $ad_position =

[PHP] Re: Singletons

2008-10-22 Thread Carlos Medina
Colin Guthrie schrieb: Stut wrote: On 20 Oct 2008, at 20:24, Christoph Boget wrote: public function __construct() A singleton would usually have a private constructor to prevent non-singleton instances. The problem being if the class in question derives from another class that has a public

[PHP] Re: Singletons

2008-10-22 Thread Colin Guthrie
Stut wrote: On 20 Oct 2008, at 20:24, Christoph Boget wrote: public function __construct() A singleton would usually have a private constructor to prevent non-singleton instances. The problem being if the class in question derives from another class that has a public constructor... If you

[PHP] Problem changing file encoding

2008-10-22 Thread Thodoris
Hi guys, I am developing a project and I wrote an interface to import contracts in it. The problem is that when the user uploads the file I don't know what is the encoding it has. So I decided that a good idea is to make the user tell me the encoding from a drop down before I parse the file.

Re: [PHP] Problem changing file encoding

2008-10-22 Thread Ian
On 22 Oct 2008 at 14:39, Thodoris wrote: Hi guys, I am developing a project and I wrote an interface to import contracts in it. The problem is that when the user uploads the file I don't know what is the encoding it has. So I decided that a good idea is to make the user tell me the

Re: [PHP] Problem changing file encoding

2008-10-22 Thread Yeti
A neat way to transcode between different encodings is htmlentities and html_entity_decode [1, 2] EXAMPLE: ?php # encode a string in UTF-8 to html entities $string = 'øæåöäü'; $string = htmlentities($string, ENT_QUOTES, 'UTF-8'); # transcode it into ISO-8859-15 $string =

Re: [PHP] Problem changing file encoding

2008-10-22 Thread Thodoris
On 22 Oct 2008 at 14:39, Thodoris wrote: Hi guys, I am developing a project and I wrote an interface to import contracts in it. The problem is that when the user uploads the file I don't know what is the encoding it has. So I decided that a good idea is to make the user tell me the

Re: [PHP] Re: Singletons

2008-10-22 Thread Christoph Boget
here is in my opinion, what you can do: class Base { private function __construct() Except that in one of my follow up posts I indicated that my singleton class was deriving from a class that had a public constructor. Thanks anyway. I ended up just using Stut's suggestion. As he said, it's

Re: [PHP] Re: -help

2008-10-22 Thread Jay Moore
Yeti wrote: -help: invalid argument I like the way you handle input errors in your php-general subroutines David. I don't. It says nothing about what a valid argument is. Horrible newsgroup coding, imo. I wouldn't be surprised if he has register_globals on. -- PHP General Mailing List

[PHP] looking for group/playlist functionality... (sort of!!)

2008-10-22 Thread bruce
Hi.. Working on a project, and I need to be able to allow the user to create groups of files from a list of files. (all of this is php/web-based) As I'm going though what I'm going to need, it occurred to me that someone's hopefully/probably already created the basic logic for this in someother

[PHP] Re: Singletons

2008-10-22 Thread Colin Guthrie
Carlos Medina wrote: this is the Result of my test with your Code: Fatal error: Access level to Singleton::__construct() must be public (as in class Base) in C:\Users\cmedina\Documents\test1.php on line 30 Hmmm, that'll learn me for not running it first I sps :s Well that is completely

[PHP] Re: re[PHP] declare classes dynamically

2008-10-22 Thread Martijn Korse
Defining multiple classes with the same name but different implementation doesn't seem like a good idea to me. Why did you choose to do this? also, have a look at this function: http://www.php.net/autoload i'm not sure what you're trying to accomplish exactly, but whatever it is, it might be

Re: [PHP] looking for group/playlist functionality... (sort of!!)

2008-10-22 Thread Børge Holen
hmm mpd/mpc allows much of what you ask, for a playlist that is. I made a frontend to this deamon using php. don't know about that disabling/enabling feature but I recon that part can be done php only. On Oct 22, 2008, at 3:15 PM, bruce wrote: Hi.. Working on a project, and I need to be

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Dan Joseph
On Tue, Oct 21, 2008 at 5:14 PM, Stut [EMAIL PROTECTED] wrote: When a script ends everything is released (with some small exceptions), thus also all references to instances of classes. Thus AFAIK a deconstructor will always be called at the end of script execution. but you have no

Re: [PHP] Re: -help

2008-10-22 Thread Yeti
Well maybe it is because he has register_globals on why he is not printing a list of valid arguments. imagine something like this .. @php-generals$ [PHP] -help List of valid arguments: -c, --make-me-forget erases the built-in mainframe's short term memory -f, --flush-me erases the entire memory

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Eric Butera
On Wed, Oct 22, 2008 at 9:42 AM, Dan Joseph [EMAIL PROTECTED] wrote: On Tue, Oct 21, 2008 at 5:14 PM, Stut [EMAIL PROTECTED] wrote: When a script ends everything is released (with some small exceptions), thus also all references to instances of classes. Thus AFAIK a deconstructor will

Re: [PHP] Half way

2008-10-22 Thread Jochem Maas
Ian schreef: On 22 Oct 2008 at 6:34, Ron Piggott wrote: I am tweaking a blog application I have programmed. I am trying to display a Google ad half through the blog entry, at the first available br /. The code I use so far is: $half_way = strlen( nl2br(stripslashes($entry))) /2 ;

Re: [PHP] redeclare classes dynamically

2008-10-22 Thread uaca man
From your code it looks like $controller will have only the last instance to the controller class, so you can only load the last request and instantiate only one time. Other alternative is to use namespaces but this is only for PHP 5.3 or you can do what everyone else does from the begging of

RE: [PHP] Half way

2008-10-22 Thread Boyd, Todd M.
-Original Message- From: Jochem Maas [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 22, 2008 10:27 AM To: [EMAIL PROTECTED] Cc: PHP General Subject: Re: [PHP] Half way Ian schreef: On 22 Oct 2008 at 6:34, Ron Piggott wrote: I am tweaking a blog application I have

[PHP] Difficulty navigating symlinks

2008-10-22 Thread Seth Foss
Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then using symbolic links to access the rest of the code for

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Robert Cummings
On Wed, 2008-10-22 at 11:59 -0400, Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then

Re: [PHP] ZendOptimizer + APC

2008-10-22 Thread Nathan Nobbe
On Wed, Oct 22, 2008 at 2:13 AM, Jochem Maas [EMAIL PROTECTED] wrote: Nathan Nobbe schreef: On Tue, Oct 21, 2008 at 10:35 AM, Jochem Maas [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Jim Lucas
Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then using symbolic links to access the

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Seth Foss
Robert Cummings wrote: On Wed, 2008-10-22 at 11:59 -0400, Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Seth Foss
Jim Lucas wrote: Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then using symbolic links to

[PHP] Source Code Analysis

2008-10-22 Thread Dee Ayy
Is there a tool that can analyze PHP source code and detect if the code is relying on register_globals still being on? Perhaps detecting if a variable has not been initialized within the code? These are my specific needs, but I'm also interested in general SCA tools and features. -- PHP

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Robert Cummings
On Wed, 2008-10-22 at 13:16 -0400, Seth Foss wrote: Robert Cummings wrote: On Wed, 2008-10-22 at 11:59 -0400, Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to

Re: [PHP] Source Code Analysis

2008-10-22 Thread Robert Cummings
On Wed, 2008-10-22 at 12:24 -0500, Dee Ayy wrote: Is there a tool that can analyze PHP source code and detect if the code is relying on register_globals still being on? Perhaps detecting if a variable has not been initialized within the code? These are my specific needs, but I'm also

[PHP] Re: Problem changing file encoding

2008-10-22 Thread Nathan Rixham
Thodoris wrote: Hi guys, I am developing a project and I wrote an interface to import contracts in it. The problem is that when the user uploads the file I don't know what is the encoding it has. So I decided that a good idea is to make the user tell me the encoding from a drop down before I

Re: [PHP] Source Code Analysis

2008-10-22 Thread Nathan Rixham
Robert Cummings wrote: On Wed, 2008-10-22 at 12:24 -0500, Dee Ayy wrote: Is there a tool that can analyze PHP source code and detect if the code is relying on register_globals still being on? Perhaps detecting if a variable has not been initialized within the code? These are my specific

Re: [PHP] Re: -help

2008-10-22 Thread Nathan Rixham
Yeti wrote: Well maybe it is because he has register_globals on why he is not printing a list of valid arguments. imagine something like this .. @php-generals$ [PHP] -help List of valid arguments: -c, --make-me-forget erases the built-in mainframe's short term memory -f, --flush-me erases the

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Jim Lucas
Seth Foss wrote: Jim Lucas wrote: Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Yeti
If you are in control of you DNS records you could CNAME [1] the sites to the same address, where a PHP script or RewriteRule [2] loads the specific configuration by checking the requested URI. Since you got them on the same server anyways this would not cost any performance. [1]

Re: [PHP] Source Code Analysis

2008-10-22 Thread Jim Lucas
Dee Ayy wrote: Is there a tool that can analyze PHP source code and detect if the code is relying on register_globals still being on? Perhaps detecting if a variable has not been initialized within the code? These are my specific needs, but I'm also interested in general SCA tools and

Re: [PHP] Source Code Analysis

2008-10-22 Thread Greg Bowser
Perhaps detecting if a variable has not been initialized within the code This is an E_NOTICE level error. ?php error_reporting(E_ALL); $foo++; ? [EMAIL PROTECTED] ~ $ php test.php Notice: Undefined variable: foo in /home/mario/test.php on line 3

Re: [PHP] export data to a ms excel file using php

2008-10-22 Thread Jim Lucas
[EMAIL PROTECTED] wrote: Hi, I have tried your MS-Excel MIME type in PHP. But am facing a small problem. I can't get the grid lines as look like in normal Excel file. Am using windows XP, Internet explorer 6.0, MS Excel 2003 Thanks in advance.-- Jim Lucas wrote : abderrazzak nejeoui

[PHP] DLL

2008-10-22 Thread Alain Roger
Hi, i would like to know if it exists a way to create component (maybe using python, perl, or something else) to save it as DLL and to use this component on PHP pages ? i mean by component something like a graphical representation of a table. this dll should be able to be dynamically loaded by

Re: [PHP] DLL

2008-10-22 Thread Stut
On 22 Oct 2008, at 19:21, Alain Roger wrote: i would like to know if it exists a way to create component (maybe using python, perl, or something else) to save it as DLL and to use this component on PHP pages ? i mean by component something like a graphical representation of a table. this

Re: [PHP] Difficulty navigating symlinks

2008-10-22 Thread Stut
On 22 Oct 2008, at 18:16, Seth Foss wrote: Robert Cummings wrote: On Wed, 2008-10-22 at 11:59 -0400, Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 14:42, Dan Joseph wrote: On Tue, Oct 21, 2008 at 5:14 PM, Stut [EMAIL PROTECTED] wrote: When a script ends everything is released (with some small exceptions), thus also all references to instances of classes. Thus AFAIK a deconstructor will always be called at the end of

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Stut
On 22 Oct 2008, at 09:35, Jochem Maas wrote: Stut schreef: On 22 Oct 2008, at 00:22, Jochem Maas wrote: Stut schreef: I use destructors to update dirty objects in memcache. care to eloborate ... sounds interesting. Nothing complicated. The core objects in my application are all cached

[PHP] Re: Difficulty navigating symlinks

2008-10-22 Thread Shawn McKenzie
Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration files for each site, then using symbolic links to access the

RE: [PHP] Half way

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 10:43 -0500, Boyd, Todd M. wrote: -Original Message- From: Jochem Maas [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 22, 2008 10:27 AM To: [EMAIL PROTECTED] Cc: PHP General Subject: Re: [PHP] Half way Ian schreef: On 22 Oct 2008 at 6:34, Ron

Re: [PHP] Source Code Analysis

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 11:16 -0700, Jim Lucas wrote: Dee Ayy wrote: Is there a tool that can analyze PHP source code and detect if the code is relying on register_globals still being on? Perhaps detecting if a variable has not been initialized within the code? These are my specific

[PHP] E_STUPID

2008-10-22 Thread ceo
I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a', 'b', 'c'); $query = select * from foo where foo in ('$foo'); It's been one of those days... -- PHP General Mailing

Re: [PHP] export data to a ms excel file using php

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 11:20 -0700, Jim Lucas wrote: [EMAIL PROTECTED] wrote: Hi, I have tried your MS-Excel MIME type in PHP. But am facing a small problem. I can't get the grid lines as look like in normal Excel file. Am using windows XP, Internet explorer 6.0, MS Excel 2003

Re: [PHP] E_STUPID

2008-10-22 Thread Stut
On 22 Oct 2008, at 19:37, [EMAIL PROTECTED] wrote: I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a', 'b', 'c'); $query = select * from foo where foo in ('$foo'); It's been one

Re: [PHP] Re: Question about __destruct()

2008-10-22 Thread Dan Joseph
On Wed, Oct 22, 2008 at 2:29 PM, Stut [EMAIL PROTECTED] wrote: Never any issues this way? They always run without a hitch? Not had any issues to far, and it's being used on some pretty busy sites and various PHP versions and several different web servers. Terrific! Thanks for the

[PHP] Re: E_STUPID

2008-10-22 Thread Jay Moore
[EMAIL PROTECTED] wrote: I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a', 'b', 'c'); $query = select * from foo where foo in ('$foo'); It's been one of those days... Yeah

Re: [PHP] E_STUPID

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 20:04 +0100, Stut wrote: On 22 Oct 2008, at 19:37, [EMAIL PROTECTED] wrote: I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a', 'b', 'c'); $query

Re: [PHP] Politics

2008-10-22 Thread Shawn McKenzie
David Robley wrote: Jim Lucas wrote: Chrome wrote: -Original Message- From: Amy [mailto:[EMAIL PROTECTED] Sent: 21 October 2008 11:58 To: php-general@lists.php.net Subject: [PHP] Politics representations emphasizing leksr matching thirds painfully wakesleep ekswiezeezeewie

Re: [PHP] Re: Difficulty navigating symlinks

2008-10-22 Thread Robert Cummings
On Wed, 2008-10-22 at 13:43 -0500, Shawn McKenzie wrote: Seth Foss wrote: Hi everyone, I am trying to run multiple sites on the same server, that have mostly identical code - a pre-built application. Anyway, I would like to save disk space by specifying independent configuration

Re: [PHP] Politics

2008-10-22 Thread Robert Cummings
On Wed, 2008-10-22 at 14:13 -0500, Shawn McKenzie wrote: David Robley wrote: Jim Lucas wrote: Chrome wrote: -Original Message- From: Amy [mailto:[EMAIL PROTECTED] Sent: 21 October 2008 11:58 To: php-general@lists.php.net Subject: [PHP] Politics representations

[PHP] mysqli, prepare and fetch_row

2008-10-22 Thread Marten Lehmann
Hello, I have a small piece of code where I'm trying to use mysqli with a prepare-statement. I don't want to bind variables for the fetch, instead I want to use something like list($question) = $stmt-fetch_row(); And this fetch_row should exist according to the documentation. But while

Re: [PHP] mysqli, prepare and fetch_row

2008-10-22 Thread Kyle Terry
You prepare the statement, execute it then use -fetch() to get the data. On Oct 22, 2008, at 1:36 PM, Marten Lehmann [EMAIL PROTECTED] wrote: Hello, I have a small piece of code where I'm trying to use mysqli with a prepare-statement. I don't want to bind variables for the fetch,

[PHP] XCache, APC, Memcached... confused

2008-10-22 Thread Martin Zvarík
Hi, I became confused after an hour trying to understand the PHP cache solutions. XCache, APC, eAccelerator and others are opcode cache systems... is memcache in the same category? or is it completely different? If I install for example XCache, set it for certain directory... it will

[PHP] Re: XCache, APC, Memcached... confused

2008-10-22 Thread Martin Zvarík
I guess the XCache everybody talks about is the open-source here: http://xcache.lighttpd.net/ But what about this: http://www.xcache.com/ ... is it the same author? :-O Martin Zvarík napsal(a): Hi, I became confused after an hour trying to understand the PHP cache solutions. XCache, APC,

Re: [PHP] Source Code Analysis

2008-10-22 Thread Dee Ayy
Thanks regarding the error_reporting. I may have to go this route for this specific issue. I was hoping a source code analyzer would report the same type problem, perhaps much faster than Robert's method, and without having a human attempt to test all functionality of the various PHP apps on old

Re: [PHP] E_STUPID

2008-10-22 Thread Jim Lucas
Ashley Sheridan wrote: On Wed, 2008-10-22 at 20:04 +0100, Stut wrote: On 22 Oct 2008, at 19:37, [EMAIL PROTECTED] wrote: I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a',

RE: [PHP] Re: Difficulty navigating symlinks

2008-10-22 Thread Boyd, Todd M.
-Original Message- From: Robert Cummings [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 22, 2008 3:02 PM To: Shawn McKenzie Cc: php-general@lists.php.net Subject: Re: [PHP] Re: Difficulty navigating symlinks On Wed, 2008-10-22 at 13:43 -0500, Shawn McKenzie wrote: Seth Foss

Re: [PHP] export data to a ms excel file using php

2008-10-22 Thread Nitsan Bin-Nun
And what about users who use office version 2003 (which do NOT support .xml charts) You can google a bit, I'm pretty sure I have already encountered a class for this case at Manuel's site (phpclasses). Nitsan On Wed, Oct 22, 2008 at 9:00 PM, Ashley Sheridan [EMAIL PROTECTED]wrote: On Wed,

Re: [PHP] export data to a ms excel file using php

2008-10-22 Thread ceo
The easiest solution is to output CSV, and use the Content-type to force it to be eXcel. Excel will suck the CSV in just fine, with minimal hassle by the user. It also makes a file that is useful for many more applications, not just Excel. -- PHP General Mailing List

Re: [PHP] Re: Difficulty navigating symlinks

2008-10-22 Thread Stut
On 22 Oct 2008, at 22:45, Boyd, Todd M. wrote: Haven't read the entire thread, but you might also look at http://php.net/manual/en/function.realpath.php realpath() won't help since it will just controbute the same problem... specifically he'll get the path were the page really exists instead

Re: [PHP] mysqli, prepare and fetch_row

2008-10-22 Thread Marten Lehmann
Hi, You prepare the statement, execute it then use -fetch() to get the data. but the documentation says, that -fetch() is only to fetch data to variables that have been bound with bind_result() before. But I want to use fetch_row() instead. Regards Marten -- PHP General Mailing List

Re: [PHP] XCache, APC, Memcached... confused

2008-10-22 Thread Stut
On 22 Oct 2008, at 22:19, Martin Zvarík wrote: I became confused after an hour trying to understand the PHP cache solutions. XCache, APC, eAccelerator and others are opcode cache systems... is memcache in the same category? or is it completely different? Memcache is completely different

Re: [PHP] export data to a ms excel file using php

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 22:04 +, [EMAIL PROTECTED] wrote: The easiest solution is to output CSV, and use the Content-type to force it to be eXcel. Excel will suck the CSV in just fine, with minimal hassle by the user. It also makes a file that is useful for many more

Re: [PHP] Re: XCache, APC, Memcached... confused

2008-10-22 Thread Stut
On 22 Oct 2008, at 22:24, Martin Zvarík wrote: I guess the XCache everybody talks about is the open-source here: http://xcache.lighttpd.net/ Indeed. But what about this: http://www.xcache.com/ ... is it the same author? :-O Nope, completely different commercial entity focused on hardware

[PHP] Re: ZendOptimizer + APC

2008-10-22 Thread Martin Zvarík
Jochem Maas napsal(a): anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts of problems ... I know it did in the past but I can't find any very recent stuff about the issues online. I believe you should look up eAccelerator or XCache, which should work with

Re: [PHP] Re: ZendOptimizer + APC

2008-10-22 Thread Nathan Nobbe
On Wed, Oct 22, 2008 at 4:39 PM, Martin Zvarík [EMAIL PROTECTED] wrote: Jochem Maas napsal(a): anyone know whether running ZendOptimizer + APC simultaneously still causes allsorts of problems ... I know it did in the past but I can't find any very recent stuff about the issues online. I

Re: [PHP] XCache, APC, Memcached... confused

2008-10-22 Thread Martin Zvarík
Thanks for reply Stut. So, the APC, XCache etc. doesn't work as FileCache and also doesn't decrease the number of database queries, since it is not caching the content... I see now, it is obvious that it would be very hard to run out of memory. -- Martin Stut napsal(a): On 22 Oct 2008,

Re: [PHP] XCache, APC, Memcached... confused

2008-10-22 Thread Martin Zvarík
I am looking at the eAccelerator's website and I realize what got me confused: there is a function for OUTPUT CACHE, so it actually could cache the whole website and then run out of memory I guess... that means I would be able to store anything into the memory and reference it by a

Re: [PHP] XCache, APC, Memcached... confused

2008-10-22 Thread Stut
On 23 Oct 2008, at 00:04, Martin Zvarík wrote: I am looking at the eAccelerator's website and I realize what got me confused: there is a function for OUTPUT CACHE, so it actually could cache the whole website and then run out of memory I guess... that means I would be able to store

[PHP] MkDir Help

2008-10-22 Thread Jason Todd Slack-Moehrle
Hi All, I want to make a directory on my web server programatically when my code to create a new user runs. I am running PHP 5.2.5 on Linux. I am running: $dirToCreate = ...$_SESSION['s_USER_URL']; mkdir($dirToCreate, 0777, TRUE); // create the directory for the user $dirToCreate is:

Re: [PHP] MkDir Help

2008-10-22 Thread Stut
On 23 Oct 2008, at 00:33, Jason Todd Slack-Moehrle wrote: I want to make a directory on my web server programatically when my code to create a new user runs. I am running PHP 5.2.5 on Linux. I am running: $dirToCreate = ...$_SESSION['s_USER_URL']; mkdir($dirToCreate, 0777, TRUE); // create

Re: [PHP] MkDir Help

2008-10-22 Thread Ashley Sheridan
On Wed, 2008-10-22 at 16:33 -0700, Jason Todd Slack-Moehrle wrote: Hi All, I want to make a directory on my web server programatically when my code to create a new user runs. I am running PHP 5.2.5 on Linux. I am running: $dirToCreate = ...$_SESSION['s_USER_URL'];

Re: [PHP] MkDir Help

2008-10-22 Thread Jason Todd Slack-Moehrle
Hi, Well, as your mkdir is saying you can only have 2 parameters, I'm guessing you're not yet running PHP 5. Also, as 0777 is the default mode, you can omit this from your code to leave only one argument. You didn't say the exact error you're getting when you omit the third argument. My guess

[PHP] CSV Files

2008-10-22 Thread Jason Todd Slack-Moehrle
Hi All, I need to take a record in MySQL and have my user get it as a CSV File. I am OK with most everything, except when I create the CSV file, I write out the column headers then I need to write out the data. After I right out the column headers do I have to put a '/n' to have it start

Re: [PHP] CSV Files

2008-10-22 Thread Eric Butera
On Wed, Oct 22, 2008 at 7:59 PM, Jason Todd Slack-Moehrle [EMAIL PROTECTED] wrote: Hi All, I need to take a record in MySQL and have my user get it as a CSV File. I am OK with most everything, except when I create the CSV file, I write out the column headers then I need to write out the data.

Re: [PHP] CSV Files

2008-10-22 Thread Stut
On 23 Oct 2008, at 00:59, Jason Todd Slack-Moehrle wrote: After I right out the column headers do I have to put a '/n' to have it start a new line in the CSV file? I think I do. A new line is \n not /n, and it must be in double quotes () not single ('). -Stut -- http://stut.net/ -- PHP

[PHP] Re: E_STUPID

2008-10-22 Thread Shawn McKenzie
[EMAIL PROTECTED] wrote: I think we need a new error reporting constant E_STUPID. This should catch stupid things I do like trying to embed an array into a string such as: $foo = array('a', 'b', 'c'); $query = select * from foo where foo in ('$foo'); It's been one of those days...

Re: [PHP] MkDir Help

2008-10-22 Thread Jim Lucas
Jason Todd Slack-Moehrle wrote: Hi All, I want to make a directory on my web server programatically when my code to create a new user runs. I am running PHP 5.2.5 on Linux. I am running: $dirToCreate = ...$_SESSION['s_USER_URL']; mkdir($dirToCreate, 0777, TRUE); // create the directory for

Re: [PHP] CSV Files

2008-10-22 Thread Jason Todd Slack-Moehrle
Hi Stut, Actually i am ending the row headers with a chr(10); // LINE FEED -Jason On Oct 22, 2008, at 5:12 PM, Stut wrote: On 23 Oct 2008, at 00:59, Jason Todd Slack-Moehrle wrote: After I right out the column headers do I have to put a '/n' to have it start a new line in the CSV file? I

Re: [PHP] CSV Files

2008-10-22 Thread Stut
On 23 Oct 2008, at 02:41, Jason Todd Slack-Moehrle wrote: Actually i am ending the row headers with a chr(10); // LINE FEED From the code you included in your original post... echo /n; There was no mention of chr(10). Outputting data in CSV format is not hard. Simply echo the header row

Re: [PHP] CSV Files

2008-10-22 Thread Jason Todd Slack-Moehrle
Oh, I am not putting quotes around each field that i get from MySQL. There are no quotes in the data so that is good. Sorry I put /n and I meant to put chr(10). -Jason On Oct 22, 2008, at 6:58 PM, Stut wrote: On 23 Oct 2008, at 02:41, Jason Todd Slack-Moehrle wrote: Actually i am ending

Re: [PHP] CSV Files

2008-10-22 Thread Robert Cummings
On Thu, 2008-10-23 at 02:58 +0100, Stut wrote: On 23 Oct 2008, at 02:41, Jason Todd Slack-Moehrle wrote: Actually i am ending the row headers with a chr(10); // LINE FEED From the code you included in your original post... echo /n; There was no mention of chr(10). Outputting

  1   2   >