[PHP-WIN] Re: 'extends' problem (Classes)

2003-10-06 Thread Sek-Mun Wong
did you have your inheritance mixed up? (or maybe it was a typo) if > class Another extends Something { then > $obj2 = new Something; > $obj2->setX(5); > $obj2->setY(6); would yield setY not found, because setY is not in Something. Ie, both methods are available in "Another", only setX is in

[PHP-WIN] Re: Accessing Outlook via COM object

2003-09-23 Thread Sek-Mun Wong
hi Ron, I'll swing at this :)... I've never done this in PHP, but have done a bit of work in Win32 Perl to M$-Exchange. The obvious thing to me is: echo $session->Logon("'','',False,True,,True," . $strExchangeServer .$vbLF . $strMailbox); should read: $session->Logon("'',"",False,True,-1,True

[PHP-WIN] Re: a Directory Crawler

2003-09-22 Thread Sek-Mun Wong
hin a class... sorry about that only spotted it after I posted. "Sek-Mun Wong" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Ron, > > I've got a function that does it for directories, and I've just quickly > modified it for you to do what yo

[PHP-WIN] Re: a Directory Crawler

2003-09-22 Thread Sek-Mun Wong
Ron, I've got a function that does it for directories, and I've just quickly modified it for you to do what you've stated, you can modify it if there is a problem. try this: $files = recurseDirectory("/home/mydir", null, null); foreach ($files as $i => $filename) { print "proce

[PHP-WIN] Re: MySQL question

2003-09-22 Thread Sek-Mun Wong
of course this is a php newsgroup :) try DAYOFMONTH DAY is only available in mysql 4.1.1 "Disko_kex" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi SELECT RegDate FROM table WHERE month(RegDate) = '10' // this is working SELECT RegDate FROM table WHERE day(RegDate) = '2' // w

[PHP-WIN] Re: generate img with fonts...

2003-09-19 Thread Sek-Mun Wong
Yes yes, you guys are hilarious but at least try to answer his question! :) Bobo, I assume you're using Win32 and true type fonts, try this chunk of code: You *will* need to install freetype (www.freetype.org) and enable gd/gd2 (depending on your version of php) extensions on your php install.

[PHP-WIN] shmop & windows

2003-09-18 Thread Sek-Mun Wong
anyone played with shmop on windows? in particular, i'm looking to create a persistent store where I can serialize large chunks of data (well, "large" meaning 64-128Mb) and stick it into memory. Maybe there's even an in-memory caching class out there. I've currently got a class for caching serial

[PHP-WIN] Re: calling a php script

