Re: [PHP] OOP Newbie - why does this not work?

2005-10-20 Thread Stephen Leaf
Here is the working code You had __constructor() it's __construct() notice I also moved your saying declaration outside of the constructor. this is to make it a class level variable. the way that you had it set it was only in scope until you finished the construct code. I guess I was wrong about

Re: [PHP] OOP Newbie - why does this not work?

2005-10-20 Thread Stephen Leaf
Sorry.. 1 more thing. php5 does not use var. use public $variable=value; instead. public is only within a class however. you cannot use it outside. On Thursday 20 October 2005 09:35 pm, Bob Hartung wrote: > Hi all, >I'm trying to get started in OOP with PHP. I have the following > short code

[PHP] Re: SCRIPT_NAME

2005-10-20 Thread John Taylor-Johnston
Thanks! John -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] OOP Newbie - why does this not work?

2005-10-20 Thread Stephen Leaf
Try removing the /* and */ Other than that, check your brackets. you never closed the get() function's On Thursday 20 October 2005 09:35 pm, Bob Hartung wrote: > Hi all, >I'm trying to get started in OOP with PHP. I have the following > short code snipped. I'f I comment out the 'class Test'

[PHP] OOP Newbie - why does this not work?

2005-10-20 Thread Bob Hartung
Hi all, I'm trying to get started in OOP with PHP. I have the following short code snipped. I'f I comment out the 'class Test' definition and the following references to it, it prints This is outside the php code block and Start defining the class here: If I do not comment

Re: [PHP] SCRIPT_NAME

2005-10-20 Thread Robert Cummings
On Thu, 2005-10-20 at 23:27, Minuk Choi wrote: > Off the top of my head... > > $filename = $_SERVER['PHP_SELF']; > > $strippedFilename = substr($filename, strrpos($filename, '/')); Won't work, I'll leave the reason as an exercise :B Cheers, Rob. -- .

Re: [PHP] SCRIPT_NAME

2005-10-20 Thread Minuk Choi
Off the top of my head... $filename = $_SERVER['PHP_SELF']; $strippedFilename = substr($filename, strrpos($filename, '/')); references : http://us3.php.net/substr http://us3.php.net/manual/en/function.strrpos.php -Minuk John Taylor-Johnston wrote: SCRIPT_NAME and PHP_SELF always include lea

Re: [PHP] SCRIPT_NAME

2005-10-20 Thread Robert Cummings
On Thu, 2005-10-20 at 22:22, John Taylor-Johnston wrote: > SCRIPT_NAME and PHP_SELF always include leading url information and > slashes. Is there a function I can use to skin either down to the > filename? No slashes or leading url. echo ereg_replace( '^.*/', '', $_SERVER['SCRIPT_NAME'] ) ereg

Re: [PHP] SCRIPT_NAME

2005-10-20 Thread Jasper Bryant-Greene
On Thu, 2005-10-20 at 22:22 -0400, John Taylor-Johnston wrote: > SCRIPT_NAME and PHP_SELF always include leading url information and > slashes. Is there a function I can use to skin either down to the > filename? No slashes or leading url. http://php.net/basename for filesystem paths http://php

Re: [PHP] Re: No redirect with header() [solved]

2005-10-20 Thread Dotan Cohen
On 10/20/05, Oliver Grätz <[EMAIL PROTECTED]> wrote: > So perhaps it was good that I was pushing to see the code ;-) > So you looked more closely... > > Tip: I put an output buffer around my "not supposed to output anything" > code: > > ob_start(); > // include function libraries, perform non-visi

[PHP] SCRIPT_NAME

2005-10-20 Thread John Taylor-Johnston
SCRIPT_NAME and PHP_SELF always include leading url information and slashes. Is there a function I can use to skin either down to the filename? No slashes or leading url. John -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Executing process in background

2005-10-20 Thread Jasper Bryant-Greene
On Thu, 2005-10-20 at 15:07 -0700, Surya Mishra wrote: > I have to start a task on the server side that is going to take pretty long > to process in the server side. So I would like to show a message to the user > and ask him/her to check again later. But starting a new task holds up the > thread a

Re: [PHP] Trapping for an uploaded file that's too large?

2005-10-20 Thread Brian Dunning
On Oct 20, 2005, at 4:55 PM, Jordan Miller wrote: are you using PHP 5? No, 4 unfortunately. Shoulda said so. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Trapping for an uploaded file that's too large?

2005-10-20 Thread Jordan Miller
On Oct 20, 2005, at 6:29 PM, Brian Dunning wrote: In my File Upload form, if the file is >=2MB, the user just gets a blank "error opening file" screen, almost immediately after the upload starts. I don't know how to trap for this to give a more user-friendly experience. Can anyone point me

[PHP] Trapping for an uploaded file that's too large?

2005-10-20 Thread Brian Dunning
In my File Upload form, if the file is >=2MB, the user just gets a blank "error opening file" screen, almost immediately after the upload starts. I don't know how to trap for this to give a more user- friendly experience. Can anyone point me in the right direction? -- PHP General Mailing Lis

[PHP] Executing process in background

2005-10-20 Thread Surya Mishra
Hi, I have to start a task on the server side that is going to take pretty long to process in the server side. So I would like to show a message to the user and ask him/her to check again later. But starting a new task holds up the thread and won't let me exit the php. The user's browser does keep

Re: [PHP] LDAP and a pain in my neck

