[PHP] Re: [PHP-DB] Re: XML to MySQL

2003-07-03 Thread justin gruenberg
I think starting with the XML parsing functions might be a logical step.

For what you're doing, expat  is going to be a 
more logical solution for parsing the xml.  There is also DOMXML, which 
makes more sense to a lot of people, but will be slower at parsing your 
file.

Nabil wrote:

any one ??

"Nabil" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
 

Dear All ;

I have an XML files like the following and i want to make an PHP code to
insert it into my MySQL
how can i read the nodes ot tages???  by the way i can export like this
   

file
 

from PhpMyAdmin but i cann't dump it back...
Thanks in advance
Nabil

- 
- 
- 
 1
 Mark
 Smith
 company1
 123456
 city1
 first street
 12

   



 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: [PHP-DB] How to get PHP to download web contents

2003-07-03 Thread justin gruenberg
Steve B. wrote:

How would you get PHP to download a file such as a web page and put it in a string?

What keywords would relate to this (besides php download)

I need a user to be able to put in a name and pass and have PHP go to a cetain site.
The site can take the user/pass in the url so I do not need a form submit.
Then I need the site contents to be in a php variable.
Any tips on parsing html out of it would be great.
Thanks

$fp = fopen("/http://site.com/path/to/file/";, "r");
while (!feof($fp)) {
   $buf .= fread($fp, 1024);
}
fclose($fp);
I like this method more than using file(), just because I have more 
control over what happens.  Since you're reading as its downloading, you 
can do stuff with the data before you're finished. 

As for parsing HTML... regular expressions are very cool.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] symlinks

2003-07-03 Thread Brian Rue
Hi,

I need to link a url like this:

www.mysite.com/?id=5

to a folder like this:

www.mysite.com/5

(so that I can access it from the subdomain 5.mysite.com)

I'm assuming that symlinks are the best way to do this, but I really don't
know how to do it.

Any help is greatly appreciated.

Thanks



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] outputting xml declaration

2003-07-03 Thread Marek Kilimajer
This should not give you any error. Not even if short_open_tags are on 
as printed output is not parsed. What is the error message and what 
version of php are you running? It works for me (php 4.3.2).

Steven Apostolou wrote:
Hello,

The folowing code gives an error:

print "";

This is probably because I print a questionmark? How can I avoid that an
error is generated?
Besides it's not an error in the way that it gives an errorstring but it
writes the output in the error_log of apache...
Greetings,



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] mail + regex + somethoughts

2003-07-03 Thread - Edwin -
Hi,

"Shivanischal A" <[EMAIL PROTECTED]> wrote:

> Hi friends,
> 
> I was just wondering about this. Whenver we reply to the posts here, we just
> click on the reply button and fire off our messages. This results in long
> messages (fresh content + earlier content) within a single mail. Now, the
> question is how would we use the regex functions to remove the older content
> from a fresh mail. I think you all beginning to get the picture.
> 
> What would we do if we want just the responses/comments to an earlier and
> not the earlier mail verbatim in the fresh one?

Copy -> Paste and/or Highlight -> Delete ?

- E -

...[snip]...
__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] mysql detect

2003-07-03 Thread - Edwin -

[EMAIL PROTECTED] wrote:

> helo all ,
> 
> what command in linux , to see default direcktory instalation mysql
> database dan mysql library

RPMs?

  $ rpm -ql 


- E -
__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: mail + regex + somethoughts

2003-07-03 Thread Shivanischal A
Hi Edwin,

Let me restate my question...

I'm now replying to ur mail. I've left ur message to me untouched. (whatever
follows '- Original Message - '). What i want is that some
SERVER-SIDE SCRIPT should be able to identify these original messages and
remove them before storing the actual responses.

I'm sorry for the confusion arising coz of incorrect statement.
Thanks and Regards,
-shiva


- Original Message -
From: "- Edwin -" <[EMAIL PROTECTED]>
To: "Shivanischal A" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, July 03, 2003 1:55 PM
Subject: Re: [PHP] mail + regex + somethoughts


> Hi,
>
> "Shivanischal A" <[EMAIL PROTECTED]> wrote:
>
> > Hi friends,
> >
> > I was just wondering about this. Whenver we reply to the posts here, we
just
> > click on the reply button and fire off our messages. This results in
long
> > messages (fresh content + earlier content) within a single mail. Now,
the
> > question is how would we use the regex functions to remove the older
content
> > from a fresh mail. I think you all beginning to get the picture.
> >
> > What would we do if we want just the responses/comments to an earlier
and
> > not the earlier mail verbatim in the fresh one?
>
> Copy -> Paste and/or Highlight -> Delete ?
>
> - E -
>
> ...[snip]...
> __
> Do You Yahoo!?
> Yahoo! BB is Broadband by Yahoo!
> http://bb.yahoo.co.jp/
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Using INCLUDES in SAFE MODE

2003-07-03 Thread Marek Kilimajer
Configuration directive:
safe_mode_include_dir  string
UID/GID checks are bypassed when including files from this 
directory and its subdirectories (directory must also be in include_path 
or full path must including).

As of PHP 4.2.0, this directive can take a semi-colon separated 
path in a similar fashion to the include_path directive, rather than 
just a single directory.

MIKE YRABEDRA wrote:

I currently have all my users in safe-mode to prevent them from running
shell commands via php.
I would still like for them to be able to access certain folders (i.e. PEAR,
basic_functions, etc..) that reside out of their root.
Since safe_mode prevents this, is there a way in the domain's config, to
allow access to *specific* directories when in safe_mode?
TIA