2003-09-15 Thread Sek-Mun Wong
try $fp = fopen (http://www.example.com/otherscript.php?a=1&b=2, "r"); $contents = fread ($fd, filesize ($filename)); fclose ($fd); then preg_match $contents for any output. "Gerardo Rojas" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] I'm trying to call a php script from another

[PHP-WIN] Re: Need to call VB from PHP script. Is this hard to do?

2003-09-08 Thread Sek-Mun Wong
you can use the ill-named "fopen". eg, $fp = fopen (http://www.example.com/vbscript.asp?a=1&b=2, "r"); you then have to parse the output of the asp to determine the result of the script execution. ie, $contents = fread ($fd, filesize ($filename)); fclose ($fd); then preg_match $contents for s

[PHP-WIN] Re: need help

2003-09-02 Thread Sek-Mun Wong
1) client pull. use the browser meta-refresh, may not work on some browsers (like PDA's, etc, nearly all desktop browsers should be ok with this method) just tricky with passing back QUERY_STRING, if you had stuff from previous form. http://www.yoursite.com/firstpage.php?action=wrongdata";> wrong

[PHP-WIN] Re: problems with mysql connections not closing - update

2003-09-01 Thread Sek-Mun Wong
Ok, here's what I found so far. 1) wait_timeout doesn't work under windows http://www.mysql.com/doc/en/News-4.0.15.html, 4.0.15 (dev) mysql is supposed to fix this. In http://bugs.php.net/bug.php?id=13589 [EMAIL PROTECTED] advises connecting like this: mysql_pconnect($host, $user, $pass, MYSQL_CL

[PHP-WIN] Re: problems with mysql connections not closing

2003-09-01 Thread Sek-Mun Wong
Chris, not sure if this is related to my question aka mysql_pconnect are u using mysql_pconnect or plain mysql_connect to connect to the database? This is the behaviour I'm getting, but with apache1.3.27/php4.3.2/mysql4.013 going to do some research on this in the next few days and will post some

[PHP-WIN] mysql_pconnect/win32/apache 1.3.27 (php4apache.dll NOT CGI)

2003-09-01 Thread Sek-Mun Wong
x27;t there only 1 thread?)... hmmm. There is barely any documentation on this, like: "it just doesn't work under win32". Even that would be fine. Ideas? PHP dudes? Any better success on php4isapi anyone? ------ Sek-Mun Wong Connecting Space

[PHP-WIN] Re: Array question

2003-08-25 Thread Sek-Mun Wong
hi again jocke... seems i'll give a go at answering your questions again ;-) If I understand your question properly, I doubt the previous poster's response would be useful to you. The bad news (I think): there are limited functions that deal with array pointers. There are plenty to deal with arra

[PHP-WIN] Re: Store array in mysql?

2003-08-21 Thread Sek-Mun Wong
use "serialize". you need to create a table with 2 fields, key & value, where value is a largetext field. $str = serialize($array); mysql_query("insert into table1 (key, value) as ($key, $str)"); then you can select it back out of mysql and use $result = mysql_query("select"); $array = unse

[PHP-WIN] Re: PHP 4.3.2, Windows 2000 IIS 5, MySQL 4.013 CPU usage problem

2003-08-14 Thread Sek-Mun Wong
are you running php4isapi.dll (ISAPI) or php.exe (CGI) version? I know people recommend CGI, but post 4.2.3, the ISAPI version is very stable and you'd be nuts to run a busy site in CGI mode. If you're running CGI, here is an explanation: The most expensive operation is the *connection*, why mysq

[PHP-WIN] Re: PHP 4.3.2, Windows 2000 IIS 5, MySQL 4.013 CPU usage problem

2003-08-12 Thread Sek-Mun Wong
t()' option on my php pages, and indeed the > 'mysql.allow.persistent' is set to 'on'. I just don't get it, > especially as the ASP version runs efficiently! Confused and > frustrated! > > It's probably going to simply need another parameter or

[PHP-WIN] Re: PHP 4.3.2, Windows 2000 IIS 5, MySQL 4.013 CPU usage problem

2003-08-09 Thread Sek-Mun Wong
t select > messageboard database - " . mysql_error()); > $newslink = @mssql_pconnect("xxx","xxx","xxx") or die("Could not connect - > "); > $newsdb = @mssql_select_db("xxx",$newslink) or die("Could not select > article database

[PHP-WIN] Re: PHP 4.3.2, Windows 2000 IIS 5, MySQL 4.013 CPU usage problem

2003-08-06 Thread Sek-Mun Wong
don't know if it should go any higher? All session > data is stored in one directory under c:\php\sessiondata\. > > The web log / event viewer isn't showing anything that I believe to be > of significance. > > Many many thanks for your advice, it is greatly appreciated. &

[PHP-WIN] Re: how can I get errors to display in a browser?

2003-08-03 Thread Sek-Mun Wong
you want display_errors = On Also, E_ALL is probably a little too verbose, you'll find. :-) "Jswalter" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have a test script, with deliberate errors. > > The broswer shows nothing, blank, empty. > > It used to show errors, now it does

[PHP-WIN] Re: Failure remote includes

2003-08-01 Thread Sek-Mun Wong
news:[EMAIL PROTECTED] As a follow up on my earlier reply, I found out how to read the socket and GET / HTTP, and that works on the remote files. However, a simple include doesn't. _Original message___ Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure

[PHP-WIN] Re: Apache or IIS

2003-08-01 Thread Sek-Mun Wong
true... I've always thought that if someone can code php or java, configuring a conf file should be (and is) a piece of cake. It suprises me to find many developers have a morbid fear (or maybe it's just laziness) of configuring servers by editing a conf file. I guess the division of labour and hyp

[PHP-WIN] Re: Failure remote includes