2005-10-20 Thread André Medeiros
Check your webserver logs. If PHP couldn't use the extension, it will accuse that in the logs. On 10/20/05, Jay Blanchard <[EMAIL PROTECTED]> wrote: > [snip] > > Call to undefined function: ldap_connect() > > > > What am I missing? TIA. > > > Did you uncomment (and properly define) the 'extension_

RE: [PHP] LDAP and a pain in my neck

2005-10-20 Thread Jay Blanchard
[snip] > Call to undefined function: ldap_connect() > > What am I missing? TIA. Did you uncomment (and properly define) the 'extension_dir' directive in your php.ini? [/snip] Yep. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] LDAP and a pain in my neck

2005-10-20 Thread Greg Donald
On 10/20/05, Jay Blanchard <[EMAIL PROTECTED]> wrote: > Farking windoblows environment! > > The extension is uncommented, I have OpenLDAP for W2k installed and running, > the dll's have been copied to the proper place and I execute a test and get > > Call to undefined function: ldap_connect() > > W

[PHP] LDAP and a pain in my neck

2005-10-20 Thread Jay Blanchard
Farking windoblows environment! The extension is uncommented, I have OpenLDAP for W2k installed and running, the dll's have been copied to the proper place and I execute a test and get Call to undefined function: ldap_connect() What am I missing? TIA. -- PHP General Mailing List (http://www.p

[PHP] install issue (affects 4.4.0 and 5.0.5) [/usr/include/rpc/rpc_msg.h, /usr/include/rpc/rpc.h, /usr/include/crypt.h, standard/crypt.c

2005-10-20 Thread Administrator
Running FreeBSD 5.4/RELEASE on Sparc64 and Apache 1.3.33 When attempting to install 4.4.0 and 5.0.5, from ports or from source, I am getting the following error: (This specific error is from 4.4.0 from ports [/usr/ports/lang/php4] /bin/sh /usr/ports/lang/php4/work/php-4.4.0/libtool --silent --pre

[PHP] php 5.0.5 segfaults apache2 on ubuntu, 5.0.4 ok

2005-10-20 Thread Petr Smith
Hi, I've just installed php 5.0.5 to newest ubuntu breezy and apache2 started (sometimes) segfaulting (teste two computers with ubuntu hoary and ubuntu breezy - same results). Is says something like this: [Thu Oct 20 12:32:21 2005] [notice] child pid 13161 exit signal Segmentation fault (11) [T

Re: [PHP] Re: No redirect with header() [solved]

2005-10-20 Thread Dotan Cohen
On 10/20/05, Oliver Grätz <[EMAIL PROTECTED]> wrote: > I mentioned that it could be possible that this in no PHP problem just > as you did but I wanted to see the code to ensure myself before saying > this out loud. > The redirection not working on your end would mean that you browser > doesn't com

[PHP] PHP4.4 and installing PEAR?

2005-10-20 Thread Kim Madsen
Hi I installed PHP 4.4 on a new server and missed the Pear packages after that. I looked in the docs, I searched the php maillist and googled without finding an answer. I solved it by installing 4.3.9 and after this upgrade to 4.4, but I´m just damn curious... How do I install the pear package

Re: [PHP] LDAPS agaisnt Active Directory

2005-10-20 Thread Aaron Axelsen
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I have been successful in getting apache to use the cert for .htaccess authentication. But i'm not seeing a clear way on how to make this happen with php. Can anyone offer any suggestions? - -- Aaron Axelsen [EMAIL PROTECTED] Great hosting, low p

[PHP] Problem returning private member array variables

2005-10-20 Thread Fernando Alvarez
Hi to all, I was wondering if someone out there has had the same problem as I have; fetching from an object a private array variable through a get method. And instead of getting a copy of the array, you get access to the original array, being able to access the object's internal data! I have trie

[PHP] Problem returning private member array variables

2005-10-20 Thread Fernando Alvarez
Hi to all, I was wondering if someone out there has had the same problem as I have; fetching from an object a private array variable through a get method. And instead of getting a copy of the array, you get access to the original array, being able to access the object's internal data! I have trie

[PHP] Re: No redirect with header()

2005-10-20 Thread ac
On 10/20/05, Dotan Cohen <[EMAIL PROTECTED]> wrote: > On 10/18/05, Oliver Grätz <[EMAIL PROTECTED]> wrote: > > Snippets are bad ;-) > > > > Please post a full example that is _not_ working on your server. > > Perhaps this is no PHP problem at all. > > > > I know, but I don't want to post my trackin

RE: [PHP] re: some problems with php form

2005-10-20 Thread Ford, Mike
On 19 October 2005 19:24, Jay Blanchard wrote: > [snip] > "normal"}?>" id="firstname" name="firstname" type="text" value=" echo $_POST['firstname'] ?>"> > > how would I fix this error? > [/snip] > > You are missing several semi-colons; > > "normal";}?>" id="firstname" name="firstname" type

Re: [PHP] Putting Form Variables / URL Parameters in to an associative array?

2005-10-20 Thread Jasper Bryant-Greene
On Thu, 2005-10-20 at 10:01 +0200, Jacques wrote: > How can I grab parameters / key-value-pairs from a query string and put them > in to an associative array where each key-value pair inside the array > exactly corresponds with the key-value pairs inside the querystring? http://php.net/parse_str

[PHP] Putting Form Variables / URL Parameters in to an associative array?

2005-10-20 Thread Jacques
How can I grab parameters / key-value-pairs from a query string and put them in to an associative array where each key-value pair inside the array exactly corresponds with the key-value pairs inside the querystring? Regards Jacques -- PHP General Mailing List (http://www.php.net/) To unsubsc