++
Mike Yrabedra (President)
323 Incorporated 
Home of MacDock, MacAgent and MacSurfshop
++
W: http://www.323inc.com/
P: 770.382.1195
F: 734.448.5164
E: [EMAIL PROTECTED]
I: ichatmacdock
++
"Whatever you do, work at it with all your heart,
as working for the Lord, not for men."
~Colossians 3:23 <{{{><
++





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Optional form variables (IDEA?)

2003-07-03 Thread - Edwin -
Hello,

"Miranda, Joel Louie M" <[EMAIL PROTECTED]> wrote:

> Hello, im doing a form that when you pass it will generate a preview report.
> My problem is some fields are optional the optional fields are 5. And for
> those fields I need to make it fit when it generate what idea or codes can
> you suggest?
> 
> Ex, a businesscard preview form. When it generates it will show you a
> businesscard template. But how about those un-filled fields. 
> 
> Can this be done thru if and else statement?
> 

Yes. Try it first. Let us know if (and how) it doesn't work.

- E -
__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Marek Kilimajer
Make it be:

if ()
{
	include();
}
else
{
if ()
{
	include();
}
else if ()
{
	include();
}
}
reads much better.



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Browscap

2003-07-03 Thread - Edwin -

"Milan Reznicek" <[EMAIL PROTECTED]> wrote:

> Hi everybody,
> I'm trying to get_browser() function, but everytime I get from my apache
> could not open browscap.ini for reading. Does someone know how to correct
> it, or is there any other way how to determine users browser type and OS
> without using browscap?

  $_SERVER['HTTP_USER_AGENT'] ?

- E -

__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] OT a lttle bit of Javascript needed

2003-07-03 Thread George Pitcher
Hi,

I'm developing a mini-website for a customer and want to build a link  so
that there is the option to see what I have in a database on my site.

It will feature in a form and when they fill in the ISBN field, their input
is added to a URL link on that page. The user can click on the link and see
what I have for that ISBN.

I've searched Google with only confusion as a result.

Can anyone here help me?

Cheers

George in Oxford


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Session vs Cookie Issues

2003-07-03 Thread Mika Tuupola
On Wed, 2 Jul 2003, Matt MacLeod wrote:

> I've had similar issues using cookies. The cookie was storing my details 
> but only for the duration of the session despite having set the expiry 
> date to a time well into the future. Any ideas for why this may have 
> happened?

Someone rm'ing /tmp/ for example.

-- 
Mika Tuupola  http://www.appelsiini.net/~tuupola/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Ford, Mike [LSS]
> -Original Message-
> From: Jim Lucas [mailto:[EMAIL PROTECTED]
> Sent: 02 July 2003 22:47
> 
> Technically you are not outside of a function.
> 
> you need to use one of the include or require functions to 
> include the file
> right?

include and require are not functions -- they are language constructs.

(Proof:  include 'file.inc';   works.)

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mail + regex + somethoughts

2003-07-03 Thread - Edwin -
Hello,

"Shivanischal A" <[EMAIL PROTECTED]> wrote:

> Hi Edwin,
> 
> Let me restate my question...
> 
> I'm now replying to ur mail. I've left ur message to me untouched. (whatever
> follows '- Original Message - '). What i want is that some
> SERVER-SIDE SCRIPT should be able to identify these original messages and
> remove them before storing the actual responses.

Hmm... I'm not really sure if I understand this but...
First, NOT all "mail clients" will add this:

  - Original Message -

to the original message. Besides, there are many ways how each 
individual would quote the original message. So, writing a script
that would identify THE original messages would be, IMHO, next to
impossible...

What is the purpose anyway?

- E -

...[snip]...
__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Browscap

2003-07-03 Thread Mika Tuupola
On Wed, 2 Jul 2003, Milan Reznicek wrote:

> I'm trying to get_browser() function, but everytime I get from my apache
> could not open browscap.ini for reading. Does someone know how to correct
> it, or is there any other way how to determine users browser type and OS
> without using browscap?

http://www.php.net/manual/en/function.get-browser.php

-- 
Mika Tuupola  http://www.appelsiini.net/~tuupola/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Calculating Largest Member of Array

2003-07-03 Thread Ford, Mike [LSS]
> -Original Message-
> From: John Wulff [mailto:[EMAIL PROTECTED]
> Sent: 02 July 2003 21:26
> 
> Sorry for the multiple post!! Apparently when pasting I hit 
> some magic send
> key.I'd like to calculate the largest member of this array 
> without taking
> into
> account the first value which is obvisouly not numeric.
> 
> So far this is how I'm doing it, but sometimes I get returned 
> a month for
> the max.
> 
> $high = end(array_reduce($cdata,
>   create_function('$a, $b',
>   'return array(max(array_reduce($a, "max"),
>   array_reduce($b, "max")));')));
> 
> Array
> (
> [0] => Array
> (
> [0] => Jan-99
> [1] => 6399.36
> [2] => 6132.71
> [3] => 2242.20
> [4] => 53.27
> [5] => 87.34
> )
> 
> [1] => Array
> (
> [0] => Feb-99
> [1] => 5754.72
> [2] => 3964.93
> [3] => 6145.98
> [4] => 693.32
> [5] => 23.80
> )
> )

Would this do?

$high = NULL;
foreach ($cdata as $month):
$a_high = max(array_slice($month, 1));
$high = is_null($high) ? $a_high : max($high, $a_high);
endforeach;

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] stupidity check: (to disable transparent session id)

2003-07-03 Thread Ford, Mike [LSS]
> -Original Message-
> From: Jason k Larson [mailto:[EMAIL PROTECTED]
> Sent: 03 July 2003 01:21
> 
> I'm almost perfectly certain this *should* work ... can 
> anybody shed some light on why it 
> doesn't?
> 
> $retval1 = ini_set ('session.use_trans_sid',false);
> or
> $retval1 = ini_set ('session.use_trans_sid','0');
> or
> $retval1 = ini_set ('session.use_trans_sid','Off');
> 
> $retval1 will be: bool(false)

The manual page for ini_set at http://www.php.net/ini_set says that 
session.use_trans_sid has changeable attributes of PHP_INI_SYSTEM|PHP_INI_PERDIR -- 
this means it can be changed in php.ini, .htaccess or httpd.conf, but *not* in your 
scripts.

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Using PHP to read style sheet -- create drop-down?

2003-07-03 Thread Sævar Öfjörð
Sorry, my bad. Replace $hm with $file[$i]. $hm was for my testing
purposes and I forgot to change it :)


-Original Message-
From: J J [mailto:[EMAIL PROTECTED] 
Sent: 3. júlí 2003 02:34
To: [EMAIL PROTECTED]
Subject: RE: [PHP] Using PHP to read style sheet -- create drop-down?

It's reading the file but returning a blank drop-down
with your example.  Where I'm confused is where is $hm
defined?


--- Sævar Öfjörð <[EMAIL PROTECTED]> wrote:
> Sure. You should use file functions like 
> 
> http://is.php.net/manual/en/function.fopen.php
> http://is.php.net/manual/en/function.fread.php
> or
> http://is.php.net/manual/en/function.file.php
> 
> to read the file and then maybe
> 
> http://is.php.net/manual/en/function.preg-match.php
> 
> to extract certain elements from the text.
> 
> Here is what i came up with:
> 
> $file=file("whatever.css");
> $total=count($file);
> print "\n";
> for($i=0;$i<$total;$i++){
>   preg_match("/^[.]?([a-zA-Z])+/",$hm,$matches);
>   print " ".$matches[0]."\n";
> }
> print "";
> 
> This should output:
> 
>  .heading
>  .headingBold
> 
> 
> 
> 
> -Original Message-
> From: J J [mailto:[EMAIL PROTECTED] 
> Sent: 2. júlí 2003 21:58
> To: [EMAIL PROTECTED]
> Subject: [PHP] Using PHP to read style sheet --
> create drop-down?
> 
> Is it possible for PHP or maybe javascript+php to
> read
> in a style sheet (whatever.css) and create a
> drop-down
> of all the elements within that style sheet?
> 
> CSS contains:
> .heading {blah blah size blah}
> .headingBold {blah blah size blah bold}
> 
> 
> Then in PHP I'd like to have a drop down that shows
> those elements found in the style:
> 
> 
>  heading
>  headingBold
> 
> 
> Is that possible to read in another file to create a
> drop-down?
> 
> Thanks in advance!
> 
> __
> Do you Yahoo!?
> SBC Yahoo! DSL - Now only $29.95 per month!
> http://sbc.yahoo.com
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 


__
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] string modification

2003-07-03 Thread sven
hi,

i didn't find a function for this in the manual, but maybe there is one (or
a workaround):

does anyone have a solution for replacing multiple whitespaces with a single
whitespace whitin a string? similar to trim(). maybe a regular expression?

eg:
$string = 'word1   word2 word3';
$modified = 'word1 word2 word3';



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mail + regex + somethoughts

2003-07-03 Thread Jason Wong
On Thursday 03 July 2003 16:37, Shivanischal A wrote:
> Hi Edwin,
>
> Let me restate my question...
>
> I'm now replying to ur mail. I've left ur message to me untouched.
> (whatever follows '- Original Message - '). What i want is that
> some SERVER-SIDE SCRIPT should be able to identify these original messages
> and remove them before storing the actual responses.
>
> I'm sorry for the confusion arising coz of incorrect statement.

Either you're seriously confused or you're doing your best to confuse us. 

First, what has this got to do with PHP? 

Looking at your headers it seems you're using MS Outlook (no comments), how 
are you going to interface that with PHP? Or how are you going to integrate 
any typical MUA with PHP for that matter?

And what's wrong with doing to what the rest of us do -- that is, remove the 
unnecessary parts of the previous post and adding your comments underneath 
the parts of the previous post that you are commenting on?

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Breaking Windows isn't just for kids anymore...
*/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] string modification

2003-07-03 Thread Leif K-Brooks

hi,

i didn't find a function for this in the manual, but maybe there is one (or
a workaround):
does anyone have a solution for replacing multiple whitespaces with a single
whitespace whitin a string? similar to trim(). maybe a regular expression?
eg:
$string = 'word1   word2 word3';
$modified = preg_replace('|(\\s)+|','$1',$string);

$modified = 'word1 word2 word3';
 



--
The above message is encrypted with double rot13 encoding.  Any unauthorized attempt 
to decrypt it will be prosecuted to the full extent of the law.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] string modification

2003-07-03 Thread sven
thanks, this works.
ciao SVEN

Leif K-Brooks wrote:
>> hi,
>>
>> i didn't find a function for this in the manual, but maybe there is
>> one (or a workaround):
>>
>> does anyone have a solution for replacing multiple whitespaces with
>> a single whitespace whitin a string? similar to trim(). maybe a
>> regular expression?
>>
>> eg:
>> $string = 'word1   word2 word3';
>>
> $modified = preg_replace('|(\\s)+|','$1',$string);
>
>> $modified = 'word1 word2 word3';



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mail + regex + somethoughts

2003-07-03 Thread sven
maybe you dig a little bit deeper:

take a look at rfc2045 and following. they describe the mime-type. there is
also specified, how boundaries in multipart-messages are defined.

ciao SVEN

- Edwin - wrote:
> Hello,
>
> "Shivanischal A" <[EMAIL PROTECTED]> wrote:
>
>> Hi Edwin,
>>
>> Let me restate my question...
>>
>> I'm now replying to ur mail. I've left ur message to me untouched.
>> (whatever follows '- Original Message - '). What i want is
>> that some SERVER-SIDE SCRIPT should be able to identify these
>> original messages and remove them before storing the actual
>> responses.
>
> Hmm... I'm not really sure if I understand this but...
> First, NOT all "mail clients" will add this:
>
>   - Original Message -
>
> to the original message. Besides, there are many ways how each
> individual would quote the original message. So, writing a script
> that would identify THE original messages would be, IMHO, next to
> impossible...
>
> What is the purpose anyway?
>
> - E -
>
> ...[snip]...
> __
> Do You Yahoo!?
> Yahoo! BB is Broadband by Yahoo!
> http://bb.yahoo.co.jp/



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mail + regex + somethoughts

2003-07-03 Thread Shivanischal A

Hi Jason,

I believe very much in the spirit of mailing lists and will never commit any
undesirable activity.

I got the idea is when i browsed thru the Usenet Discussion Forums using
Google's web-interface to the Usenet. If u go their site, u can see this.
The UI look very cluttered with the previous posts appearing along with
newer posts (as part of same message). I thought it would have been good if
someone/something took care to remove the earlier posts even if the person
posting it forgets to do so.

If this is still confusing you, its probably my English. But i'm convinced
this is difficult.

Anyway, thanks for ur timeRegards,
-shiva



- Original Message -
From: "Jason Wong" <[EMAIL PROTECTED]>
Newsgroups: php.general
To: <[EMAIL PROTECTED]>
Sent: Thursday, July 03, 2003 3:38 PM
Subject: Re: [PHP] Re: mail + regex + somethoughts


> On Thursday 03 July 2003 16:37, Shivanischal A wrote:
> > Hi Edwin,
> >
> > Let me restate my question...
> >
> > I'm now replying to ur mail. I've left ur message to me untouched.
> > (whatever follows '- Original Message - '). What i want is that
> > some SERVER-SIDE SCRIPT should be able to identify these original
messages
> > and remove them before storing the actual responses.
> >
> > I'm sorry for the confusion arising coz of incorrect statement.
>
> Either you're seriously confused or you're doing your best to confuse us.
>
> First, what has this got to do with PHP?
>
> Looking at your headers it seems you're using MS Outlook (no comments),
how
> are you going to interface that with PHP? Or how are you going to
integrate
> any typical MUA with PHP for that matter?
>
> And what's wrong with doing to what the rest of us do -- that is, remove
the
> unnecessary parts of the previous post and adding your comments underneath
> the parts of the previous post that you are commenting on?
>
> --
> Jason Wong -> Gremlins Associates -> www.gremlins.biz
> Open Source Software Systems Integrators
> * Web Design & Hosting * Internet & Intranet Applications Development *
> --
> Search the list archives before you post
> http://marc.theaimsgroup.com/?l=php-general
> --
> /*
> Breaking Windows isn't just for kids anymore...
> */
>
- Original Message -
From: "Jason Wong" <[EMAIL PROTECTED]>
Newsgroups: php.general
To: <[EMAIL PROTECTED]>
Sent: Thursday, July 03, 2003 3:38 PM
Subject: Re: [PHP] Re: mail + regex + somethoughts


> On Thursday 03 July 2003 16:37, Shivanischal A wrote:
> > Hi Edwin,
> >
> > Let me restate my question...
> >
> > I'm now replying to ur mail. I've left ur message to me untouched.
> > (whatever follows '- Original Message - '). What i want is that
> > some SERVER-SIDE SCRIPT should be able to identify these original
messages
> > and remove them before storing the actual responses.
> >
> > I'm sorry for the confusion arising coz of incorrect statement.
>
> Either you're seriously confused or you're doing your best to confuse us.
>
> First, what has this got to do with PHP?
>
> Looking at your headers it seems you're using MS Outlook (no comments),
how
> are you going to interface that with PHP? Or how are you going to
integrate
> any typical MUA with PHP for that matter?
>
> And what's wrong with doing to what the rest of us do -- that is, remove
the
> unnecessary parts of the previous post and adding your comments underneath
> the parts of the previous post that you are commenting on?
>
> --
> Jason Wong -> Gremlins Associates -> www.gremlins.biz
> Open Source Software Systems Integrators
> * Web Design & Hosting * Internet & Intranet Applications Development *
> --
> Search the list archives before you post
> http://marc.theaimsgroup.com/?l=php-general
> --
> /*
> Breaking Windows isn't just for kids anymore...
> */
>


DISCLAIMER: This email is bound by the terms and conditions described at 
http://www.subexgroup.com/mail-disclaimer.htm



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP + Linux: Configuration?

2003-07-03 Thread Luiz Morte
Hello list,

I have a problem using php in linux. I´m using the code bellow:

html code:

 
 


php code
",count($linhas));
?>

If I repeat the line bellow 100 times and put this in a textarea, the php code returns 
that there are 154 lines.
teste.com.br::Teste 
variaveis::teste::teste::dfasfafasdfafasdfasfas::11::11::ativo::teste.do.teste

I´ve made this test using the versions:
php-4.2.2-17
php-4.3.2-3

Using FreeBSD, I don´t have the error with the same code. (php-4.3.1)

Any ideia?
Thanks in advance,
Luiz.

Re: [PHP] Forms & PHP

2003-07-03 Thread Greg Wiley
On Wed, 02 Jul 2003 14:58:39 +0100, Greg Wiley <[EMAIL PROTECTED]> 
wrote:

On Wed, 2 Jul 2003 14:45:27 +0100, Gary Ogilvie 
<[EMAIL PROTECTED]> wrote:

[snip]
By maintaining the POST (assuming you're using POST)variables and
calling them into the form values when reloaded. If you go to the second
page store the POST variables in hidden form input types, then grab them
when the second page is POSTED. Does this make sense? Not enough
caffeine for me yet...[/snip]
So basically I need to have 2 versions of the first page, is that right?
:)

No, in your first form you have code like

Well almost. I realised whilst trying to get to sleep last night that 
there's a problem with this. In the first form you need:

;
	$action = "form2.php";
} else {
$foo = $_POST['foo'];
	$action = "results.php";
}
?>


...

This way you won't get a circular dependency. However, it means that you'll 
need to provide some other way of amending the details on form2 if it's a 
requirement.

and in the second form you have:



...

Cheers, Greg.
--
Greg Wiley
www.wileysworld.org
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Get Rid of this Crook

2003-07-03 Thread Daryl Meese
Could someone that this ass of the mailing list

Daryl



-Original Message-
From: MARIAM ABACHA [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 03, 2003 12:02 AM
To: [EMAIL PROTECTED]
Subject: [PHP] ASSISTANCE NEEDED


Hello,
I am sorry for the embarrassment this letter might cause you as we have not
had any correspondence before this letter. I got your address through my
nephew   with Nigerian Military Chamber of Commerce industry and Mining
during my research for a reliable and trustworthy partner who l can do
business with though l did not disclose the nature of the business l intend
to do with whoever he recommend for me.
I am DR. MRS MARIAM ABACHA, wife of the late Nigeria Head of State, General
Sanni Abacha who died on the 8th of June 1998 while still on active duty. I
am contacting you in view of the fact that we will be of great assistance to
each other likeness developing a cordial relationship.
I currently have within my reach the sum of Twenty - Five Million US Dollars
(US$25,000,000.00) cash which l intends to use for investment, like Real
Estate Development specifically in your country. This money came as a
payback contract deal between my late husband and a Russian Firm on our
countries Multi-billion dollars Ajaokuta Steel Plant.
The Russian Partners returned my husband's Share of USD$25,000,000.00 after
the death of my husband and Lodged in my husband's Security Company of which
l am director right now, the new Civilian Government have intensified their
probe on my husband? Financial and oil company. In view of these, l acted
fast to withdraw the US$25,000,000.00 from the company vault and deposited
it in a Security Company. I have since declared the Security Company
bankrupt. No record ever existed concerning the money traceable by the
government because there is no documentation showing that we received the
money from the Russian.
Due to the current situation in the country concerning government attitude
towards my family, it has become quite impossible for me to make use of this
money within. Let me refer you to the front page of this day newspapers of
10th March 2001. You can check it through their website
www.thisdayonline.com the present government in Nigeria had frozen and
seized all our bank accounts both here in Nigeria and abroad.Thus consent l
shall expect you to contact me urgently to enable us discuss in detail about
this transaction.Bearing in mind that your assistance is needed to transfer
this fund, I proposed a percentage of 30% of the total sum to you for the
expected service and assistance, 5% for offsetting minor expenses incurred
in the  course of this transaction. Your urgent response is highly needed as
to stop further contacts. All correspondence must be by the email address
[EMAIL PROTECTED]  I will give you my Tel numbers where you can
contact me when I hear from you.
I must use this opportunity to implore you to exercise the utmost indulgence
to keep this matter extraordinarily confidential whatever your decision
while await your prompt response.
NB: Because of the security being mounted on the members of my family, l has
decided that this transaction exist between you and my nephew Dr. Azeez
Bello. Remember to include your private Tel/fax or mobile number for easy
communication.
Best Regards.
DR. (MRS) MARIAM ABACHA



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Get Rid of this Crook

2003-07-03 Thread Christian Wach
@ 3/7/03 12:33 pm Daryl Meese wrote:

> Could someone that this ass of the mailing list

Just to chime in on the "reply to" thread earlier, Daryl, by hitting "reply
all" has now sent his email address to these 401 scamsters as well as the
list. Hopefully he'll not suffer any consequences from doing this, but the
risk is there.

Guess which side of the header-munging debate I sympathise with...

Regards,

Chris


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Get Rid of this Crook

2003-07-03 Thread Brian S. Drexler
You do have to admit though, it is a pretty good story. :-)  Now let me ask
you this.  You reply to this e-mail and give your phone/fax numbers and then
I'm assuming those get spammed all to hell too.  Correct?