2003-08-01 Thread Sek-Mun Wong
n't want to give up too easily on this one, in case it's just a simple configuration flaw on my part (am newbie). Thanks very much! _Original message___ Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure remote includes <..silly one but i as

[PHP-WIN] Re: Failure remote includes

2003-07-31 Thread Sek-Mun Wong
silly one but i assume you already have "allow_url_fopen=On" in php.ini? (it should tell you anyway, that this is not set, plus the error below) works for me in 4.3.2/winxp pro/apache 1.3.28. I guess if you don't *need* apache 2, don't do it. another test might be to fopen and read a socket via

[PHP-WIN] Re: Q on PHP 4.3.2 & Apache 2.0.43

2003-07-31 Thread Sek-Mun Wong
Well, it works for me under 1.3.28, so let me walk through your apache config. I'm sure there are issues with the script to say the least, but just one more try with apache2: Your httpd.conf: 1) remove these lines LoadFile "/etc/php/php4ts.dll" Action application/x-httpd-php "/etc/php/php

[PHP-WIN] Re: Q on PHP 4.3.2 & Apache 2.0.43

2003-07-31 Thread Sek-Mun Wong
> I can only assume you are refering to... > > LoadModule php4_module "/etc/php/sapi/php4apache2.dll" > oops just spotted this... maybe this is the issue? the function might not like what apache2/win32 returns. fwiw I've gone back to 1.3.28 on win32. Don't really need apache2... yet. -- PHP

[PHP-WIN] Re: Q on PHP 4.3.2 & Apache 2.0.43

2003-07-31 Thread Sek-Mun Wong
27;; } } } } "Jswalter" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "Sek-Mun Wong" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > > red herring! > > well, wild goose maybe. > >

[PHP-WIN] Re: Q on PHP 4.3.2 & Apache 2.0.43

2003-07-31 Thread Sek-Mun Wong
red herring! those are Apache directives you've listed, not php.ini settings. I assume you mean php.conf which is included by httpd.conf? I assume you know how to install php as a SAPI module (you've got all the directives below plus the help url) However, that's just a SAPI red herring, this is

[PHP-WIN] Re: Apache or IIS

2003-07-31 Thread Sek-Mun Wong
We use both in production. I'm biased, but we prefer Apache, even though I've had more issues with it. (On win32) Prior to Apache 1.3.27, had a few issues with the apache service dying every few days and not restarting (win2k event viewer didn't even know it stopped) on a Compaq DL370 (ah there's

Re: [PHP-WIN] Windows 2K (workstation)

2003-07-30 Thread Sek-Mun Wong
You might just be using it for development. But you're right, I use Apache for dev too, however I do simultaneously run the crippled IIS on port 8080 for cross platform work on our framework... just to ensure it works under both web servers. Now Frontpage extensions for linux... THAT'S getting ca

[PHP-WIN] Re: my script on php 4.3.2 kills apache 2.x

2003-07-30 Thread Sek-Mun Wong
Just on local laptop development 2.0.47 locks up quite often on mysql calls (about every 30 calls) Couldn't be bothered to debug it, so I've gone back to 1.3.28 for win32, it's production stable (at least on w2k). I'm running WinXP on laptop, btw. "Jswalter" <[EMAIL PROTECTED]> wrote in message ne

[PHP-WIN] Re: Session not working

2003-07-30 Thread Sek-Mun Wong
1) Verify that you've specified (and created) your sessiondata (usually {drive:}/php/sessiondata directory, 2) check to see if a session id has been written there. 3) if not, make sure that the apache logon (usually localsystem) has access to write to sessiondata (which it should have by default).

[PHP-WIN] Re: Please Help!!!

2003-07-29 Thread Sek-Mun Wong
Umm, you have an "@" before the mysql_connect and mysql_select_db statements? remove these. "Wx" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Please help me out Wx The following sql statements work when called from command line i.e in the php path but when called from the

[PHP-WIN] Set Apache's $REMOTE_USER externally

2002-04-20 Thread Sek-Mun Wong
referred approach ;-) Regds, Sek-Mun <<< Sek-Mun Wong Connecting Space Sydney, Australia mailto:[EMAIL PROTECTED] http://www.connectingspace.com mobile +61 402 138 974 phone +61 2 9516 2888 fax +61 2 8080 8305 -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php