-Original Message-
From: Daryl Meese [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 03, 2003 7:33 AM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: [PHP] Get Rid of this Crook


Could someone that this ass of the mailing list

Daryl



-Original Message-
From: MARIAM ABACHA [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 03, 2003 12:02 AM
To: [EMAIL PROTECTED]
Subject: [PHP] ASSISTANCE NEEDED


Hello,
I am sorry for the embarrassment this letter might cause you as we have not
had any correspondence before this letter. I got your address through my
nephew   with Nigerian Military Chamber of Commerce industry and Mining
during my research for a reliable and trustworthy partner who l can do
business with though l did not disclose the nature of the business l intend
to do with whoever he recommend for me.
I am DR. MRS MARIAM ABACHA, wife of the late Nigeria Head of State, General
Sanni Abacha who died on the 8th of June 1998 while still on active duty. I
am contacting you in view of the fact that we will be of great assistance to
each other likeness developing a cordial relationship.
I currently have within my reach the sum of Twenty - Five Million US Dollars
(US$25,000,000.00) cash which l intends to use for investment, like Real
Estate Development specifically in your country. This money came as a
payback contract deal between my late husband and a Russian Firm on our
countries Multi-billion dollars Ajaokuta Steel Plant.
The Russian Partners returned my husband's Share of USD$25,000,000.00 after
the death of my husband and Lodged in my husband's Security Company of which
l am director right now, the new Civilian Government have intensified their
probe on my husband? Financial and oil company. In view of these, l acted
fast to withdraw the US$25,000,000.00 from the company vault and deposited
it in a Security Company. I have since declared the Security Company
bankrupt. No record ever existed concerning the money traceable by the
government because there is no documentation showing that we received the
money from the Russian.
Due to the current situation in the country concerning government attitude
towards my family, it has become quite impossible for me to make use of this
money within. Let me refer you to the front page of this day newspapers of
10th March 2001. You can check it through their website
www.thisdayonline.com the present government in Nigeria had frozen and
seized all our bank accounts both here in Nigeria and abroad.Thus consent l
shall expect you to contact me urgently to enable us discuss in detail about
this transaction.Bearing in mind that your assistance is needed to transfer
this fund, I proposed a percentage of 30% of the total sum to you for the
expected service and assistance, 5% for offsetting minor expenses incurred
in the  course of this transaction. Your urgent response is highly needed as
to stop further contacts. All correspondence must be by the email address
[EMAIL PROTECTED]  I will give you my Tel numbers where you can
contact me when I hear from you.
I must use this opportunity to implore you to exercise the utmost indulgence
to keep this matter extraordinarily confidential whatever your decision
while await your prompt response.
NB: Because of the security being mounted on the members of my family, l has
decided that this transaction exist between you and my nephew Dr. Azeez
Bello. Remember to include your private Tel/fax or mobile number for easy
communication.
Best Regards.
DR. (MRS) MARIAM ABACHA



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Jeff Moser
So...why not write the entire included file as a function and then call that
function instead of using include? I'd be interested, though, to hear if the
return broke out of the include.

--
Jeff Moser
Web Developer
ihigh Inc. / Host Interactive
859.232.8282

-- 


-Original Message-
From: Ford, Mike [LSS] [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 03, 2003 5:10 AM
To: 'Jim Lucas'; Jonathan Pitcher; [EMAIL PROTECTED]
Subject: RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

> -Original Message-
> From: Jim Lucas [mailto:[EMAIL PROTECTED]
> Sent: 02 July 2003 22:47
> 
> Technically you are not outside of a function.
> 
> you need to use one of the include or require functions to 
> include the file
> right?

include and require are not functions -- they are language constructs.

(Proof:  include 'file.inc';   works.)

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] web based mail client

2003-07-03 Thread greg brant
hi, im the lead developer for a small online magazine / community

we want to set up an e-mail service where our users can create their own
mail account similar to hotmail etc etc.

i plan on using the imap_ functions and i was just wondering about the
potential security issues related to theses functions.

any advice or tips would be appreciated.

many thanks

Greg Brant



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Get Rid of this Crook

2003-07-03 Thread Jason Wong
On Thursday 03 July 2003 19:48, Christian Wach wrote:

> Just to chime in on the "reply to" thread earlier, Daryl, by hitting "reply
> all" has now sent his email address to these 401 scamsters as well as the
> list. Hopefully he'll not suffer any consequences from doing this, but the
> risk is there.

A decent mail client would allow you to at least:

 reply (to sender)
 reply (to list)
 reply to all (which means sender, and anyone else on the To: and Cc: fields)

> Guess which side of the header-munging debate I sympathise with...

It's a short-coming of your mail client, not the list -- guess which one 
should be changed?

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
The first myth of management is that it exists
-- Thoreau's Theories of Adaption n2
*/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Ford, Mike [LSS]
> -Original Message-
> From: Jeff Moser [mailto:[EMAIL PROTECTED]
> Sent: 03 July 2003 13:07
> 
> So...why not write the entire included file as a function and 
> then call that
> function instead of using include? I'd be interested, though, 
> to hear if the
> return broke out of the include.

Well, it damn well better, as the manual page at http://www.php.net/include says it 
does! (You can return a value, as well, if you really must.)

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mail + regex + somethoughts

2003-07-03 Thread Jason Wong
On Thursday 03 July 2003 19:18, Shivanischal A wrote:

> I believe very much in the spirit of mailing lists and will never commit
> any undesirable activity.

I'm not saying that you have been committing any undesirable acts -- and AFAIK 
you haven't -- yet ;-)

> I got the idea is when i browsed thru the Usenet Discussion Forums using
> Google's web-interface to the Usenet. If u go their site, u can see this.
> The UI look very cluttered with the previous posts appearing along with
> newer posts (as part of same message). 

Like I said it is *your* responsibility to trim posts, your mail client (or 
whatever you're using) isn't going to do it for you (not in any sensible 
fashion anyway because the technology just isn't there yet).

So again ...

> > And what's wrong with doing to what the rest of us do -- that is, remove
> > the unnecessary parts of the previous post and adding your comments
> > underneath the parts of the previous post that you are commenting on?

> I thought it would have been good if
> someone/something took care to remove the earlier posts even if the person
> posting it forgets to do so.

Most of the time you don't want to completely remove the previous post(s) from 
your reply, Sensible use of quoting helps the flow of the discussion so that 
people can jump in in the middle of a thread and still have some idea of what 
the thread is about.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Q:  What's the difference between USL and the Titanic?
A:  The Titanic had a band.
*/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: PHP5 classes

2003-07-03 Thread Catalin Trifu
hi,

Read the Changes in PHP 5/Zend Engine 2.0
http://www.php.net/zend-engine-2.php
The sections about constructors and destructors
are self explanatory:
the engine does not call autmatically the destructors
nor the constructors from the parent class.

Cheers,
Catalin



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: php my sql question

2003-07-03 Thread Anthony
When you upload the page to the webserver and then access it, do you just
see the source?  If so then you probably don;t have PHP support as part of
your hosting package.  Call your web host and find out.  Also, if you're
really new to PHP, I'll through this out too, you did put 
arround your script right?  Once you're sure PHP is running, then check out
the online manual for MySQL functions -->
http://us2.php.net/manual/en/ref.mysql.php  You don't need PHP on your local
machine, just on the webserver.  It may be a good idea though to install a
webserver (like Apache) and PHP on your local machine, that way you can test
your scripts without uploading them to the webserver.

- Anthony


"Jerome A. Jackson/Ac/Vcu" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I have a web site that has my sql installed.  The web server is 1st host
> web and they do not provide much support other than referral to my sql
> and php web site.  I know how to set up a database from a text file then
> upload to an sql database.  Now I want to write code to make it open and
> access it.  This is where I am stuck.  The web site uses an apache
> server.  Must I install php on my local machine?  When I save a web page
> with a php extension, it defaults to an html page and it will not work
> when I upload.
>
> --
> Jerome A. Jackson
> Information Services Coordinator
> Advancement Services
> Virginia Commonwealth University
> Post Office Box 842026
> Richmond, Virginia 23284-2026
> Phone: 804-828-2043  Fax: 804-828-0884
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Get Rid of this Crook

2003-07-03 Thread Adam Voigt
Well spamming doesn't get them any money. I believe
I read they use this info to transfer money from your bank
account, after convincing you to scan your passport for
them, or something like that.

One guy decided to "strike back", check it out:

http://www.haxial.com/spls-soapbox/nigerian-fraud/


On Thu, 2003-07-03 at 07:54, Brian S. Drexler wrote:
> You do have to admit though, it is a pretty good story. :-)  Now let me ask
> you this.  You reply to this e-mail and give your phone/fax numbers and then
> I'm assuming those get spammed all to hell too.  Correct?
> 
> -Original Message-
> From: Daryl Meese [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 7:33 AM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: [PHP] Get Rid of this Crook
> 
> 
> Could someone that this ass of the mailing list
> 
> Daryl
> 
> 
> 
> -Original Message-
> From: MARIAM ABACHA [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 12:02 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] ASSISTANCE NEEDED
> 
> 
> Hello,
> I am sorry for the embarrassment this letter might cause you as we have not
> had any correspondence before this letter. I got your address through my
> nephew   with Nigerian Military Chamber of Commerce industry and Mining
> during my research for a reliable and trustworthy partner who l can do
> business with though l did not disclose the nature of the business l intend
> to do with whoever he recommend for me.
> I am DR. MRS MARIAM ABACHA, wife of the late Nigeria Head of State, General
> Sanni Abacha who died on the 8th of June 1998 while still on active duty. I
> am contacting you in view of the fact that we will be of great assistance to
> each other likeness developing a cordial relationship.
> I currently have within my reach the sum of Twenty - Five Million US Dollars
> (US$25,000,000.00) cash which l intends to use for investment, like Real
> Estate Development specifically in your country. This money came as a
> payback contract deal between my late husband and a Russian Firm on our
> countries Multi-billion dollars Ajaokuta Steel Plant.
> The Russian Partners returned my husband's Share of USD$25,000,000.00 after
> the death of my husband and Lodged in my husband's Security Company of which
> l am director right now, the new Civilian Government have intensified their
> probe on my husband? Financial and oil company. In view of these, l acted
> fast to withdraw the US$25,000,000.00 from the company vault and deposited
> it in a Security Company. I have since declared the Security Company
> bankrupt. No record ever existed concerning the money traceable by the
> government because there is no documentation showing that we received the
> money from the Russian.
> Due to the current situation in the country concerning government attitude
> towards my family, it has become quite impossible for me to make use of this
> money within. Let me refer you to the front page of this day newspapers of
> 10th March 2001. You can check it through their website
> www.thisdayonline.com the present government in Nigeria had frozen and
> seized all our bank accounts both here in Nigeria and abroad.Thus consent l
> shall expect you to contact me urgently to enable us discuss in detail about
> this transaction.Bearing in mind that your assistance is needed to transfer
> this fund, I proposed a percentage of 30% of the total sum to you for the
> expected service and assistance, 5% for offsetting minor expenses incurred
> in the  course of this transaction. Your urgent response is highly needed as
> to stop further contacts. All correspondence must be by the email address
> [EMAIL PROTECTED]  I will give you my Tel numbers where you can
> contact me when I hear from you.
> I must use this opportunity to implore you to exercise the utmost indulgence
> to keep this matter extraordinarily confidential whatever your decision
> while await your prompt response.
> NB: Because of the security being mounted on the members of my family, l has
> decided that this transaction exist between you and my nephew Dr. Azeez
> Bello. Remember to include your private Tel/fax or mobile number for easy
> communication.
> Best Regards.
> DR. (MRS) MARIAM ABACHA
> 
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
-- 
Adam Voigt ([EMAIL PROTECTED])
Linux/Unix Network Administrator
The Cryptocomm Group


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Get Rid of this Crook

2003-07-03 Thread Dan Joseph
No, they actually contact you, and scam you for about 2 trips to Europe, and
$50,000.  That's how they make their money.  There have been several
documentaries on cable about this stuff.

-Dan Joseph

> -Original Message-
> From: Brian S. Drexler [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 7:55 AM
> To: 'Daryl Meese'; [EMAIL PROTECTED]
> Subject: RE: [PHP] Get Rid of this Crook
>
>
> You do have to admit though, it is a pretty good story. :-)  Now
> let me ask
> you this.  You reply to this e-mail and give your phone/fax
> numbers and then
> I'm assuming those get spammed all to hell too.  Correct?
>
> -Original Message-
> From: Daryl Meese [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 7:33 AM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: [PHP] Get Rid of this Crook
>
>
> Could someone that this ass of the mailing list
>
> Daryl
>
>
>
> -Original Message-
> From: MARIAM ABACHA [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 12:02 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] ASSISTANCE NEEDED
>
>
> Hello,
> I am sorry for the embarrassment this letter might cause you as
> we have not
> had any correspondence before this letter. I got your address through my
> nephew   with Nigerian Military Chamber of Commerce industry and Mining
> during my research for a reliable and trustworthy partner who l can do
> business with though l did not disclose the nature of the
> business l intend
> to do with whoever he recommend for me.
> I am DR. MRS MARIAM ABACHA, wife of the late Nigeria Head of
> State, General
> Sanni Abacha who died on the 8th of June 1998 while still on
> active duty. I
> am contacting you in view of the fact that we will be of great
> assistance to
> each other likeness developing a cordial relationship.
> I currently have within my reach the sum of Twenty - Five Million
> US Dollars
> (US$25,000,000.00) cash which l intends to use for investment, like Real
> Estate Development specifically in your country. This money came as a
> payback contract deal between my late husband and a Russian Firm on our
> countries Multi-billion dollars Ajaokuta Steel Plant.
> The Russian Partners returned my husband's Share of
> USD$25,000,000.00 after
> the death of my husband and Lodged in my husband's Security
> Company of which
> l am director right now, the new Civilian Government have
> intensified their
> probe on my husband? Financial and oil company. In view of these, l acted
> fast to withdraw the US$25,000,000.00 from the company vault and deposited
> it in a Security Company. I have since declared the Security Company
> bankrupt. No record ever existed concerning the money traceable by the
> government because there is no documentation showing that we received the
> money from the Russian.
> Due to the current situation in the country concerning government attitude
> towards my family, it has become quite impossible for me to make
> use of this
> money within. Let me refer you to the front page of this day newspapers of
> 10th March 2001. You can check it through their website
> www.thisdayonline.com the present government in Nigeria had frozen and
> seized all our bank accounts both here in Nigeria and abroad.Thus
> consent l
> shall expect you to contact me urgently to enable us discuss in
> detail about
> this transaction.Bearing in mind that your assistance is needed
> to transfer
> this fund, I proposed a percentage of 30% of the total sum to you for the
> expected service and assistance, 5% for offsetting minor expenses incurred
> in the  course of this transaction. Your urgent response is
> highly needed as
> to stop further contacts. All correspondence must be by the email address
> [EMAIL PROTECTED]  I will give you my Tel numbers where you can
> contact me when I hear from you.
> I must use this opportunity to implore you to exercise the utmost
> indulgence
> to keep this matter extraordinarily confidential whatever your decision
> while await your prompt response.
> NB: Because of the security being mounted on the members of my
> family, l has
> decided that this transaction exist between you and my nephew Dr. Azeez
> Bello. Remember to include your private Tel/fax or mobile number for easy
> communication.
> Best Regards.
> DR. (MRS) MARIAM ABACHA
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Job Offer

2003-07-03 Thread Erich Kolb
The company that I work for is currently looking for an additional web
developer.  If you are interested, please send your resume and a link to at
least 3 of your most recent projects.  Qualified candidates should have at
least 4 years of experience with HTML/Javascript Design, PHP, MySQL, Apache,
and RedHat.  Please respond by email.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] dynamic form display??

2003-07-03 Thread Jay Blanchard
[snip]
On the form that I am creating I allow the user to browse for a file.  I
would like it that once the user selects the file, that it displays only
the
file information in a  on the same page.  The idea is that the
user can keep browsing and selecting files and the file information
(location and name) is transferred further down the page in the
textarea.
Once the user is done, they click on a submit button which then loads
all
the files from either the textarea into the database.  I've seen
something
like this done with both ASP and ColdFusion but not PHP.

Basically its like this:
1. Browse for a file
2. find file and select the file and click OK
3. The file information is moved from the browse file text box to the
textarea
4. The user then searches for another file like above and the new file
is
added underneath the file already in the textarea.  The process repeats
until the user is done.
5. The user then clicks the Submit button which loads the files in the
textarea into the database

Any snippets of code or known likeness would be greatly appreciated.
One
other thing.  I'm fairly new to PHP so, please comment the code if you
would.
[/snip]


Unless you want to make a round trip to the server each time this sounds
like a job for **ta-dat-ta-dah!** JavaScript!

HTH!

Jay

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: web based mail client

2003-07-03 Thread Pete Morganic
There's loads of email clients here

http://www.hotscripts.com/PHP/Scripts_and_Programs/Email_Systems/Web-based_Email/index.html

Greg Brant wrote:
hi, im the lead developer for a small online magazine / community

we want to set up an e-mail service where our users can create their own
mail account similar to hotmail etc etc.
i plan on using the imap_ functions and i was just wondering about the
potential security issues related to theses functions.
any advice or tips would be appreciated.

many thanks

Greg Brant




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: Calculating Largest Member of Array

2003-07-03 Thread Anthony
why not just change your array structure a little so that the date is the
key, and the elements are the values.  so it would look like this.
Array
 (
 [Jan-99] => Array
 (
 [0] => 6399.36
 [1] => 6132.71
 [2] => 2242.20
 [3] => 53.27
 [4] => 87.34
 )

 [Feb-99] => Array
 (
 [0] => 5754.72
 [1] => 3964.93
 [2] => 6145.98
 [3] => 693.32
 [4] => 23.80
 )
 )
That would make it much easier. I think.

- Anthony


"John Wulff" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Sorry for the multiple post!! Apparently when pasting I hit some magic
send
> key.I'd like to calculate the largest member of this array without taking
> into
> account the first value which is obvisouly not numeric.
>
> So far this is how I'm doing it, but sometimes I get returned a month for
> the max.
>
> $high = end(array_reduce($cdata,
>   create_function('$a, $b',
>   'return array(max(array_reduce($a, "max"),
>   array_reduce($b, "max")));')));
>
> Array
> (
> [0] => Array
> (
> [0] => Jan-99
> [1] => 6399.36
> [2] => 6132.71
> [3] => 2242.20
> [4] => 53.27
> [5] => 87.34
> )
>
> [1] => Array
> (
> [0] => Feb-99
> [1] => 5754.72
> [2] => 3964.93
> [3] => 6145.98
> [4] => 693.32
> [5] => 23.80
> )
> )
>
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: PHP user group

2003-07-03 Thread Steve Magruder
Erich Kolb wrote:
> Does anyone know of a PHP user group near Gurnee, IL.  I found one in
> Chicago, but its a little far to go and they meet in the middle of
> the day on Sat.

Take a look at http://php.meetup.com - perhaps there's a PHP meetup near
you.

Steve
-- 

Steve Magruder Consulting - http://consulting.stevemagruder.com



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: dynamic form display??

2003-07-03 Thread Anthony
PHP is not what you're looking for here.  You'll want to use something like
JavaScript.  I'm assuming that you want to do this on the browser side so
that you'll upload all the files at once.  If that is the case, PHP won't
know anything about it since it's a server side language.  I've seen things
like this done in JavaScript before and seen really cool ones that are IE,
vbs only.  Look in that dirrection.

- Anthony


"Micah Montoy" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On the form that I am creating I allow the user to browse for a file.  I
> would like it that once the user selects the file, that it displays only
the
> file information in a  on the same page.  The idea is that the
> user can keep browsing and selecting files and the file information
> (location and name) is transferred further down the page in the textarea.
> Once the user is done, they click on a submit button which then loads all
> the files from either the textarea into the database.  I've seen something
> like this done with both ASP and ColdFusion but not PHP.
>
> Basically its like this:
> 1. Browse for a file
> 2. find file and select the file and click OK
> 3. The file information is moved from the browse file text box to the
> textarea
> 4. The user then searches for another file like above and the new file is
> added underneath the file already in the textarea.  The process repeats
> until the user is done.
> 5. The user then clicks the Submit button which loads the files in the
> textarea into the database
>
> Any snippets of code or known likeness would be greatly appreciated.  One
> other thing.  I'm fairly new to PHP so, please comment the code if you
> would.
>
> thanks a bunch
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] print html code

2003-07-03 Thread Wendell Brown
On Wed, 2 Jul 2003 14:23:23 -0700, Jim Lucas wrote:

>well, tell me.  What browser follows the standards 100% ??

I would bet that it would be easier to come up with a browser that
supports 100% of the HTML standard (which is IMHO the minimum the
browser HAS to support) than it would be to come up with a browser that
supports 100% of the nonstandard.  :)

As the old saying goes two wrongs don't make a right.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] print html code

2003-07-03 Thread Dan Joseph
Hi,

> I would bet that it would be easier to come up with a browser that
> supports 100% of the HTML standard (which is IMHO the minimum the
> browser HAS to support) than it would be to come up with a browser that
> supports 100% of the nonstandard.  :)
>
> As the old saying goes two wrongs don't make a right.

There's no such thing.  Its SQL servers, some support the full language,
some don't.

-Dan Joseph


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Setting Cookie Going Nuts

2003-07-03 Thread Mike Morton
I am trying to issue a cookie, using the set cookie directive, and it is not
working for some reason.  The code below I have used before with perfect
success.  The only difference between the other place that I am using it is
that the other place has globals on, this server has globals off (tho I
turned them on a and it made no difference), and the other server is running
4.3.2 where this one is 4.3.0

I am sure that it is something small that I missed when copying the code
over, but I cannot for the life of me see what it is.  The only other
difference is the other server is using a domain name, while the server this
code is on is an IP address only (that should not make a difference tho)

Why is the cookie not being isseued?  I am going nuts trying to figure this
out!

$ADMIN_COOKIE_NAME="scavengeradmin"; //name of the issuing cookie
$COOKIE_EXPIRY=1800; //time in seconds to expiry

function adminCookie() {
global $ADMIN_COOKIE_NAME,$COOKIE_EXPIRY;

//check to see if a cookie exists already.
$cookieid=$_COOKIE[$ADMIN_COOKIE_NAME];

//if there is no cookieid - then we are going to set a cookie.
if(strlen($cookieid) < 1) {
//find a unique value.
list($msec,$sec)=explode(" ",microtime());
$cookiekey=ereg_replace("\.","",($msec+$sec));
//set expiry - 30 mins from now.
$cookieexpiry=time()+$COOKIE_EXPIRY;

setcookie($ADMIN_COOKIE_NAME,$cookiekey,$cookieexpiry,"/",$_SERVER["HTTP_HOS
T"],0);
$_COOKIE[$ADMIN_COOKIE_NAME]=$cookiekey;
unset($cookiekey);unset($msec);unset($sec);unset($cookieexpiry);
} else {
//if the cookie has been set then we are just going to adjust the
expiry date.
//set expiry - 30 mins from now.
$cookieexpiry=time()+$COOKIE_EXPIRY;

setcookie($ADMIN_COOKIE_NAME,"$cookieid",$cookieexpiry,"/",$_SERVER["HTTP_HO
ST"],0);
unset($cookieexpiry);
}

unset($cookieid);
}

adminCookie(); //issue the cookie

--
Cheers

Mike Morton


*
* Tel: 905-465-1263
* Email: [EMAIL PROTECTED]
*


"Indeed, it would not be an exaggeration to describe the history of the
computer industry for the past decade as a massive effort to keep up with
Apple."
- Byte Magazine

Given infinite time, 100 monkeys could type out the complete works of
Shakespeare. Win 98 source code? Eight monkeys, five minutes.
-- NullGrey 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Get Rid of this Crook

2003-07-03 Thread Doug Essinger-Hileman
On 3 Jul 2003 at 9:06, Adam Voigt wrote:

> Well spamming doesn't get them any money. I believe
> I read they use this info to transfer money from your bank
> account, after convincing you to scan your passport for
> them, or something like that.

Actually, the scam is fairly sophisticated. They ask for money 
upfront in order to begin the process of getting access to the loot 
that is stored whereever. Usually, they ask for one or two more 
payments, since it is costing them more than they thought. They then 
inform you that the money you sent them has been used to bribe 
officials, including those in the government. If you don't send them 
even more money, they will report you to the authorities on suspicion 
of bribery and have you arrested.

At this point, the scam becomes simple blackmail. Most interesting to 
me is that this scam is so widespread (a sign that it is successful) 
that the FBI has stationed some agents in Nigeria solely for the 
purpose of dealing with this scam. Apparently, there are some folk so 
greedy that gullibility wins the day.

Doug


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Multiple posts.

2003-07-03 Thread news.php.net
I was wondering if there is a way to solve my problem. I want to send
certain information to certain webpage for about 25 times ( I wanna make a
webpage to send a SMS to every player in our soccer team). I can send the
needed information to one server and it sends an SMS but how to do it 25
times in a row. I have a form where I can write the message and I take the
phonenumbers from db and there's a button to send the sms. If I do it once
it works fine, but how to do it multiple times? The real problem is that
after I do it once the browser opens a web page returned from the
sms-server. So what should I do to prevent the browser doing this and can I
make a php-script to my webserver that sends the needed information as many
times as I want and without opening the "requested" page?



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Multiple posts.

2003-07-03 Thread Jeff Harris
On Jun 30, 2003, "news.php.net" claimed that:

|I was wondering if there is a way to solve my problem. I want to send
|certain information to certain webpage for about 25 times ( I wanna make a
|webpage to send a SMS to every player in our soccer team). I can send the
|needed information to one server and it sends an SMS but how to do it 25
|times in a row. I have a form where I can write the message and I take the
|phonenumbers from db and there's a button to send the sms. If I do it once
|it works fine, but how to do it multiple times? The real problem is that
|after I do it once the browser opens a web page returned from the
|sms-server. So what should I do to prevent the browser doing this and can I
|make a php-script to my webserver that sends the needed information as many
|times as I want and without opening the "requested" page?
|

If you're sending the SMS message through another web page, perhaps one of
the Pear HTTP packages might work for you:
(http://pear.php.net/packages.php?catpid=11&catname=HTTP)

I haven't started experimenting with any of them yet, but I'm sure someone
will be able to help out if you need assistance.

Jeff

-- 
Registered Linux user #304026.
"lynx -source http://jharris.rallycentral.us/jharris.asc | gpg --import"
Key fingerprint = 52FC 20BD 025A 8C13 5FC6  68C6 9CF9 46C2 B089 0FED
Responses to this message should conform to RFC 1855.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP to Excel Export

2003-07-03 Thread Mark McCulligh
Hi Group,

I am working on an app the creates an Excel file. Right now I am using the
PEAR package Spreadsheet_Excel_Writer. It works great but I have one
problem.  I have a field greater then 255 to export and the PEAR package
truncates anything over 255.

Has anyone used or know of a Excel class that allow fields greater then 255.

Thanks, Mark.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP and graphics

2003-07-03 Thread César Aracena
Hi all,

I'm developing a new site where the visitors, among other things, will be
able to see a map of my country, choose a region then a city, in order to
see a complete map of that place. Another good thing would be to let the
user set the starting and destination points of a trip and show him or her
wich would be the best route to take, gas stations, hotels, etc.

My question is: Is this possible using PHP and MySQL or do I need to use
also some other tool like Java or other?

Thanks in advanced,

---
Cesar Aracena
[EMAIL PROTECTED]
http://www.icaam.com.ar
Cel: +54.299.635-6688
Tel/Fax: +54.299.477-4532
Cipolletti, Rio Negro
R8324BEG
Argentina




---
Soluciones profesionales en
 Internet y Comunicaciones
  http://www.icaam.com.ar



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: PHP + Linux: Configuration?

2003-07-03 Thread Anthony
Not 100% sure, but isn't $HTTP_POST_VARS depricated?... to lazy to look in
the manual right now.  You should use $_POST instead.  I have no idea if
that's causing your problem though :-P

- Anthony


"Luiz Morte" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Hello list,

I have a problem using php in linux. I´m using the code bellow:

html code:

 
 


php code
",count($linhas));
?>

If I repeat the line bellow 100 times and put this in a textarea, the php
code returns that there are 154 lines.
teste.com.br::Teste
variaveis::teste::teste::dfasfafasdfafasdfasfas::11::11::ativo::teste.do.tes
te

I´ve made this test using the versions:
php-4.2.2-17
php-4.3.2-3

Using FreeBSD, I don´t have the error with the same code. (php-4.3.1)

Any ideia?
Thanks in advance,
Luiz.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Redirect to a different frame...

2003-07-03 Thread Grant Rutherford
Hello there,

I was wondering if there is a way to use the header function in php to
redirect the browser's output to a different frame.

Specifically, I have a form on frame A which has two submit buttons.  I
would like one to submit the data in the form to a page which will load
in frame A, and the other to submit the data to the same page which will
load in frame B.

I was hoping that I could put some code at the top of the results page
which will tell the browser which frame to display it in (dependent on
which $_POST variable is set).  Is this possible?

Thanks,
Grant


-- 
Grant Rutherford
Iders Incorporated
600A Clifton Street
Winnipeg, MB Canada R3G 2X6
http://www.iders.ca
tel: 204-779-5400 ext 36
fax: 204-779-5444

This message is intended solely for the use of the designated
recipient(s) and their appointed delegates, and may contain
confidential information.  Any unauthorized disclosure,
copying or distribution of its contents is strictly prohibited.
If you have received this message in error, please destroy it
and advise the sender immediately by phone, email or facsimile.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Redirect to a different frame...

2003-07-03 Thread Dan Joseph
Hi,

> I was wondering if there is a way to use the header function in php to
> redirect the browser's output to a different frame.
>
> Specifically, I have a form on frame A which has two submit buttons.  I
> would like one to submit the data in the form to a page which will load
> in frame A, and the other to submit the data to the same page which will
> load in frame B.

in your  tag, you can put target=framename, example:



Anything submitted from that frame will target the specified frame.  No
fancy PHP needed, unless you want to make the target dynamic.

-Dan Joseph


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Jim Lucas
i works for me in many different areas on my site

Jim Lucas

- Original Message -
From: "Jeff Moser" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, July 03, 2003 5:07 AM
Subject: RE: [PHP] Break, Exit, Die, Kill, Maime and Stab


So...why not write the entire included file as a function and then call that
function instead of using include? I'd be interested, though, to hear if the
return broke out of the include.

--
Jeff Moser
Web Developer
ihigh Inc. / Host Interactive
859.232.8282

--


-Original Message-
From: Ford, Mike [LSS] [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 03, 2003 5:10 AM
To: 'Jim Lucas'; Jonathan Pitcher; [EMAIL PROTECTED]
Subject: RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

> -Original Message-
> From: Jim Lucas [mailto:[EMAIL PROTECTED]
> Sent: 02 July 2003 22:47
>
> Technically you are not outside of a function.
>
> you need to use one of the include or require functions to
> include the file
> right?

include and require are not functions -- they are language constructs.

(Proof:  include 'file.inc';   works.)

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Redirect to a different frame...

2003-07-03 Thread Grant Rutherford
Hi there,

Thanks for your response.  I understand that I can specify a target in
the form tag.  However, if I were to do that both buttons would have to
go to the same frame.  (I think?)

If I could specify the target for each submit button, that would work
perfectly.  Also, if I could have the same input fields shared between
two forms (one for each target destination).  However, I don't think
that either of these is an option in regular HTML.

Thanks,
Grant


On Thu, 2003-07-03 at 10:41, Dan Joseph wrote:
> Hi,
> 
> > I was wondering if there is a way to use the header function in php to
> > redirect the browser's output to a different frame.
> >
> > Specifically, I have a form on frame A which has two submit buttons.  I
> > would like one to submit the data in the form to a page which will load
> > in frame A, and the other to submit the data to the same page which will
> > load in frame B.
> 
>   in your  tag, you can put target=framename, example:
> 
>   
> 
>   Anything submitted from that frame will target the specified frame.  No
> fancy PHP needed, unless you want to make the target dynamic.
> 
> -Dan Joseph
-- 
Grant Rutherford
Iders Incorporated
600A Clifton Street
Winnipeg, MB Canada R3G 2X6
http://www.iders.ca
tel: 204-779-5400 ext 36
fax: 204-779-5444

This message is intended solely for the use of the designated
recipient(s) and their appointed delegates, and may contain
confidential information.  Any unauthorized disclosure,
copying or distribution of its contents is strictly prohibited.
If you have received this message in error, please destroy it
and advise the sender immediately by phone, email or facsimile.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Redirect to a different frame...

2003-07-03 Thread Dan Joseph
Oh, yeah, that is correct.  You'd need to use the  tag and put some
javascript in them to target the frames.  I'm not up on the javascript
enough though, check javascript.internet.com for more information.

-Dan Joseph

> -Original Message-
> From: Grant Rutherford [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 03, 2003 12:03 PM
> To: Dan Joseph
> Cc: PHP Mailing List
> Subject: RE: [PHP] Redirect to a different frame...
>
>
> Hi there,
>
> Thanks for your response.  I understand that I can specify a target in
> the form tag.  However, if I were to do that both buttons would have to
> go to the same frame.  (I think?)
>
> If I could specify the target for each submit button, that would work
> perfectly.  Also, if I could have the same input fields shared between
> two forms (one for each target destination).  However, I don't think
> that either of these is an option in regular HTML.
>
> Thanks,
> Grant
>
>
> On Thu, 2003-07-03 at 10:41, Dan Joseph wrote:
> > Hi,
> >
> > > I was wondering if there is a way to use the header function in php to
> > > redirect the browser's output to a different frame.
> > >
> > > Specifically, I have a form on frame A which has two submit
> buttons.  I
> > > would like one to submit the data in the form to a page which
> will load
> > > in frame A, and the other to submit the data to the same page
> which will
> > > load in frame B.
> >
> > in your  tag, you can put target=framename, example:
> >
> >  target=framethree>
> >
> > Anything submitted from that frame will target the
> specified frame.  No
> > fancy PHP needed, unless you want to make the target dynamic.
> >
> > -Dan Joseph
> --
> Grant Rutherford
> Iders Incorporated
> 600A Clifton Street
> Winnipeg, MB Canada R3G 2X6
> http://www.iders.ca
> tel: 204-779-5400 ext 36
> fax: 204-779-5444
>
> This message is intended solely for the use of the designated
> recipient(s) and their appointed delegates, and may contain
> confidential information.  Any unauthorized disclosure,
> copying or distribution of its contents is strictly prohibited.
> If you have received this message in error, please destroy it
> and advise the sender immediately by phone, email or facsimile.
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Get Rid of this Crook

2003-07-03 Thread Anthony
pathetic isn't it  :-/

- Anthony


"Doug Essinger-Hileman" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On 3 Jul 2003 at 9:06, Adam Voigt wrote:
>
> > Well spamming doesn't get them any money. I believe
> > I read they use this info to transfer money from your bank
> > account, after convincing you to scan your passport for
> > them, or something like that.
>
> Actually, the scam is fairly sophisticated. They ask for money
> upfront in order to begin the process of getting access to the loot
> that is stored whereever. Usually, they ask for one or two more
> payments, since it is costing them more than they thought. They then
> inform you that the money you sent them has been used to bribe
> officials, including those in the government. If you don't send them
> even more money, they will report you to the authorities on suspicion
> of bribery and have you arrested.
>
> At this point, the scam becomes simple blackmail. Most interesting to
> me is that this scam is so widespread (a sign that it is successful)
> that the FBI has stationed some agents in Nigeria solely for the
> purpose of dealing with this scam. Apparently, there are some folk so
> greedy that gullibility wins the day.
>
> Doug
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Redirect to a different frame...

2003-07-03 Thread Adam Voigt





On Thu, 2003-07-03 at 12:02, Dan Joseph wrote:
> Oh, yeah, that is correct.  You'd need to use the  tag and put some
> javascript in them to target the frames.  I'm not up on the javascript
> enough though, check javascript.internet.com for more information.
> 
> -Dan Joseph
> 
> > -Original Message-
> > From: Grant Rutherford [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, July 03, 2003 12:03 PM
> > To: Dan Joseph
> > Cc: PHP Mailing List
> > Subject: RE: [PHP] Redirect to a different frame...
> >
> >
> > Hi there,
> >
> > Thanks for your response.  I understand that I can specify a target in
> > the form tag.  However, if I were to do that both buttons would have to
> > go to the same frame.  (I think?)
> >
> > If I could specify the target for each submit button, that would work
> > perfectly.  Also, if I could have the same input fields shared between
> > two forms (one for each target destination).  However, I don't think
> > that either of these is an option in regular HTML.
> >
> > Thanks,
> > Grant
> >
> >
> > On Thu, 2003-07-03 at 10:41, Dan Joseph wrote:
> > > Hi,
> > >
> > > > I was wondering if there is a way to use the header function in php to
> > > > redirect the browser's output to a different frame.
> > > >
> > > > Specifically, I have a form on frame A which has two submit
> > buttons.  I
> > > > would like one to submit the data in the form to a page which
> > will load
> > > > in frame A, and the other to submit the data to the same page
> > which will
> > > > load in frame B.
> > >
> > >   in your  tag, you can put target=framename, example:
> > >
> > >> target=framethree>
> > >
> > >   Anything submitted from that frame will target the
> > specified frame.  No
> > > fancy PHP needed, unless you want to make the target dynamic.
> > >
> > > -Dan Joseph
> > --
> > Grant Rutherford
> > Iders Incorporated
> > 600A Clifton Street
> > Winnipeg, MB Canada R3G 2X6
> > http://www.iders.ca
> > tel: 204-779-5400 ext 36
> > fax: 204-779-5444
> >
> > This message is intended solely for the use of the designated
> > recipient(s) and their appointed delegates, and may contain
> > confidential information.  Any unauthorized disclosure,
> > copying or distribution of its contents is strictly prohibited.
> > If you have received this message in error, please destroy it
> > and advise the sender immediately by phone, email or facsimile.
> >
-- 
Adam Voigt ([EMAIL PROTECTED])
Linux/Unix Network Administrator
The Cryptocomm Group


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Redirect to a different frame...

2003-07-03 Thread Grant Rutherford
Hi there,

Thank you!

I had a feeling that javascript would be the answer, but as I have not
yet learned javascript, I was hoping that php would work.  Oh, well.  No
sense putting that off anymore.  Time to delve into the javascript
tutorials.

Thanks for your time, everyone.
Grant


On Thu, 2003-07-03 at 11:07, Adam Voigt wrote:
>  onclick="javascript:document.formname.target =
> 'frame1';document.formname.submit();">
> 
>  onclick="javascript:document.formname.target =
> 'frame2';document.formname.submit();">
> 
> 
> On Thu, 2003-07-03 at 12:02, Dan Joseph wrote:
> > Oh, yeah, that is correct.  You'd need to use the  tag and put some
> > javascript in them to target the frames.  I'm not up on the javascript
> > enough though, check javascript.internet.com for more information.
> > 
> > -Dan Joseph
> > 
> > > -Original Message-
> > > From: Grant Rutherford [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, July 03, 2003 12:03 PM
> > > To: Dan Joseph
> > > Cc: PHP Mailing List
> > > Subject: RE: [PHP] Redirect to a different frame...
> > >
> > >
> > > Hi there,
> > >
> > > Thanks for your response.  I understand that I can specify a target in
> > > the form tag.  However, if I were to do that both buttons would have to
> > > go to the same frame.  (I think?)
> > >
> > > If I could specify the target for each submit button, that would work
> > > perfectly.  Also, if I could have the same input fields shared between
> > > two forms (one for each target destination).  However, I don't think
> > > that either of these is an option in regular HTML.
> > >
> > > Thanks,
> > > Grant
> > >
> > >
> > > On Thu, 2003-07-03 at 10:41, Dan Joseph wrote:
> > > > Hi,
> > > >
> > > > > I was wondering if there is a way to use the header function in php to
> > > > > redirect the browser's output to a different frame.
> > > > >
> > > > > Specifically, I have a form on frame A which has two submit
> > > buttons.  I
> > > > > would like one to submit the data in the form to a page which
> > > will load
> > > > > in frame A, and the other to submit the data to the same page
> > > which will
> > > > > load in frame B.
> > > >
> > > > in your  tag, you can put target=framename, example:
> > > >
> > > >  > > target=framethree>
> > > >
> > > > Anything submitted from that frame will target the
> > > specified frame.  No
> > > > fancy PHP needed, unless you want to make the target dynamic.
> > > >
> > > > -Dan Joseph
> > > --
> > > Grant Rutherford
> > > Iders Incorporated
> > > 600A Clifton Street
> > > Winnipeg, MB Canada R3G 2X6
> > > http://www.iders.ca
> > > tel: 204-779-5400 ext 36
> > > fax: 204-779-5444
> > >
> > > This message is intended solely for the use of the designated
> > > recipient(s) and their appointed delegates, and may contain
> > > confidential information.  Any unauthorized disclosure,
> > > copying or distribution of its contents is strictly prohibited.
> > > If you have received this message in error, please destroy it
> > > and advise the sender immediately by phone, email or facsimile.
> > >
> -- 
> Adam Voigt ([EMAIL PROTECTED])
> Linux/Unix Network Administrator
> The Cryptocomm Group
-- 
Grant Rutherford
Iders Incorporated
600A Clifton Street
Winnipeg, MB Canada R3G 2X6
http://www.iders.ca
tel: 204-779-5400 ext 36
fax: 204-779-5444

This message is intended solely for the use of the designated
recipient(s) and their appointed delegates, and may contain
confidential information.  Any unauthorized disclosure,
copying or distribution of its contents is strictly prohibited.
If you have received this message in error, please destroy it
and advise the sender immediately by phone, email or facsimile.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] imap_search question

2003-07-03 Thread greg brant
hi.

in the php manual
the entry for imap_search states it has 3 arguments

"imap_search ( resource imap_stream, string criteria, int options)"

i get the first 2, but whats the third.

at the end of the page it says
"Valid values for flags are SE_UID, which causes the returned array to
contain UIDs instead of messages sequence numbers. "

so should
imap_search ( $myStream, "ALL", SE_UID);

return an array of the UIDs of the emails?

because this is what i want.
i need to work with the UIDs not the mesage numbers

cheers folks


Greg Brant



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP form builder?

2003-07-03 Thread J J
I've seen survey tools before to build surveys
dynamically with PHP code, but I'm looking for
something a bit more simple that just allows you to
build HTML forms dynamically.

Something where I say I need 10 fields, some
checkboxes, a submit button and it then generates the
form on the fly.

Then that form could be submitted to a database, or
direct to email, etc.

Is there something like this built already in
PHP/Javascript?



__
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Please Help.. cgi.force_redirect does not work

2003-07-03 Thread Scott Fletcher
Hi!

To make the long story short, we use IIS 5.0 with PHP 4.0.6 for a while.
Then we builted a new database server, SQL-2000 and point the website to the
new server.  Then we notice the problem with the CGI error.  So, we last
week downloaded the PHP 4.3.3 and update the IIS with the newer PHP version
and set the cgi.force_redirect to zero in php.ini.  See example below
--snip--
; cgi.force_redirect is necessary to provide security running PHP as a CGI
under
; most web servers.  Left undefined, PHP turns this on by default.  You can
; turn it off here AT YOUR OWN RISK
; **You CAN safely turn this off for IIS, in fact, you MUST.**
cgi.force_redirect = 0
--snip--

We still have problem with CGI error.  The use of php function, header() is
what cause the error.  Yes, the IIS and the website are reading the php.ini
correctly.  I checked that out and it is verified.

So, what is the workaround to the CGI error??

Thanks,
 Scott



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] PHP and graphics

2003-07-03 Thread SED
Hello Aracena,

To answer your question: Yes, this is doable in PHP/MySQL but you need
to make the maps, database and functions by yourself.

However, I have not yet found any "all-ready-made" solution (without
paying huge $$$). If you will find solution, please inform us if
possible - even if you only find a algorithm.

Regards, 
Sumarlidi Einar Dadason 

SED DESIGN 
_ 
Email:[EMAIL PROTECTED] 
Website:  http://www.sed.is 




-Original Message-
From: César Aracena [mailto:[EMAIL PROTECTED] 
Sent: 3. júlí 2003 13:57
To: [EMAIL PROTECTED]
Subject: [PHP] PHP and graphics


Hi all,

I'm developing a new site where the visitors, among other things, will
be able to see a map of my country, choose a region then a city, in
order to see a complete map of that place. Another good thing would be
to let the user set the starting and destination points of a trip and
show him or her wich would be the best route to take, gas stations,
hotels, etc.

My question is: Is this possible using PHP and MySQL or do I need to use
also some other tool like Java or other?

Thanks in advanced,

---
Cesar Aracena
[EMAIL PROTECTED]
http://www.icaam.com.ar
Cel: +54.299.635-6688
Tel/Fax: +54.299.477-4532
Cipolletti, Rio Negro
R8324BEG
Argentina




---
Soluciones profesionales en
 Internet y Comunicaciones
  http://www.icaam.com.ar



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: web based mail client

2003-07-03 Thread Anthony
In addition to using an elready developed web mail client.  If you plan to
have a large number of users, you might want to go with some type of
completely managed packaged software.  I was reading about Novell NetMail.
Check it out, even runs on Linux now too -->
http://www.novell.com/products/netmail/  Don't know how customiseable it is
or if you could use PHP to extend it, but its worth a look.

- Anthony


"Pete Morganic" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> There's loads of email clients here
>
>
http://www.hotscripts.com/PHP/Scripts_and_Programs/Email_Systems/Web-based_E
mail/index.html
>
> Greg Brant wrote:
> > hi, im the lead developer for a small online magazine / community
> >
> > we want to set up an e-mail service where our users can create their own
> > mail account similar to hotmail etc etc.
> >
> > i plan on using the imap_ functions and i was just wondering about the
> > potential security issues related to theses functions.
> >
> > any advice or tips would be appreciated.
> >
> > many thanks
> >
> > Greg Brant
> >
> >
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Get Rid of this Crook

2003-07-03 Thread Jeff Harris
On Jul 3, 2003, "Jason Wong" claimed that:

|On Thursday 03 July 2003 19:48, Christian Wach wrote:
|
|> Just to chime in on the "reply to" thread earlier, Daryl, by hitting "reply
|> all" has now sent his email address to these 401 scamsters as well as the
|> list. Hopefully he'll not suffer any consequences from doing this, but the
|> risk is there.
|
|A decent mail client would allow you to at least:
|
| reply (to sender)
| reply (to list)
| reply to all (which means sender, and anyone else on the To: and Cc: fields)
|
|> Guess which side of the header-munging debate I sympathise with...
|
|It's a short-coming of your mail client, not the list -- guess which one
|should be changed?
|

Should people bend to the technology they use, or should the technology be
manipulated to do the people's bidding?

Jeff
-- 
Registered Linux user #304026.
"lynx -source http://jharris.rallycentral.us/jharris.asc | gpg --import"
Key fingerprint = 52FC 20BD 025A 8C13 5FC6  68C6 9CF9 46C2 B089 0FED
Responses to this message should conform to RFC 1855.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Jeff Schwartz
The PHP site (under Servers-Apache 2.0) says "Do not use Apache 2.0 and PHP in a 
production environment neither on Unix nor on Windows" but isn't clear whether Linux 
is included or whether it applies to all Apache 2 releases (such as 2.0.46) or just 
the original 2.0.
 
And, Red Hat 9 comes with 2.0 so it's really confusing. Has anyone had any experience 
with this combo?
 
Thanks,
Jeff


-
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!

RE: [PHP] Break, Exit, Die, Kill, Maime and Stab

2003-07-03 Thread Chris Hayes
At 14:35 3-7-2003, you wrote:
> -Original Message-
> From: Jeff Moser [mailto:[EMAIL PROTECTED]
> Sent: 03 July 2003 13:07
>
> So...why not write the entire included file as a function and
> then call that
> function instead of using include? I'd be interested, though,
> to hear if the
> return broke out of the include.
Mike Ford:
Well, it damn well better, as the manual page at 
http://www.php.net/include says it does! (You can return a value, as well, 
if you really must.)
ah that's interesting.

another option using multiple returns in one function:

function testvars($var1,$var2)
{ if ($var1<1)   return 'var1 must be a positive integer';
  if ($var2=='bad') return 'var2 is bad!';
  //this line is only reached when all vars are tested ok:
  return true;
}
$result=testvars($var1,$var2);

if ($result!=true) {
echo $result.'Please warp to your previous 
location';
exit();
  }



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Sancar Saran
On Thursday 03 July 2003 20:51, Jeff Schwartz wrote:
> The PHP site (under Servers-Apache 2.0) says "Do not use Apache 2.0 and PHP
> in a production environment neither on Unix nor on Windows" but isn't clear
> whether Linux is included or whether it applies to all Apache 2 releases
> (such as 2.0.46) or just the original 2.0.
>
> And, Red Hat 9 comes with 2.0 so it's really confusing. Has anyone had any
> experience with this combo?
>
> Thanks,
> Jeff

Hi,
Not on RH 9. But on gentoo I use apache 2.0, it not for production nor 
development. 

Lots of problems,

Perhaps RH solve someting using own patch, and I repead if you gonna build 
production server. Stay away Apache 2.0

Basicly, when you ecounter a problem, then ask question here,
first response

Use Apache 1.3.27 or someting like that.

Good luck


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Ford, Mike [LSS]
> -Original Message-
> From: Jeff Schwartz [mailto:[EMAIL PROTECTED]
> Sent: 03 July 2003 18:52
> 
> The PHP site (under Servers-Apache 2.0) says "Do not use 
> Apache 2.0 and PHP in a production environment neither on 
> Unix nor on Windows"

Well, that's a clumsily-worded sentence all around (I would guess from a non-native 
English user!).  I assume the writer was trying to emphasize that he meant not to use 
it "on any platform", but really "Do not use Apache 2.0 and PHP in a production 
environment" just about says it all without the embellishment.

>  but isn't clear whether Linux is 
> included

Yes, it is.  (And MacOS X!)

>  or whether it applies to all Apache 2 releases (such 
> as 2.0.46) or just the original 2.0.

2.0 can usually be taken to mean 2.0.x, and it can in this instance, too.

HTH

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Red Hat 9, Apache 2, and PHP

2003-07-03 Thread justin gruenberg
Jeff Schwartz wrote:

The PHP site (under Servers-Apache 2.0) says "Do not use Apache 2.0 and PHP in a production environment neither on Unix nor on Windows" but isn't clear whether Linux is included or whether it applies to all Apache 2 releases (such as 2.0.46) or just the original 2.0.

And, Red Hat 9 comes with 2.0 so it's really confusing. Has anyone had any experience with this combo?

Thanks,
Jeff
 

When someone says UNIX, they're generally including Linux and BSD, as 
both are UNIX clones.  At this point anyone in their right mind is going 
to suggest you stick with Apache 1.3.x.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Uploading files time out every so often

2003-07-03 Thread Ivo Pletikosic
Hello,

I am currently involved in a site where users frequently need to upload text
files of various sizes. Every so often users will experience problems where
the uploads will start timing-out and need to be reinitiated.

The timeout problem comes and goes, so far I've been unable to find the root
cause. It happens with files of all sizes, from 10k to several MB,
eventually they all get uploaded, tho sometimes it can take days re-trying.

Another issue is experienced when the above symptom is happening which makes
me think they're related. An additional tool on the site writes out files
with information provided by a user thru a form. A user submits a form with
some text and php writes out a file with the received info and notifies the
user the task was done. Every so often the browser will timeout with no file
written out by php or notification. This symptom can go on for days. The
info being written to a file is never longer than a dozen lines of text so
it's quite small.

Initially we thought that the server just did not have the resources to
service simultaneous uploads but monitoring tools show the cpu appears to be
near idle when this is experienced. I've experienced the file writing
problem when I was the only user on the server with all unnecessary services
disabled. The browser will just time out, then one days voila! it works
until the next problem day.

This is on a Linux box with Apache 1.3, php 4.2.2 & experienced across
multiple browsers. All the scripts have set_time_limit(0). File system has
the proper permissions and with plenty of free space.

We've been collecting quite a lot of info from the server to try to capture
it's state at the time of the problem but nothing raises any flags.

Has anyone experienced this issue or a similar issue? Any pointers and help
is greatly appreciated. 

Ivo

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: web based mail client

2003-07-03 Thread greg brant
yeah. the thing is. its a bit of a fudge.
we dont have our own news server. were just on a £150 pre year hosting
service
its somthing we want to do so the workaround is

you have one catch-all e-mail address
then your mail system lives within this.
so a user logs in to your e-mail frontend. not the actuall mail server.
then every user 'actualy logs in with the same username and pass but they
dont get to see that.
then the php filters only the emails addressed to them.




"Anthony" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> In addition to using an elready developed web mail client.  If you plan to
> have a large number of users, you might want to go with some type of
> completely managed packaged software.  I was reading about Novell NetMail.
> Check it out, even runs on Linux now too -->
> http://www.novell.com/products/netmail/  Don't know how customiseable it
is
> or if you could use PHP to extend it, but its worth a look.
>
> - Anthony
>
>
> "Pete Morganic" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > There's loads of email clients here
> >
> >
>
http://www.hotscripts.com/PHP/Scripts_and_Programs/Email_Systems/Web-based_E
> mail/index.html
> >
> > Greg Brant wrote:
> > > hi, im the lead developer for a small online magazine / community
> > >
> > > we want to set up an e-mail service where our users can create their
own
> > > mail account similar to hotmail etc etc.
> > >
> > > i plan on using the imap_ functions and i was just wondering about the
> > > potential security issues related to theses functions.
> > >
> > > any advice or tips would be appreciated.
> > >
> > > many thanks
> > >
> > > Greg Brant
> > >
> > >
> >
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] DOMXML usage

2003-07-03 Thread Matt Grimm
I'm attempting to create a generic XML writer with the DOMXML functions
which takes as its input the array structure generated by gdemartiti on this
function page:
http://us3.php.net/manual/en/function.xml-parse-into-struct.php

Actually, it's the updated version done by [EMAIL PROTECTED], here:
http://www.devdump.com/phpxml.php

Anyway, the trouble I'm having is when I get to a child element and need to
use 'append_child' -- append_child requires that you specify the ancestor
element you're appending to, but I can't seem to reference that object when
I loop back into the function.  This is probably a class/object issue since
I'm pretty useless with classes.

If I come into the function, having passed the ancestor name as a string and
having already added the ancestor as an object in the class, this doesn't
work:

$child = $ancestor->append_child($thisChild);

The error is: "...Call to a member function on a non-object...".  How can I
reference that ancestor object when I come back into the function?

(PHP version is 4.3.2, Apache 2.0.44 on Win2k)

Thanks,
--
Matt Grimm
Web Developer
The Health TV Channel, Inc.
(a non - profit organization)
3820 Lake Otis Parkway
Anchorage, AK 99508
907.770.6200 ext. 686
907.336.6205 (fax)
E-mail: [EMAIL PROTECTED]
Web: www.healthtvchannel.org



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Sending a PDF page

2003-07-03 Thread Todd Cary






[Sent this the first time to the wrong list]

In this code:

 if ($prtpdf) {
    include "letter_new.php";
    exit;
  }

I create a PDF page, however I would like to continue within the script
(not have the exit).  If I do that, the PDF page is corrupted by the
script code.

What is the best solution for this?

Todd

-- 



<>

[PHP] how do i work with an "object"

2003-07-03 Thread greg brant
imap_headder info returns an "object".

print_r works to see all the stuff containd within but when i try to acces
it via

print object[date];

i get naff all

to save you looking, heres the entry in the manual

cheers folks

Description
object imap_headerinfo ( resource imap_stream, int msg_number [, int
fromlength [, int subjectlength [, string defaulthost]]])


This function returns an object of various header elements.




   remail, date, Date, subject, Subject, in_reply_to, message_id,
   newsgroups, followup_to, references

message flags:
   Recent -  'R' if recent and seen,
 'N' if recent and not seen,
 ' ' if not recent
   Unseen -  'U' if not seen AND not recent,
 ' ' if seen OR not seen and recent
   Answered -'A' if answered,
 ' ' if unanswered
   Deleted - 'D' if deleted,
 ' ' if not deleted
   Draft -   'X' if draft,
 ' ' if not draft
   Flagged - 'F' if flagged,
 ' ' if not flagged

NOTE that the Recent/Unseen behavior is a little odd. If you want to
know if a message is Unseen, you must check for

Unseen == 'U' || Recent == 'N'

toaddress (full to: line, up to 1024 characters)

to[] (returns an array of objects from the To line, containing):
   personal
   adl
   mailbox
   host

fromaddress (full from: line, up to 1024 characters)

from[] (returns an array of objects from the From line, containing):
   personal
   adl
   mailbox
   host

ccaddress (full cc: line, up to 1024 characters)
cc[] (returns an array of objects from the Cc line, containing):
   personal
   adl
   mailbox
   host

bccaddress (full bcc line, up to 1024 characters)
bcc[] (returns an array of objects from the Bcc line, containing):
   personal
   adl
   mailbox
   host

reply_toaddress (full reply_to: line, up to 1024 characters)
reply_to[] (returns an array of objects from the Reply_to line,
containing):
   personal
   adl
   mailbox
   host

senderaddress (full sender: line, up to 1024 characters)
sender[] (returns an array of objects from the sender line, containing):
   personal
   adl
   mailbox
   host

return_path (full return-path: line, up to 1024 characters)
return_path[] (returns an array of objects from the return_path line,
containing):
   personal
   adl
   mailbox
   host

udate (mail message date in unix time)

fetchfrom (from line formatted to fit fromlength
characters)

fetchsubject (subject line formatted to fit subjectlength characters)



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] how do i work with an "object"

2003-07-03 Thread Brad Pauly
greg brant wrote:
imap_headder info returns an "object".

print_r works to see all the stuff containd within but when i try to acces
it via
print object[date];

i get naff all
You need to assign the object to a variable first. There are some 
examples in the user contributed notes in the manual, but essentially 
something like this:

$header = imap_header($foo, $bar);
print $header->date;
http://us4.php.net/manual/en/function.imap-headerinfo.php

Brad



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: Please Help.. cgi.force_redirect does not work

2003-07-03 Thread Scott Fletcher
Oddly, the CGI Error message is intermitted.  It come on some of the time
and some of the other time doesn't.  What is the problem here.?

"Scott Fletcher" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hi!
>
> To make the long story short, we use IIS 5.0 with PHP 4.0.6 for a
while.
> Then we builted a new database server, SQL-2000 and point the website to
the
> new server.  Then we notice the problem with the CGI error.  So, we last
> week downloaded the PHP 4.3.3 and update the IIS with the newer PHP
version
> and set the cgi.force_redirect to zero in php.ini.  See example below
> --snip--
> ; cgi.force_redirect is necessary to provide security running PHP as a CGI
> under
> ; most web servers.  Left undefined, PHP turns this on by default.  You
can
> ; turn it off here AT YOUR OWN RISK
> ; **You CAN safely turn this off for IIS, in fact, you MUST.**
> cgi.force_redirect = 0
> --snip--
>
> We still have problem with CGI error.  The use of php function, header()
is
> what cause the error.  Yes, the IIS and the website are reading the
php.ini
> correctly.  I checked that out and it is verified.
>
> So, what is the workaround to the CGI error??
>
> Thanks,
>  Scott
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Sending a PDF page

2003-07-03 Thread Brad Pauly
Todd Cary wrote:
In this code:

 if ($prtpdf) {
include "letter_new.php";
exit;
  }
I create a PDF page, however I would like to continue within the script 
(not have the exit).  If I do that, the PDF page is corrupted by the 
script code.

What is the best solution for this?
I am assuming that "letter_new.php" outputs the contents of the PDF you 
are generating. You could use output buffering to grab the PDF and then 
go on with your script:

if ($prtpdf) {
ob_start();
include "letter_new.php";
$pdf_buffer = ob_get_contents();
ob_end_clean();
}
http://us2.php.net/manual/en/ref.outcontrol.php

Brad



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Sending a PDF page

2003-07-03 Thread Ray Hunter
Try using the a shutdown function:

http://us2.php.net/manual/en/function.register-shutdown-function.php

and put all your logic that needs to run after the exit function.

--
BigDog



On Thu, 2003-07-03 at 13:18, Todd Cary wrote:
> [Sent this the first time to the wrong list]
> 
> In this code:
> 
>  if ($prtpdf) {
> include "letter_new.php";
> exit;
>   }
> 
> I create a PDF page, however I would like to continue within the
> script (not have the exit).  If I do that, the PDF page is corrupted
> by the script code.
> 
> What is the best solution for this?
> 
> Todd
> 
> -- 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Joseph Szobody
Folks,

I'm just getting ready to built a webserver this weekend and was planning on using 
RH9, so this thread especially caught my eye. The website that the server will be 
hosting is pretty simple, some basic DB queries, no special Apache modules. Is Apache 
2.0 still not a good choice for something simple?

If I really should use Apache 1.3, then which route would be easier...

1. Install RH9, remove Apache 2.0 and manually install Apache 1.3 (from tarball). The 
only problem with this is that I will no longer be able to use the Red Hat Network's 
"up2date" tool to download and apply patches (from what I understand). Up2date is a 
huge time saver for me.

2. Install RH7.3, and manually install the latest version of PHP (I simply can't use 
the version that comes with RH7.3). Of course then I still have the older version of 
MySQL, and everything else.

Comments?

Joseph


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Sending a PDF page

2003-07-03 Thread Suhas Pharkute



try to send it as attachment
Suhas
_
 
Encrypt your PHP code for FREE at
 
http://encphp.sspsoft.com
 
_

  - Original Message - 
  From: 
  Todd 
  Cary 
  To: [EMAIL PROTECTED] 
  Sent: Thursday, July 03, 2003 1:18 
  PM
  Subject: [PHP] Sending a PDF page
  [Sent this the first time to the wrong list]In this 
  code: if ($prtpdf) {    include 
  "letter_new.php";    exit;  }I create a 
  PDF page, however I would like to continue within the script (not have the 
  exit).  If I do that, the PDF page is corrupted by the script 
  code.What is the best solution for this?Todd
  -- 


Re: [PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread ed

 I'm current;y in the process of setting up a new web server myself. The
obvious choice for me was to use Red Hat 7.3 for the install. On a clean
install all the nice options are already present, (ssl, php, mysql, gd
lib) which is much better thatn what we used to run, Red Hat 5.2! Been
running that for the past 4 years on that dinosaur.

Ed


On Thu, 3 Jul 2003, Joseph Szobody wrote:

> Folks,
> 
> I'm just getting ready to built a webserver this weekend and was planning on using 
> RH9, so this thread especially caught my eye. The website that the server will be 
> hosting is pretty simple, some basic DB queries, no special Apache modules. Is 
> Apache 2.0 still not a good choice for something simple?
> 
> If I really should use Apache 1.3, then which route would be easier...
> 
> 1. Install RH9, remove Apache 2.0 and manually install Apache 1.3 (from tarball). 
> The only problem with this is that I will no longer be able to use the Red Hat 
> Network's "up2date" tool to download and apply patches (from what I understand). 
> Up2date is a huge time saver for me.
> 
> 2. Install RH7.3, and manually install the latest version of PHP (I simply can't use 
> the version that comes with RH7.3). Of course then I still have the older version of 
> MySQL, and everything else.
> 
> Comments?
> 
> Joseph
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Need a function to calculate time difference.

2003-07-03 Thread Jack Sasportas
datetime.

Thanks

Jim Lucas wrote:

what type of format does your column take?

date
time
datetime
??

Jim Lucas
- Original Message - 
From: "Jack Sasportas" <[EMAIL PROTECTED]>
To: "php" <[EMAIL PROTECTED]>
Sent: Wednesday, July 02, 2003 2:11 PM
Subject: [PHP] Need a function to calculate time difference.

 

I am trying to find a function or information on how to properly take a 
start time and an end time from mysql timestamps in order to calculate 
time taken.
So in theory $endtime-$starttime = timespent.

It would be great if this understood that 11:55 pm til 12:10am one day 
apart only equals 15 minutes.

Links, example code etc would be great!

Thanks

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
   



 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] PDF on the fly ?

2003-07-03 Thread [-^-!-%-

Hello!

I'm trying to create a PDF file for downloading, but Acrobat cannot read
the generated file. I get a "file corrupted or cannot be found", whenever
I try to open the file.


My script is as follow:


header("Cache-control: private");
header("Content-type: application/octet-stream");
header("Content-type: application/pdf");
header("Content-Disposition: attachment; filename=file.pdf");

//sql code to retrieve data as $data

echo $data

//...more code

//

As expected, the server create the pdf file and force the browser to open
the save file dialog box to save the file. Acrobat,however cannot read the
generated file (both online or offline). Any suggestions?

Am I missing something?

Please help.

-john

 =P e p i e  D e s i g n s
 www.pepiedesigns.com
 Providing Solutions That Increase Productivity

 Web Developement. Database. Hosting. Multimedia.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PDF on the fly:::Addition

2003-07-03 Thread [-^-!-%-

I just found out that the generated file, though with .pdf extension, is
actually an HTML file. The file was never encoded to PDF.

What am I missing?

-john


=P e p i e  D e s i g n s
 www.pepiedesigns.com
 Providing Solutions That Increase Productivity

 Web Developement. Database. Hosting. Multimedia.

On Thu, 3 Jul 2003, [-^-!-%- wrote:

>
> Hello!
>
> I'm trying to create a PDF file for downloading, but Acrobat cannot read
> the generated file. I get a "file corrupted or cannot be found", whenever
> I try to open the file.
>
>
> My script is as follow:
>
>
> header("Cache-control: private");
> header("Content-type: application/octet-stream");
> header("Content-type: application/pdf");
> header("Content-Disposition: attachment; filename=file.pdf");
>
> //sql code to retrieve data as $data
>
> echo $data
>
> //...more code
>
> //
>
> As expected, the server create the pdf file and force the browser to open
> the save file dialog box to save the file. Acrobat,however cannot read the
> generated file (both online or offline). Any suggestions?
>
> Am I missing something?
>
> Please help.
>
> -john
>
>  =P e p i e  D e s i g n s
>  www.pepiedesigns.com
>  Providing Solutions That Increase Productivity
>
>  Web Developement. Database. Hosting. Multimedia.
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PDF on the fly:::Addition

2003-07-03 Thread Shena Delian O'Brien
[-^-!-%- wrote:
I just found out that the generated file, though with .pdf extension, is
actually an HTML file. The file was never encoded to PDF.
What am I missing?
You need a PDF file library...

http://www.php.net/manual/en/ref.cpdf.php
http://www.php.net/manual/en/ref.pdf.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Mark McCulligh
I am also building a new server.  I am going with RedHat 8, but only
installing the Classic server from the CDs. Then installing/configuring
Apache/PHP/MySQL/SSL manually. I like the rpm install programs but I like to
be able to add modules in the future and I find it easier the configure it
all by hand.

I also use the up2date, but only for the basic server part, not the
webserver part.  I will reconfigure my web server is a new version or patch
comes out.

I am doing to use Apache 1.3.27, because I too have read all the warnings
about 2.X and PHP, it does not look stable. Maybe with PHP 5 it will be
stable.

I went with Redhat 8 over 9 because I have also read about a lot of bugs
with redhat 9.

I usually don't like to use the new of anything until it have been out for
sometime and I don't see any see bug reports.

Just my two cent.

Mark.



"Joseph Szobody" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Folks,

I'm just getting ready to built a webserver this weekend and was planning on
using RH9, so this thread especially caught my eye. The website that the
server will be hosting is pretty simple, some basic DB queries, no special
Apache modules. Is Apache 2.0 still not a good choice for something simple?

If I really should use Apache 1.3, then which route would be easier...

1. Install RH9, remove Apache 2.0 and manually install Apache 1.3 (from
tarball). The only problem with this is that I will no longer be able to use
the Red Hat Network's "up2date" tool to download and apply patches (from
what I understand). Up2date is a huge time saver for me.

2. Install RH7.3, and manually install the latest version of PHP (I simply
can't use the version that comes with RH7.3). Of course then I still have
the older version of MySQL, and everything else.

Comments?

Joseph



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread ed

 Does anyone remember the warning concerning MySQL and glibc. I distinctly
remember some conflict between the two and up2date installing a bad
mismatch lib making MySQL act funny. It's one of the reasons I'll stick
with Red Hat 7.3 but I my conclusions about the situation may be clouded
because of this.

Ed


On Thu, 3 Jul 2003, Mark McCulligh wrote:

> I am also building a new server.  I am going with RedHat 8, but only
> installing the Classic server from the CDs. Then installing/configuring
> Apache/PHP/MySQL/SSL manually. I like the rpm install programs but I like to
> be able to add modules in the future and I find it easier the configure it
> all by hand.
> 
> I also use the up2date, but only for the basic server part, not the
> webserver part.  I will reconfigure my web server is a new version or patch
> comes out.
> 
> I am doing to use Apache 1.3.27, because I too have read all the warnings
> about 2.X and PHP, it does not look stable. Maybe with PHP 5 it will be
> stable.
> 
> I went with Redhat 8 over 9 because I have also read about a lot of bugs
> with redhat 9.
> 
> I usually don't like to use the new of anything until it have been out for
> sometime and I don't see any see bug reports.
> 
> Just my two cent.
> 
> Mark.
> 
> 
> 
> "Joseph Szobody" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> Folks,
> 
> I'm just getting ready to built a webserver this weekend and was planning on
> using RH9, so this thread especially caught my eye. The website that the
> server will be hosting is pretty simple, some basic DB queries, no special
> Apache modules. Is Apache 2.0 still not a good choice for something simple?
> 
> If I really should use Apache 1.3, then which route would be easier...
> 
> 1. Install RH9, remove Apache 2.0 and manually install Apache 1.3 (from
> tarball). The only problem with this is that I will no longer be able to use
> the Red Hat Network's "up2date" tool to download and apply patches (from
> what I understand). Up2date is a huge time saver for me.
> 
> 2. Install RH7.3, and manually install the latest version of PHP (I simply
> can't use the version that comes with RH7.3). Of course then I still have
> the older version of MySQL, and everything else.
> 
> Comments?
> 
> Joseph
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Greg Donald

> I usually don't like to use the new of anything until it have been out for
> sometime and I don't see any see bug reports.

And just when would this rare event occur, if ever?

Every version of Apache, PHP, or Linux distro ever released has had bugs or 
exploits of some form.  If you're waiting for a perfect version of any of 
those, it'll still be a long while.

The best thing to do is just pick a distro that releases patches quickly, and 
keep up to date on patches.


-- 
Greg Donald
http://destiney.com/



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP to Excel Export

2003-07-03 Thread Chris Hayes
At 16:56 3-7-2003, you wrote:
Hi Group,

I am working on an app the creates an Excel file. Right now I am using the
PEAR package Spreadsheet_Excel_Writer. It works great but I have one
problem.  I have a field greater then 255 to export and the PEAR package
truncates anything over 255.
Has anyone used or know of a Excel class that allow fields greater then 255.
i just write a .csv file with a header that claims it is for Excel. Then 
Excel just opens it and converts it for me.



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] CSR file

2003-07-03 Thread Siddharth Hegde
Hello,

Does any one know how to decode a CSR ( Certificate Signing Request) file in PHP and 
get the ifo out from the server?

- Sid

[PHP] Please Hit these links... (for testing purposes)

2003-07-03 Thread Michael Smith
Hey,

would everyone take a wack at
http://www.prattmuseum.org:8080/prattcms/
http://www.prattmuseum.org:8080/prattcms/?id=49
and click links a couple of times? I'm working on some stats, and I 
especially need some from foreign countries (not US).

Thanks!

-Michael

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Please Hit these links... (for testing purposes)

2003-07-03 Thread Michael Smith
Hey,

would everyone take a wack at
http://www.prattmuseum.org:8080/prattcms/
http://www.prattmuseum.org:8080/prattcms/?id=49
and click links a couple of times? I'm working on some stats, and I
especially need some from foreign countries (not US).
Thanks!

-Michael

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Re: Red Hat 9, Apache 2, and PHP

2003-07-03 Thread Todd Cary




Mark McCulligh wrote:

  I am also building a new server.  I am going with RedHat 8, but only
installing the Classic server from the CDs. Then installing/configuring
Apache/PHP/MySQL/SSL manually. I like the rpm install programs but I like to
be able to add modules in the future and I find it easier the configure it
all by hand.

I also use the up2date, but only for the basic server part, not the
webserver part.  I will reconfigure my web server is a new version or patch
comes out.

I am doing to use Apache 1.3.27, because I too have read all the warnings
about 2.X and PHP, it does not look stable. Maybe with PHP 5 it will be
stable.

I went with Redhat 8 over 9 because I have also read about a lot of bugs
with redhat 9.

I usually don't like to use the new of anything until it have been out for
sometime and I don't see any see bug reports.

Just my two cent.

Mark.



"Joseph Szobody" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
Folks,

I'm just getting ready to built a webserver this weekend and was planning on
using RH9, so this thread especially caught my eye. The website that the
server will be hosting is pretty simple, some basic DB queries, no special
Apache modules. Is Apache 2.0 still not a good choice for something simple?

If I really should use Apache 1.3, then which route would be easier...

1. Install RH9, remove Apache 2.0 and manually install Apache 1.3 (from
tarball). The only problem with this is that I will no longer be able to use
the Red Hat Network's "up2date" tool to download and apply patches (from
what I understand). Up2date is a huge time saver for me.

2. Install RH7.3, and manually install the latest version of PHP (I simply
can't use the version that comes with RH7.3). Of course then I still have
the older version of MySQL, and everything else.

Comments?

Joseph

  

Linux is quite new for me, so please forgive me if my questions are
rather basic.

I have RH 9 installed and I want to add the Interbase extensions to PHP
and then recompile Apache.  Conceptually I understand what has to be
done, but I do not know the steps or syntax.  Is there documentation
available for doing this?

Todd
-- 



<>

[PHP] Database question

2003-07-03 Thread Hardik Doshi
Hi Group,

Currently i am connecting the underlying database
server from every php page. To reduce the connection
overhead i am thinking to store the PEAR DB object
into the registry (session) at the time of user login.
Here i am connecting the Database only one time and
rest of the time i am using the object stored in the
memory. Even this is more helpful when the application
is connecting more than one database..My application
is getting feed from four different databases reside
on two different servers.

I don't know what ever i am thinking is correct or
not.. Please guide me if i am wrong anywhere and if
any one of you have better idea then please disucss.

Thanks

Hardik Doshi

__
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Database question

2003-07-03 Thread Pete Morganic
definately do NOT recommend this path-
Just make an include file at the top of each page
pete

Hardik Doshi wrote:
Hi Group,

Currently i am connecting the underlying database
server from every php page. To reduce the connection
overhead i am thinking to store the PEAR DB object
into the registry (session) at the time of user login.
Here i am connecting the Database only one time and
rest of the time i am using the object stored in the
memory. Even this is more helpful when the application
is connecting more than one database..My application
is getting feed from four different databases reside
on two different servers.
I don't know what ever i am thinking is correct or
not.. Please guide me if i am wrong anywhere and if
any one of you have better idea then please disucss.
Thanks

Hardik Doshi

__
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: [PHP-DB] Database question

2003-07-03 Thread Paul Chvostek
On Thu, Jul 03, 2003 at 07:00:17AM -0700, Hardik Doshi wrote:
>
> Currently i am connecting the underlying database
> server from every php page. To reduce the connection
> overhead i am thinking to store the PEAR DB object
> into the registry (session) at the time of user login.
> Here i am connecting the Database only one time and
> rest of the time i am using the object stored in the
> memory.

Nice as it sounds, this won't work.  I don't recall where it's
documented, but at least with MySQL (and I'm assuming with the others as
well), a database link identifier cannot be stored in a session variable
and then re-used by another session.  Check out
http://www.php.net/features.persistent-connections for details.

-- 
  Paul Chvostek <[EMAIL PROTECTED]>
  it.canadahttp://www.it.ca/
  Free PHP web hosting!http://www.it.ca/web/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



  1   2   >