RE: [PHP] Zend IDE vs. PhpEd

2003-01-05 Thread Timothy Hitchens \(HiTCHO\)
__NO I DON'T WORK FOR ZEND__

Well I use Zend Studio and have done for sometime.

Check out there offer for Small Business:

http://www.zend.com/store/products/zend-smallbiz.php

Includes the Encoder and the IDE ++

You won't regret a Zend Studio buy and with the upgrade option
you get all upgrades (including all version comp eg 4.x.x comp)
included.



HiTCHO has Spoken! 
Timothy Hitchens (HiTCHO)
[EMAIL PROTECTED] 

> -Original Message-
> From: Mirek Novak [mailto:[EMAIL PROTECTED]] 
> Sent: Monday, 6 January 2003 5:08 PM
> To: John Wells; [EMAIL PROTECTED]
> Subject: Re: [PHP] Zend IDE vs. PhpEd
> 
> 
> John Wells wrote:
> > Can anyone who's familiar with both give an honest, open 
> evaluation?  
> > I'm in a rush project and need something quickly (have to purchase 
> > tomorrow), but I'm on the fence when it comes to these two products.
> > 
> > Zend costs $100 less than Phped, so I'm leaning that way.  But if 
> > there's anything you know that could make my decision 
> easier, please 
> > forward it on.  They seem pretty comparable, with the exception of 
> > PhpEd's db browser.
> 
> ... have u seen phpEdit? It's for free, has perfect autocompletion, 
> project manager, editable templates and many other features. AFAIK it 
> has no db browser, but has good developer community around 
> ... http://www.phpedit.net
> 
> 
> -- 
> Mirek Novak
> jabber:[EMAIL PROTECTED]
> ICQ:119499448
> 
> AUTO.CZ
> http://www.auto.cz
> 
> NEWS.AUTO.CZ
> http://news.auto.cz
> 
> FORMULE1.CZ
> http://www.formule1.cz
> 
> 
> -- 
> 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] Zend IDE vs. PhpEd

2003-01-05 Thread Mirek Novak
John Wells wrote:

Can anyone who's familiar with both give an honest, open evaluation?  I'm
in a rush project and need something quickly (have to purchase tomorrow),
but I'm on the fence when it comes to these two products.

Zend costs $100 less than Phped, so I'm leaning that way.  But if there's
anything you know that could make my decision easier, please forward it
on.  They seem pretty comparable, with the exception of PhpEd's db
browser.


... have u seen phpEdit? It's for free, has perfect autocompletion, 
project manager, editable templates and many other features. AFAIK it 
has no db browser, but has good developer community around ...
http://www.phpedit.net


--
Mirek Novak
jabber:[EMAIL PROTECTED]
ICQ:119499448

AUTO.CZ
http://www.auto.cz

NEWS.AUTO.CZ
http://news.auto.cz

FORMULE1.CZ
http://www.formule1.cz


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



[PHP] changing uid/gid

2003-01-05 Thread Pupeno
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Is it posible to change the current uid/gid in a script that is being running
? of course, having the user and password ? like running su.
I'm writting a script that has to perform some operations on the files on the
server, make some directories in the place where the web is and make some
symlinks, the other option, is to make a bash script that would do the work
of making some globaly writeable directories to later let php do the job and
I don't like that option.
Thanks
Carpe diem.
- --
Pupeno: [EMAIL PROTECTED]
http://www.pupeno.com
- ---
Help the hungry children of Argentina,
please go to (and make it your homepage):
http://www.porloschicos.com/servlet/PorLosChicos?comando=donar
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE+GSorLr8z5XzmSDQRAn6iAJ96NIQIdVwUqeEpMbSkwAQAEHIfdwCgtfCf
eOfVoJXVBd/wzZ0aEwiWEZU=
=P6Tf
-END PGP SIGNATURE-


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




Re: [PHP] emulate Post with redirect

2003-01-05 Thread Jason Wong
On Monday 06 January 2003 14:01, Bobby Patel wrote:
> Hello, I want to emulate a POST request to Paypal. Originally a POST
> request is sent from the user (through a form) and the user is redirected
> to paypal's site. Now, what I want to do is to emulate a POST request (so
> that the surfer can't see some of the hidden fields of the form) and to
> deter tampering. (If they could see all the fields, they could just create
> their own form , and just change the amount).
>
> Possible solution:
> fsockopen to emulate POST, but that doesn;t redirect the user,  using
> header will direct the user to the paypal site, but then I have to use a
> GET request and then once again variables are visible and modifiable.
>
>
> Desired solution:
> a PHP script (toPaypal.php, say) that is called when a surfer wants to buy
> something for a product for $5 , say.
> The Product form will direct to the toPaypal.php script that creates a POST
> request and sends the request and the surefer to Paypal.
>
> Any ideas? or did I just make this confusing? One solution I guess is to
> just double check the total amount credited to the merchant account matches
> the product. But then I ask this question out of curosity.

Have a look at curl and snoopy.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
Remember, drive defensively! And of course, the best defense is a good 
offense!
*/


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




[PHP] emulate Post with redirect

2003-01-05 Thread Bobby Patel
Hello, I want to emulate a POST request to Paypal. Originally a POST request
is sent from the user (through a form) and the user is redirected to
paypal's site. Now, what I want to do is to emulate a POST request (so that
the surfer can't see some of the hidden fields of the form) and to deter
tampering. (If they could see all the fields, they could just create their
own form , and just change the amount).

Possible solution:
fsockopen to emulate POST, but that doesn;t redirect the user,  using header
will direct the user to the paypal site, but then I have to use a GET
request and then once again variables are visible and modifiable.


Desired solution:
a PHP script (toPaypal.php, say) that is called when a surfer wants to buy
something for a product for $5 , say.
The Product form will direct to the toPaypal.php script that creates a POST
request and sends the request and the surefer to Paypal.

Any ideas? or did I just make this confusing? One solution I guess is to
just double check the total amount credited to the merchant account matches
the product. But then I ask this question out of curosity.





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




[PHP] emulate full post wth redirect

2003-01-05 Thread Bobby Patel
Hello, I want to emulate a POST request to Paypal. Originally a POST request
is sent from the user (through a form) and the user is redirected to
paypal's site. Now, what I want to do is to emulate a POST request (so that
the surfer can't see some of the hidden fields of the form) and to deter
tampering. (If they could see all the fields, they could just create their
own form , and just change the amount).

Possible solution:
fsockopen to emulate POST, but that doesn;t redirect the user,  using header
will direct the user to the paypal site, but then I have to use a GET
request and then once again variables are visible and modifiable.


Desired solution:
a PHP script (toPaypal.php, say) that is called when a surfer wants to buy
something for a product for $5 , say.
The Product form will direct to the toPaypal.php script that creates a POST
request and sends the request and the surefer to Paypal.

Any ideas? or did I just make this confusing? One solution I guess is to
just double check the total amount credited to the merchant account matches
the product. But then I ask this question out of curosity.





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




Re: [PHP] printer_open

2003-01-05 Thread Jason Wong
On Tuesday 07 January 2003 05:56, Kathy wrote:
>  Hi, I'm Kathy and just a beginner in php. I'm using the printer_open
> and printer_draw_text etc. to print a report. It works in my localhost, but
> when I run it in a remote server, the error message 'couldn't connect to
> the printer' shown. I think this was caused by no printer was setup in the
> remote server. Can you suggest how I can print to a local printer with the
> programs reside in remote server.

The php printer commands can only control printers attached to the webserver.

If you want finer control over the printed output than what HTML can provide, 
then you can consider creating a PDF file instead.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
It is better to live rich than to die rich.
-- Samuel Johnson
*/


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




Re: [PHP] printer_open

2003-01-05 Thread Leif K-Brooks
PHP is server-side.  You can't do anything to the client besides give 
them data.  This may be possible with javascript (I don't think so, 
though), but not with PHP.

Kathy wrote:

Hi, I'm Kathy and just a beginner in php. I'm using the printer_open and printer_draw_text etc. to print a report. It works in my localhost, but when I run it in a remote server, the error message 'couldn't connect to the printer' shown. I think this was caused by no printer was setup in the remote server. Can you suggest how I can print to a local printer with the programs reside in remote server. 




 


--
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




[PHP] printer_open

2003-01-05 Thread Kathy
 Hi, I'm Kathy and just a beginner in php. I'm using the printer_open and 
printer_draw_text etc. to print a report. It works in my localhost, but when I run it 
in a remote server, the error message 'couldn't connect to the printer' shown. I think 
this was caused by no printer was setup in the remote server. Can you suggest how I 
can print to a local printer with the programs reside in remote server. 
 





Re: [PHP] system()

2003-01-05 Thread Jason Wong
On Monday 06 January 2003 04:20, Richard Baskett wrote:
> When using the system() function, let's say starting up a program, can that
> program start in the background while the rest of the page is parsed or
> does it have to wait until the system command has finished whatever it is
> doing?

If you're using linux or similar you can append an ampersand (&) to your 
command to make it run in the background:

  system('mycommand &');

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
The kernel license has expired
*/


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




Re: [PHP] Zend IDE vs. PhpEd

2003-01-05 Thread John Wells
Sterling,

Thanks for the reply.  I'm also impressed with Zend's autocompletion...I
can't even get PHPEd to autocomplete on objects.

I wonder if Zend uses dbg as well.  It'd be nice to see a profiler thrown
into a future version.

Finally, one frustrating thing on the part of both editors is the
inability to autocomplete on arrays of object references...but I suppose
that's a little difficult with a dynamically typed language.

Thanks!

John




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




Re: [PHP] Zend IDE vs. PhpEd

2003-01-05 Thread Sterling Hughes
> Can anyone who's familiar with both give an honest, open evaluation?  I'm
> in a rush project and need something quickly (have to purchase tomorrow),
> but I'm on the fence when it comes to these two products.
> 
> Zend costs $100 less than Phped, so I'm leaning that way.  But if there's
> anything you know that could make my decision easier, please forward it
> on.  They seem pretty comparable, with the exception of PhpEd's db
> browser.
> 

I personally recommend the Zend IDE, simply because:

1) Its (more) cross platform
2) A more complete autocompletion.  Uses javadoc style documentation to generate
function prototypes for which you can then use autocompletion.  It also resolves
classes and objects.
3) Richer debugger
4) Better integration with other Zend products, if you want to use the encoder, 
it plugs right into the Zend IDE.
5) I like working with it more, and that's what it all comes down too.  The Zend
IDE is what I'm more comfortable with (outside of vim and emacs, which I must admit
are my primary development tools).

-Sterling


> Thanks!
> 
> John
> 
> 
> 
> -- 
> 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] Combine sockets and Header()

2003-01-05 Thread Bobby Patel
Hello, I want to emulate a POST request to Paypal. Originally a POST request
is sent from the user (through a form) and the user is redirected to
paypal's site. Now, what I want to do is to emulate a POST request (so that
the surfer can't see some of the hidden fields of the form) and to deter
tampering. (If they could see all the fields, they could just create their
own form , and just change the amount).

Possible solution:
fsockopen to emulate POST, but that doesn;t redirect the user,  using header
will direct the user to the paypal site, but then I have to use a GET
request and then once again variables are visible and modifiable.


Desired solution:
a PHP script (toPaypal.php, say) that is called when a surfer wants to buy
something for a product for $5 , say.
The Product form will direct to the toPaypal.php script that creates a POST
request and sends the request and the surefer to Paypal.

Any ideas? or did I just make this confusing? One solution I guess is to
just double check the total amount credited to the merchant account matches
the product. But then I ask this question out of curosity.



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




[PHP] Zend IDE vs. PhpEd

2003-01-05 Thread John Wells
Can anyone who's familiar with both give an honest, open evaluation?  I'm
in a rush project and need something quickly (have to purchase tomorrow),
but I'm on the fence when it comes to these two products.

Zend costs $100 less than Phped, so I'm leaning that way.  But if there's
anything you know that could make my decision easier, please forward it
on.  They seem pretty comparable, with the exception of PhpEd's db
browser.

Thanks!

John



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




[PHP] Re: Pass Variables

2003-01-05 Thread Greg Beaver
Use sessions, you can save the result of the previous form in a server-side
variable, and it will still be there even if the user has a modem
disconnect.

http://php.net/session

Take care,
Greg
--
phpDocumentor
http://www.phpdoc.org

"Stephen" <[EMAIL PROTECTED]> wrote in message
000b01c2b518$d8e4a1a0$0200a8c0@melchior">news:000b01c2b518$d8e4a1a0$0200a8c0@melchior...
I want to make a function that passes all the variables in a form to the
next form since the form has multiple steps. I thought about putting all the
contents in an array but I'd have to name out each array which would take a
while and then there's the global inside the function, but again, I'd have
to list all of them out. Any other quick and simple way?

Thanks,
Stephen Craton
http://www.melchior.us

"What's the point in appearance if your true love, doesn't care about
it?" -- http://www.melchior.us



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




[PHP] Re: undocumented OOP feature/bug?

2003-01-05 Thread Greg Beaver
Use get_class($this)

function Go()
{
if (!isset($this))
{
echo 'Called Statically';
}
   switch(get_class($this))
  { // note get_class is lowercase (which I think is a bug, but it hasn't
changed, so oh well)
 'a' : echo 'Called Dynamically';
 'b' : echo 'Called Statically';
   }
}

or, is_a() to include descendants (PHP 4.2.0+ I think)

function Go()
{
if (!isset($this))
{
echo 'Called Statically';
}
   if (is_a($this,'a'))
  {
  echo 'Called Dynamically';
   } else
   {
  echo 'Called Statically';
   }
}

Incidentally, this ability to call other methods and operate on your own
variables is in my opinion the greatest feature of PHP along with
aggregation.  It allows dynamic (runtime!) multiple inheritance, which is
essential for the new version of a complex data-access project I'm working
on constantly (http://calendar.chiaraquartet.net)

Take care,
Greg
--
phpDocumentor
http://www.phpdoc.org

"Sean Malloy" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Consider the following code...
>
> class A
> {
>   function Go()
>   {
> switch (isset($this))
> {
>   case true: echo 'Called Dynamically'; break;
>   case false: echo 'Called Statically'; break;
> }
>   }
> }
>
> class B
> {
>   function Go()
>   {
> A::Go();
>   }
> }
>
> A::Go();
> $a = new A();
> $a->Go();
>
> B::Go();
> $b = new B();
> $b->Go();
>
>
> My understanding is that the output should be:
>
> Called Statically
> Called Dynamically
> Called Statically
> Called Statically
>
> Yet the output is actually:
>
> Called Statically
> Called Dynamically
> Called Statically
> Called Dynamically
>
>
> Now my question is, is this what was intended?
>
> It seems that if you call a static class from within a dynamic instance of
a
> class, the static class then decides $this should reference the class from
> which the static class was called
>
> Anyone else come across this?
>
> It could be useful, but right now, its bloody annoying! I need a class to
be
> called from within another clas, and it needs to know wether it has had an
> instance created, or wether it is being statically called, and now I'll
have
> to write some kludge code instead...
>
>
>
>
> ///
> // Sean Malloy
> // Developer
> // element
> // t: +61 3 9510 
> // f: +61 3 9510 7755
> // m: 0413 383 683
> ///
>
> DISCLAIMER:
> © copyright protected element digital pty ltd 2002.
> the information contained herein is the intellectual property
> of element digital pty ltd and may contain confidential material.
> you must not disclose, reproduce, copy, or use this information
> in any way unless authorised by element digital pty ltd in writing
> or except as permitted by any applicable laws including the
> copyright act 1968 (cth).
>



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




Re: [PHP] Web Based PHP CVS

2003-01-05 Thread Sterling Hughes
> 
> Does anyone know of any decent PHP/Web front ends to CVS?
>

check out chora.

-sterling


> Thanks
> Mike
> 
> 
> P.S. Still looking for a good Linux SysAdmin Mail list.
> I don't understand Romanian but thanks for the answer!  :-)
> 
> 
> 
> 
> 
> -- 
> 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] Web Based PHP CVS

2003-01-05 Thread Michael J. Pawlowsky

Does anyone know of any decent PHP/Web front ends to CVS?

Thanks
Mike


P.S. Still looking for a good Linux SysAdmin Mail list.
I don't understand Romanian but thanks for the answer!  :-)





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




Re: [PHP] Passing Query_String or variables through multiplepages?

2003-01-05 Thread Justin French
get your entire query string (eg key1=val1&key2=val2&key3=val3),
base64encode() it, pass it through to the next page via get as a var (eg
href="page.php?ref=">, the
base64decode() it on the next page... I use this HEAPS.

Justin


on 06/01/03 1:12 PM, Noel Wade ([EMAIL PROTECTED]) wrote:

> Hi all,
> 
> I have an issue I'm hoping there's a simple answer for (I'm betting there
> is):
> 
> I have a dynamic page where the user may click on a link - this link
> processes their data and shows them a "result" page...
> 
> Then I want a variable (for a manual hypertext link) that contains the
> original URL they were viewing.  The problem is, the original page / URL
> needs a query string (i.e. "?key1=val1&key2=val2&key3=val3...").
> 
> So I have to somehow pass their original query string THROUGH the "result
> page" via a GET, and without using a  (using a POST form I could do
> it)...  I've looked at manually copying and "forwarding" each original
> variable by including it in the URL for the "result page"; but I was hoping
> for something more elegant and flexible...
> 
> Any thoughts or ideas?
> 
> Thanks a bunch in advance!  Take care,
> 
> --Noel
> 
> 
> 


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




[PHP] Passing Query_String or variables through multiple pages?

2003-01-05 Thread Noel Wade
Hi all,

I have an issue I'm hoping there's a simple answer for (I'm betting there
is):

I have a dynamic page where the user may click on a link - this link
processes their data and shows them a "result" page...

Then I want a variable (for a manual hypertext link) that contains the
original URL they were viewing.  The problem is, the original page / URL
needs a query string (i.e. "?key1=val1&key2=val2&key3=val3...").

So I have to somehow pass their original query string THROUGH the "result
page" via a GET, and without using a  (using a POST form I could do
it)...  I've looked at manually copying and "forwarding" each original
variable by including it in the URL for the "result page"; but I was hoping
for something more elegant and flexible...

Any thoughts or ideas?

Thanks a bunch in advance!  Take care,

--Noel




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




RE: [PHP] locally enabling register_globals?

2003-01-05 Thread Daevid Vincent
This might help... Put this at the top of each page:

reset ($_POST);
while (list ($key, $val) = each ($_POST)) {
//echo "$key => $val\n";
$$key = $val;
}

You could do the same for $_GET if you need to as well.

DÆVID.

> -Original Message-
> From: Michael Greenspon [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, January 03, 2003 5:51 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] locally enabling register_globals?
> 
> 
> Thanks. This is what we've chosen to do-- 'fix' the code.
> Unfortunately this was all written 'old style' by novices, so 'fixing'
> it by putting in references to $_GET, $_POST etc. doesn't really lend
> any clarity to it. Values are still splayed out across multiple pages
> with no structure. But at least it works now. Still uncertain why the
> php_flag in htaccess didn't do it-- perhaps not enabled with Apache.
> Cheers
> M.
> 
> 
> "Michael J. Pawlowsky" wrote:
> > 
> > Why not just fix your code?
> > 
> > *** REPLY SEPARATOR  ***
> > 
> > On 03/01/2003 at 2:50 PM Michael Greenspon wrote:
> > 
> > >Our hosting provider installed PHP 4.2 and thus disabled
> > >register_globals by default which our scripts depend on. 
> We don't have
> > >access to php.ini to change this. This is with Apache. I 
> tried putting
> > >
> > >php_flags register_globals on
> > >
> > >into .htaccess in the directory(s) with pages that need 
> this but it does
> > >not seem to work. How can I enable register_globals 
> selectively for some
> > >directories of pages so that our old scripts work again?
> > >
> > >Thanks
> > >Michael
> > >
> > >--
> > >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




Re: [PHP] Pass Variables

2003-01-05 Thread Stephen
Oh yeah, forgot that the $_POST variable was an actual array already...
Thanks!


- Original Message -
From: "Justin French" <[EMAIL PROTECTED]>
To: "Stephen" <[EMAIL PROTECTED]>
Sent: Sunday, January 05, 2003 7:56 PM
Subject: Re: [PHP] Pass Variables


: Assuming php > 4.1, on the script that accepts the first form's submitted
: content, you want to loop through the POST variables, and include them as
: hidden INPUTs on the second form
:
: 
: 
:  $value)
: {
: echo "\n";
: }
: ?>
: 
: Your shoe size: 
: 
:
: Totally untested code (never had to do a multi-page form!!), but in
theory,
: you've got a heap of POST items in an array from the first form... all you
: need to do is include them in the second form as hidden fields, and
they'll
: become part of the second form.
:
:
: Have fun,
:
: Justin
:
:
: on 06/01/03 11:16 AM, Stephen ([EMAIL PROTECTED]) wrote:
:
: > I want to make a function that passes all the variables in a form to the
next
: > form since the form has multiple steps. I thought about putting all the
: > contents in an array but I'd have to name out each array which would
take a
: > while and then there's the global inside the function, but again, I'd
have to
: > list all of them out. Any other quick and simple way?
: >
: > Thanks,
: > Stephen Craton
: > http://www.melchior.us
: >
: > "What's the point in appearance if your true love, doesn't care about
it?" --
: > http://www.melchior.us
:
:
:



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




Re: FW: [PHP] How to get the mail sending stuff to work on Win2k?

2003-01-05 Thread Manuel Lemos
Hello,

On 01/05/2003 10:37 PM, Rad Craig wrote:

I run ArgoSoft's mail server which has worked great.  I use SMTP
authentication, could that be the problem?

Is there a way to setup the info for SMTP authentication in PHP so it can
pass it to the mail server during it's sendmail type functions?


No, PHP mail() function does not support authentication. You may want to 
try this class that comes with a wrapper function named smtp_mail() that 
 emulates the mail() function by sending the message via SMTP. It les 
you configure the authentication credentials among other things that the 
mail() function does not support:

http://www.phpclasses.org/mimemessage

To send via SMTP you also need this:

http://www.phpclasses.org/smtpclass


--

Regards,
Manuel Lemos


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



RE: [PHP] How to get the mail sending stuff to work on Win2k?

2003-01-05 Thread Rad Craig
I just turned PHP authentication off and it didn't make any difference,
still didn't receive any email from PHP.

Rad...

> -Original Message-
> From: Rad Craig [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, January 05, 2003 6:37 PM
> To: PHP Mailing List
> Subject: FW: [PHP] How to get the mail sending stuff to work on Win2k?
>
>
> I run ArgoSoft's mail server which has worked great.  I use SMTP
> authentication, could that be the problem?
>
> Is there a way to setup the info for SMTP authentication in PHP so it can
> pass it to the mail server during it's sendmail type functions?
>
> Rad...
>
> > -Original Message-
> > From: Andrew Brampton [mailto:[EMAIL PROTECTED]]
> > Sent: Sunday, January 05, 2003 6:22 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [PHP] How to get the mail sending stuff to work on Win2k?
> >
> >
> > Sorry I misread that you had a local mail server...
> >
> > Well I use ISP mail server for my PHP and it works fine, so there
> > is no need
> > to install any extras ie sendmail etc...
> >
> > I can only suggest that your mail server doesn't like
> forwarding mail for
> > PHP, maybe it takes the wrong way to it or something... If you
> > got any smtp
> > logs have a read to see if you see anything. If its IIS SMTP server I
> > beleive they are stored in c:\winnt\system32\Logfiles\\blah.log.
> >
> > Also to reload the php settings you just have to restart IIS.
> >
> > Hope this helps
> > Andrew
> > - Original Message -
> > From: "Rad Craig" <[EMAIL PROTECTED]>
> > To: "Andrew Brampton" <[EMAIL PROTECTED]>
> > Sent: Monday, January 06, 2003 12:20 AM
> > Subject: RE: [PHP] How to get the mail sending stuff to work on Win2k?
> >
> >
> > > I have an email server installed on that machine.  Mail server works
> > great,
> > > has been for many months.
> > >
> > > I have tested it via PHP using this code:
> > >
> > > 
> > >
> > > But it doesn't work.  I never get an email.
> > >
> > > I've tried:
> > > SMTP = localhost
> > > SMTP = 127.0.0.1
> > > SMTP = mail.mydomain.com
> > >
> > > None work.
> > >
> > > Rad...
> > >
> > > > -Original Message-
> > > > From: Andrew Brampton [mailto:[EMAIL PROTECTED]]
> > > > Sent: Sunday, January 05, 2003 6:12 PM
> > > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> > > > Subject: Re: [PHP] How to get the mail sending stuff to
> work on Win2k?
> > > >
> > > >
> > > > change that line to your ISPs email server.
> > > > OR install a email server locally
> > > >
> > > > Andrew
> > > > - Original Message -
> > > > From: "Rad Craig" <[EMAIL PROTECTED]>
> > > > To: "PHP Mailing List" <[EMAIL PROTECTED]>
> > > > Sent: Sunday, January 05, 2003 11:20 PM
> > > > Subject: [PHP] How to get the mail sending stuff to work on Win2k?
> > > >
> > > >
> > > > > I have a fresh install of PHP on a Win2k server.  It is installed
> > along
> > > > with
> > > > > MySQL to allow me to run and XMB message base on my website.
> > > > >
> > > > > Everything works great except for the fact that I never receive
> > > > any email
> > > > > notification when someone replies to a message I (or anyone else)
> > posts.
> > > > I
> > > > > think the problem is that I don't have the email part of PHP
> > configured
> > > > > correctly.
> > > > >
> > > > > I used the php.ini-recommended file to set it up.  In the mail
> > > > section it
> > > > > says:
> > > > >
> > > > > SMTP=localhost
> > > > >
> > > > > There is a mail server on the local host.
> > > > >
> > > > > Do I have to install a sendmail app to get this working correctly?
> > > > >
> > > > > Nothing shows up in the event logs.
> > > > >
> > > > > One more question, when I make a change to that ini file,
> > do I have to
> > > > > reboot the machine or just restart IIS?
> > > > > 
> > > > > Rad Craig
> > > > > 
> > > > > Rad Craig
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > 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 General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




FW: [PHP] How to get the mail sending stuff to work on Win2k?

2003-01-05 Thread Rad Craig
I run ArgoSoft's mail server which has worked great.  I use SMTP
authentication, could that be the problem?

Is there a way to setup the info for SMTP authentication in PHP so it can
pass it to the mail server during it's sendmail type functions?

Rad...

> -Original Message-
> From: Andrew Brampton [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, January 05, 2003 6:22 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] How to get the mail sending stuff to work on Win2k?
>
>
> Sorry I misread that you had a local mail server...
>
> Well I use ISP mail server for my PHP and it works fine, so there
> is no need
> to install any extras ie sendmail etc...
>
> I can only suggest that your mail server doesn't like forwarding mail for
> PHP, maybe it takes the wrong way to it or something... If you
> got any smtp
> logs have a read to see if you see anything. If its IIS SMTP server I
> beleive they are stored in c:\winnt\system32\Logfiles\\blah.log.
>
> Also to reload the php settings you just have to restart IIS.
>
> Hope this helps
> Andrew
> - Original Message -
> From: "Rad Craig" <[EMAIL PROTECTED]>
> To: "Andrew Brampton" <[EMAIL PROTECTED]>
> Sent: Monday, January 06, 2003 12:20 AM
> Subject: RE: [PHP] How to get the mail sending stuff to work on Win2k?
>
>
> > I have an email server installed on that machine.  Mail server works
> great,
> > has been for many months.
> >
> > I have tested it via PHP using this code:
> >
> > 
> >
> > But it doesn't work.  I never get an email.
> >
> > I've tried:
> > SMTP = localhost
> > SMTP = 127.0.0.1
> > SMTP = mail.mydomain.com
> >
> > None work.
> >
> > Rad...
> >
> > > -Original Message-
> > > From: Andrew Brampton [mailto:[EMAIL PROTECTED]]
> > > Sent: Sunday, January 05, 2003 6:12 PM
> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> > > Subject: Re: [PHP] How to get the mail sending stuff to work on Win2k?
> > >
> > >
> > > change that line to your ISPs email server.
> > > OR install a email server locally
> > >
> > > Andrew
> > > - Original Message -
> > > From: "Rad Craig" <[EMAIL PROTECTED]>
> > > To: "PHP Mailing List" <[EMAIL PROTECTED]>
> > > Sent: Sunday, January 05, 2003 11:20 PM
> > > Subject: [PHP] How to get the mail sending stuff to work on Win2k?
> > >
> > >
> > > > I have a fresh install of PHP on a Win2k server.  It is installed
> along
> > > with
> > > > MySQL to allow me to run and XMB message base on my website.
> > > >
> > > > Everything works great except for the fact that I never receive
> > > any email
> > > > notification when someone replies to a message I (or anyone else)
> posts.
> > > I
> > > > think the problem is that I don't have the email part of PHP
> configured
> > > > correctly.
> > > >
> > > > I used the php.ini-recommended file to set it up.  In the mail
> > > section it
> > > > says:
> > > >
> > > > SMTP=localhost
> > > >
> > > > There is a mail server on the local host.
> > > >
> > > > Do I have to install a sendmail app to get this working correctly?
> > > >
> > > > Nothing shows up in the event logs.
> > > >
> > > > One more question, when I make a change to that ini file,
> do I have to
> > > > reboot the machine or just restart IIS?
> > > > 
> > > > Rad Craig
> > > > 
> > > > Rad Craig
> > > >
> > > >
> > > >
> > > > --
> > > > 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] Pass Variables

2003-01-05 Thread Stephen



I want to make a function that passes all the variables in a 
form to the next form since the form has multiple steps. I thought about putting 
all the contents in an array but I'd have to name out each array which would 
take a while and then there's the global inside the function, but again, I'd 
have to list all of them out. Any other quick and simple way?
Thanks,Stephen Cratonhttp://www.melchior.us
 
"What's the point in appearance if your true love, doesn't care about it?" 
-- http://www.melchior.us
-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] How to get the mail sending stuff to work on Win2k?

2003-01-05 Thread Andrew Brampton
change that line to your ISPs email server.
OR install a email server locally

Andrew
- Original Message -
From: "Rad Craig" <[EMAIL PROTECTED]>
To: "PHP Mailing List" <[EMAIL PROTECTED]>
Sent: Sunday, January 05, 2003 11:20 PM
Subject: [PHP] How to get the mail sending stuff to work on Win2k?


> I have a fresh install of PHP on a Win2k server.  It is installed along
with
> MySQL to allow me to run and XMB message base on my website.
>
> Everything works great except for the fact that I never receive any email
> notification when someone replies to a message I (or anyone else) posts.
I
> think the problem is that I don't have the email part of PHP configured
> correctly.
>
> I used the php.ini-recommended file to set it up.  In the mail section it
> says:
>
> SMTP=localhost
>
> There is a mail server on the local host.
>
> Do I have to install a sendmail app to get this working correctly?
>
> Nothing shows up in the event logs.
>
> One more question, when I make a change to that ini file, do I have to
> reboot the machine or just restart IIS?
> 
> Rad Craig
> 
> Rad Craig
>
>
>
> --
> 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] array help please

2003-01-05 Thread David Freeman

 > $mysql query1
 > result
 > array[cityid][cityname]
 >
 > mysql query2
 > result
 > array[cityid][cityname]
 >
 > now what i want to do is kick out any doubles in my array
 > and resort them alphebetically by cityname ?!

It's difficult to answer this question without knowing more about the
context and the way you have your database laid out.

In any event, sorting stuff and getting removing duplicates is probably
better achieved in your mysql query than in php.

Something like this would get you close (you'll have to figure it out
for your database as you didn't give much to go on)...

SELECT cityid, DISTINCE(cityname) FROM my_table WHERE some = 'condition'
ORDER BY cityname

Basically, use DISTINCT() to remove duplicates and use ORDER BY to set
the display order.

CYA, Dave




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




Re: [PHP] Unexpected $end error?

2003-01-05 Thread Michael J. Pawlowsky
look at your loop.  you have mis matched  which starts one


*** REPLY SEPARATOR  ***

On 05/01/2003 at 5:56 PM Vincent Bouret wrote:

>Can someone tell me why I keep getting that error:
>
>Parse error: parse error, unexpected $end in D:\Program Files\Apache
>Group\Apache2\htdocs\proxy\acc_new.php on line 62
>
>line 62 refers to 
>
>Thanks for your help
>
>Vincent
>



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




[PHP] How to get the mail sending stuff to work on Win2k?

2003-01-05 Thread Rad Craig
I have a fresh install of PHP on a Win2k server.  It is installed along with
MySQL to allow me to run and XMB message base on my website.

Everything works great except for the fact that I never receive any email
notification when someone replies to a message I (or anyone else) posts.  I
think the problem is that I don't have the email part of PHP configured
correctly.

I used the php.ini-recommended file to set it up.  In the mail section it
says:

SMTP=localhost

There is a mail server on the local host.

Do I have to install a sendmail app to get this working correctly?

Nothing shows up in the event logs.

One more question, when I make a change to that ini file, do I have to
reboot the machine or just restart IIS?

Rad Craig

Rad Craig



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




Fw: [PHP] Unexpected $end error?

2003-01-05 Thread Rick Emery
When you get an error that points to , it means you did not close a {} or ""

In this case, you did not close the:   if ($row = mysql_fetch_array($result)) {

Although you did close the "while do {}" immediately thereafter.

- Original Message - 
From: "Vincent Bouret" <[EMAIL PROTECTED]>
To: <>
Sent: Sunday, January 05, 2003 4:56 PM
Subject: [PHP] Unexpected $end error?


Can someone tell me why I keep getting that error:

Parse error: parse error, unexpected $end in D:\Program Files\Apache
Group\Apache2\htdocs\proxy\acc_new.php on line 62

line 62 refers to 

Thanks for your help

Vincent

Here is the content of acc_new.php




Account Management Tools - Add a new account





Accounts Management Tools
Add a new account

Username:
  

  Password:

Must contain between 4 and 20 characters.
  Firstname:

  
  Lastname:

  
  Email address:

  
  Usergroup:
  
  

  
   
   

  

  



Back to Account Management Tools




and here is the content of auth.php



and mysql.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




Re: [PHP] Unexpected $end error?

2003-01-05 Thread Tom Rogers
Hi,

Monday, January 6, 2003, 8:56:58 AM, you wrote:
VB> Can someone tell me why I keep getting that error:

VB> Parse error: parse error, unexpected $end in D:\Program Files\Apache
VB> Group\Apache2\htdocs\proxy\acc_new.php on line 62

VB> line 62 refers to 

VB> Thanks for your help

VB> Vincent

VB> Here is the content of acc_new.php

VB>  //MUST declare $page_class to specify the level of authentication required
VB> $page_class = "account";

VB> include('auth.php');

VB> include('mysql.php');

?>>
VB> 
VB> 
VB> Account Management Tools - Add a new account
VB> 
VB> 
VB> 

VB> 
VB> Accounts Management Tools
VB> Add a new account
VB> 
VB> Username:
VB>   
VB> 
VB>   Password:
VB>  size="25" maxlength="20">
VB> Must contain between 4 and 20 characters.
VB>   Firstname:
VB>  size="25" maxlength="50">
VB>   
VB>   Lastname:
VB>  size="25" maxlength="50">
VB>   
VB>   Email address:
VB> >
VB>   
VB>   Usergroup:
VB>   
VB>  //Fetch list of groups
VB>$result = mysql_query("SELECT id, name FROM tblUserGroups", $db);
VB>  $row = mysql_fetch_array($result);
VB>  if ($row = mysql_fetch_array($result)) {
VB>   do {
VB>   ?>
VB> >
VB>  } while($row = mysql_fetch_array($result));
VB>   ?>
VB>
VB>

VB>   
VB> >
VB>   

VB> 

VB> Back to Account Management Tools

VB> 
VB> 

VB> and here is the content of auth.php

VB>  //some code working with every other pages

?>>

VB> and mysql.php

VB>  //mysql.php Include file initializing connection to db
VB>  $db = mysql_connect(dbinfo goes here);
VB>  mysql_select_db("proxy_db", $db);

?>>

That happens if you have mismatched braces {} or if(): endif; etc

-- 
regards,
Tom


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




[PHP] Unexpected $end error?

2003-01-05 Thread Vincent Bouret
Can someone tell me why I keep getting that error:

Parse error: parse error, unexpected $end in D:\Program Files\Apache
Group\Apache2\htdocs\proxy\acc_new.php on line 62

line 62 refers to 

Thanks for your help

Vincent

Here is the content of acc_new.php




Account Management Tools - Add a new account





Accounts Management Tools
Add a new account

Username:
  

  Password:

Must contain between 4 and 20 characters.
  Firstname:

  
  Lastname:

  
  Email address:

  
  Usergroup:
  
  

  
   
   

  

  



Back to Account Management Tools




and here is the content of auth.php



and mysql.php





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




[PHP] Good Linux Admin Mail List

2003-01-05 Thread Michael J. Pawlowsky

Perhaps a weird place to ask.. but, anyone have a really good (advanced without to 
many newbie questions) Linux System Administrators Mail List?

Thanks,
Mike




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




RE: [PHP] Re: PHP and MySQL bug

2003-01-05 Thread David Freeman

 > @MYSQL_QUERY("UPDATE d SET h='$h' WHERE id='$id'"); // this
 > query doesn't work

Personally, I'd call it bad programming practice to do a database update
and not check to see if it worked or not.  In this case, how are you
determining that the query did not work?  Are you manually checking the
database?  You don't have anything in your code to check the status of
this query.

Perhaps this might get you somewhere:

$qid = @mysql_query("UPDATE d SET h = '$h' WHERE id = '$id'");

if (isset($qid) && mysql_affected_rows() == 1)
{
  echo "query executed";
} else {
  echo "query failed: " . mysql_error();
}

At least this way you might get some indication of where the problem is.

CYA, Dave




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




Re: [PHP] Re: security in guest book and user forums

2003-01-05 Thread Justin French
on 05/01/03 11:54 PM, Jurre Thiel ([EMAIL PROTECTED]) wrote:

> The bad side of this that all other HTML tags than  and  will be
> removed.

So add some more tags!!  Gz!  Which would you prefer?  Pretty colours
and bold text, or a page full of unclosed tags, evil javascripts, and other
harmfull markup?

Let me know where your message board / guestbook's are on the web, and i'll
wrap a 



tag around my whole post... as soon as someone mouses over my guestbook
post, the window will close down :)


Justin French


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




[PHP] Advanced PHP Debugger

2003-01-05 Thread Fredrik Johansson
 Hi,

If someone out there has an .dll file for the Advanced PHP Debugger 
(APD) extension to run i Windows 2000 (PHP version 4.2.2) I would be 
glad if you could send it to me. I have tried to compile one myself but 
has failed each and every time :(

Regards,
Fredrik Johansson



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



php-general Digest 5 Jan 2003 21:27:01 -0000 Issue 1805

2003-01-05 Thread php-general-digest-help

php-general Digest 5 Jan 2003 21:27:01 - Issue 1805

Topics (messages 130302 through 130336):

Re: PHP and MySQL bug
130302 by: Nuno Lopes

array help please
130303 by: John Fishworld
130304 by: David T-G

undefining an array element
130305 by: David T-G
130308 by: Tom Rogers
130309 by: David T-G

'php_network_getaddresses'
130306 by: zzori

undocumented OOP feature/bug?
130307 by: Sean Malloy
130313 by: Jurre Thiel

php_admin values in httpd.conf
130310 by: Jochen Kaechelin
130311 by: Jurre Thiel
130327 by: Jason Wong

Re: security in guest book and user forums
130312 by: Jurre Thiel

Re: Perl > PHP
130314 by: Jurre Thiel
130318 by: Marek Kilimajer
130321 by: Jurre Thiel
130323 by: Mark Charette

Re: counter problem
130315 by: Anthony Ritter

Re: File Modification Date/Time
130316 by: Marek Kilimajer

Re: please help me, y have a error
130317 by: Marek Kilimajer

JPgraph Font Problems
130319 by: Alexandre Soares

[announce] AtomicBoard v0.6.1
130320 by: Vincent Vollers

web reload
130322 by: TACKEL
130325 by: Marek Kilimajer
130326 by: Jason Sheets
130329 by: Marek Kilimajer

Mysql update problems
130324 by: Jesse Lawrence
130328 by: Rick Emery
130330 by: Jason Wong
130331 by: Jesse Lawrence
130332 by: Rick Emery

.doc parsing class or function?
130333 by: James Brennan
130335 by: Sean Burlington

system()
130334 by: Richard Baskett

Re: php4.3.0 & GD library
130336 by: Philip Olson

Administrivia:

To subscribe to the digest, e-mail:
[EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]

To post to the list, e-mail:
[EMAIL PROTECTED]


--

--- Begin Message ---
Here is the source code:

Seleccione a localização para o download:Localização Principal";
if ($mirrors) {
echo " Mirrors";
$m=explode("»",$mirrors);
foreach ($m as $v) {
$m2=explode("!",$v);
echo "$m2[0]";
}
echo "Nota: Deve escolher o mirror mais próximo da sua localização,
para acelerar o dowload. No caso de um mirror estar indisponível, utilize
outro.";
}
}
@MYSQL_CLOSE();
?>



--- End Message ---
--- Begin Message ---
can someone give me a bit of help / walthrough the following for me !
this first bits is okay
$mysql query1
result
array[cityid][cityname]

mysql query2
result
array[cityid][cityname]

now what i want to do is kick out any doubles in my array and resort them
alphebetically by cityname ?!


help !



--- End Message ---
--- Begin Message ---
John, et al --

...and then John Fishworld said...
% 
% can someone give me a bit of help / walthrough the following for me !

Let's see if I can help.


% this first bits is okay
% $mysql query1
% result
% array[cityid][cityname]
% 
% mysql query2
% result
% array[cityid][cityname]

Are CityIDs unique, like US-GA-ATL and CN-QC-MON or 214365 and 214387, or
is duplication possible?  If the IDs are unique then adding duplicates
won't cause duplicate entries.


% 
% now what i want to do is kick out any doubles in my array and resort them
% alphebetically by cityname ?!

Check out array_merge and array_multisort to put the two together and
sort on the second key, respectively.


% 
% 
% help !


HTH & HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg91679/pgp0.pgp
Description: PGP signature
--- End Message ---
--- Begin Message ---
Hi, all --

If I have an array like

  $a1 = array ( 'a' => 'aaa' , 'b' => 'bbb' , 'c' => 'ccc' ) ;

and I want to completely remove 'b' from it (not just set $a1[b] to ""),
how do I undefine that element?


TIA & HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg91679/pgp1.pgp
Description: PGP signature
--- End Message ---
--- Begin Message ---
Hi,

Sunday, January 5, 2003, 9:46:05 PM, you wrote:
DTG> Hi, all --

DTG> If I have an array like

DTG>   $a1 = array ( 'a' => 'aaa' , 'b' => 'bbb' , 'c' => 'ccc' ) ;

DTG> and I want to completely remove 'b' from it (not just set $a1[b] to ""),
DTG> how do I undefine that element?


DTG> TIA & HAND

DTG> :-D

unset($a1['b']);

-- 
regards,
Tom


--- End Message ---
--- Begin Message ---
Tom, et al --

...and then Tom Rogers said...
% 
% Hi,

Hi!


% 
% Sunday, January 5, 2003, 9:46:05 PM, you wrote:
% 
...
% DTG> how do I undefine

Re: [PHP] php4.3.0 & GD library

2003-01-05 Thread Philip Olson
On Sun, 5 Jan 2003, thkiat wrote:

> Do you kow how can I upgrade the PHP 4.1.1 in PHPTriad to PHP 4.3.0?
> I need PHP 4.3.0. as it includes a version of gd (GD Library) as "standard
> equipment."

GD is not "standard equipment", a "special" version 
is just bundled in PHP source now.  It sounds like 
you  are  using windows, this bundling has no affect 
on the windows distribution as it included all the 
pre-compiled binaries already, including GD's. In
fact, I bet you already have a GD binary and just
need to uncomment out in your php.ini but anyway
4.1.1 is old so you should upgrade.

Like with any version of PHP you download it and 
follow the install instructions.

  http://www.php.net/downloads

Regards,
Philip


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




Re: [PHP] .doc parsing class or function?

2003-01-05 Thread Sean Burlington
James Brennan wrote:

I'm looking to extract the text from user-uploaded .doc files. Has 
anyone come across a class or function for this? If not, any advice on 
where I would go to figure out how to write one of my own?

thanks,
loop





 search freshmeat.net for antiword

its a beuatiful little command line utility


--

Sean


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




[PHP] system()

2003-01-05 Thread Richard Baskett
When using the system() function, let's say starting up a program, can that
program start in the background while the rest of the page is parsed or does
it have to wait until the system command has finished whatever it is doing?

Rick

"Dost thou love life? Then do not squander time; for that's the stuff life
is made of." - Ben Franklin


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




[PHP] .doc parsing class or function?

2003-01-05 Thread James Brennan
I'm looking to extract the text from user-uploaded .doc files. Has anyone 
come across a class or function for this? If not, any advice on where I 
would go to figure out how to write one of my own?

thanks,
loop



_
STOP MORE SPAM with the new MSN 8 and get 2 months FREE* 
http://join.msn.com/?page=features/junkmail


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



Re: [PHP] Mysql update problems

2003-01-05 Thread Rick Emery
Then the problem is in MYSQL.  to help determine this, ALWAYS--ALWAYS include the "or
die(mysql_error())" as part of the mysql_query():

mysql_db_query ($dbname, $query, $link) or die("Error: cannot read
table$query".mysql_error());

- Original Message -
From: "jesse" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, January 05, 2003 11:50 AM
Subject: Re: [PHP] Mysql update problems


No, the query is working fine... all variables are printing correctly.
This is what has me confused.  Everything seems to be as it should, it's
just not updating the db table.

Rick Emery wrote:
> what appeared when you printed the text of your query:
>  $query = "update bloggers set cache='$blog', title='$title' where url='$address'";
>  print $query;
>
> I'm thinking that your single quotes preventd $blog, $title, $address form being 
>expanded.
> - Original Message -
> From: "Jesse Lawrence" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Sunday, January 05, 2003 10:27 AM
> Subject: [PHP] Mysql update problems
>
>
> I've been scratching my head over the following code
> for a while now.  It's supposed to check a given
> weblog for specific tags, and if they're present,
> update the weblog's table in my database.  I believe
> the problem is around the execution of the db query,
> but I can't seem to get it figured out.
>
> function is_news($address, $blogtitle, $host, $user,
> $pass, $dbname){
>$f = fopen($address, 'r');
>$read = fread($f, 2);
>fclose($f);
>$title_start = strpos($read, "");
>$title_end = strpos($read, "");
>$title = substr($read, $title_start, ($title_end -
> $title_start));
>
>
>$blog_start = strpos($read, "");
>$blog_end = strpos($read, "");
>$blog = substr($read, $blog_start, ($blog_end -
> $blog_start));
>
>$link = mysql_connect($host, $user, $pass)
>  or die("Can't connect to
> database");
>
>   $query = "update bloggers set cache='$blog',
> title='$title' where url='$address'";
>   if(mysql_db_query ($dbname, $query, $link)) {
>  $is_news = 1;
>   }else{
>  $is_news = 0;
>   }
>
>return $is_news;
>
> }
>
> Thanks a million for any help,
>
> Jesse Lawrence
>
>
>
> __
> Post your free ad now! http://personals.yahoo.ca
>


--
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] Mysql update problems

2003-01-05 Thread jesse
No, the query is working fine... all variables are printing correctly. 
This is what has me confused.  Everything seems to be as it should, it's 
just not updating the db table.

Rick Emery wrote:
what appeared when you printed the text of your query:
 $query = "update bloggers set cache='$blog', title='$title' where url='$address'";
 print $query;

I'm thinking that your single quotes preventd $blog, $title, $address form being expanded.
- Original Message - 
From: "Jesse Lawrence" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, January 05, 2003 10:27 AM
Subject: [PHP] Mysql update problems


I've been scratching my head over the following code
for a while now.  It's supposed to check a given
weblog for specific tags, and if they're present,
update the weblog's table in my database.  I believe
the problem is around the execution of the db query,
but I can't seem to get it figured out.

function is_news($address, $blogtitle, $host, $user,
$pass, $dbname){
   $f = fopen($address, 'r');
   $read = fread($f, 2);
   fclose($f);
   $title_start = strpos($read, "");
   $title_end = strpos($read, "");
   $title = substr($read, $title_start, ($title_end -
$title_start));


   $blog_start = strpos($read, "");
   $blog_end = strpos($read, "");
   $blog = substr($read, $blog_start, ($blog_end -
$blog_start));

   $link = mysql_connect($host, $user, $pass) 
 or die("Can't connect to
database");
  
  $query = "update bloggers set cache='$blog',
title='$title' where url='$address'";
  if(mysql_db_query ($dbname, $query, $link)) {
 $is_news = 1; 
  }else{
 $is_news = 0;
  }

   return $is_news;

}

Thanks a million for any help,

Jesse Lawrence



__ 
Post your free ad now! http://personals.yahoo.ca



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




Re: [PHP] Mysql update problems

2003-01-05 Thread Jason Wong
On Monday 06 January 2003 00:27, Jesse Lawrence wrote:
> I've been scratching my head over the following code
> for a while now.  It's supposed to check a given
> weblog for specific tags, and if they're present,
> update the weblog's table in my database.  I believe
> the problem is around the execution of the db query,
> but I can't seem to get it figured out.

[snip]

So that other people don't have to scratch their heads as well could you tell 
us what the problem is?

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
You'll wish that you had done some of the hard things when they were easier
to do.
*/


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




Re: [PHP] web reload

2003-01-05 Thread Marek Kilimajer
Yes, you are right $cookie = $HTTP_COOKIE_VARS["mycookie"]; should be in 
*else* part


Jason Sheets wrote:

This will always assign the value of $HTTP_COOKIE_VARS["mycookie"] to
$cookie, overwriting the $cookie = $form_value assignment which is what
you want if the page is being reloaded but is not what is desired on the
first page load.

Jason

On Sun, 2003-01-05 at 09:50, Marek Kilimajer wrote:
 

TACKEL wrote:

   

Hi,

I have a php file that set up a cookie that receives from a form and also uses it. 
My problem is the first time the value is submitted via form. The cookie is setup 
but I cannot not use it so I'd need to reload the web after setting up the cookie.


Myfile.php

if ($form_value != "0"){

 

// you should use if(isset($form_value)) {

   

  setcookie("mycookie",$form_value,time() + 30660);
  

 

   $cookie=$form_value; // and no need to reload

   

  }
$cookie = $HTTP_COOKIE_VARS["mycookie"];


Any suggestion?

Thanks,
Tackel.





 

--
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] Mysql update problems

2003-01-05 Thread Rick Emery
what appeared when you printed the text of your query:
 $query = "update bloggers set cache='$blog', title='$title' where url='$address'";
 print $query;

I'm thinking that your single quotes preventd $blog, $title, $address form being 
expanded.
- Original Message - 
From: "Jesse Lawrence" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, January 05, 2003 10:27 AM
Subject: [PHP] Mysql update problems


I've been scratching my head over the following code
for a while now.  It's supposed to check a given
weblog for specific tags, and if they're present,
update the weblog's table in my database.  I believe
the problem is around the execution of the db query,
but I can't seem to get it figured out.

function is_news($address, $blogtitle, $host, $user,
$pass, $dbname){
   $f = fopen($address, 'r');
   $read = fread($f, 2);
   fclose($f);
   $title_start = strpos($read, "");
   $title_end = strpos($read, "");
   $title = substr($read, $title_start, ($title_end -
$title_start));


   $blog_start = strpos($read, "");
   $blog_end = strpos($read, "");
   $blog = substr($read, $blog_start, ($blog_end -
$blog_start));

   $link = mysql_connect($host, $user, $pass) 
 or die("Can't connect to
database");
  
  $query = "update bloggers set cache='$blog',
title='$title' where url='$address'";
  if(mysql_db_query ($dbname, $query, $link)) {
 $is_news = 1; 
  }else{
 $is_news = 0;
  }

   return $is_news;

}

Thanks a million for any help,

Jesse Lawrence



__ 
Post your free ad now! http://personals.yahoo.ca

-- 
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] php_admin values in httpd.conf

2003-01-05 Thread Jason Wong
On Sunday 05 January 2003 20:47, Jochen Kaechelin wrote:
> 
>
> > php_admin_flag engine on
> > php_admin_flag log_errors on
> > php_admin_value error_reporting 7
> > php_flag display_errors on
> > php_admin_value doc_root /var/www/ HERE WHAT TO WRITE TO HAVE
>
> 
>
> Where can I find a list of all these php_admin parameters to use in
> Apaches' httpd.conf?

manual > ini_set()

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *

/*
Hideously disfigured by an ancient Indian curse?

WE CAN HELP!

Call (511) 338-0959 for an immediate appointment.
*/


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




Re: [PHP] web reload

2003-01-05 Thread Jason Sheets
You could use a header() with Location: but why do you need to reload
the page?  If you already have your data in $form_value then the data is
already available to you.

If you are using a newer version of PHP (> 4.1) you can reference the
information from the $_COOKIE array as well.

You could do this: 

if ($form_value != "0"){
setcookie("mycookie",$form_value,time() + 30660);
$cookie = $form_value;
} elseif (isset($HTTP_COOKIE_VARS["mycookie"])) {
$cookie = $HTTP_COOKIE_VARS["mycookie"];
}

There are a number of other ways you could do it as well but that should
help you think about it.

Jason

On Sun, 2003-01-05 at 09:12, TACKEL wrote:
> Hi,
> 
> I have a php file that set up a cookie that receives from a form and also uses it. 
> My problem is the first time the value is submitted via form. The cookie is setup 
> but I cannot not use it so I'd need to reload the web after setting up the cookie.
> 
> 
> Myfile.php
> 
> if ($form_value != "0"){
> setcookie("mycookie",$form_value,time() + 30660);
> // Web should be reload here;
> }
> $cookie = $HTTP_COOKIE_VARS["mycookie"];
> 
> 
> Any suggestion?
> 
> Thanks,
> Tackel.
> 
> 
> 
> -- 
> 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] web reload

2003-01-05 Thread Marek Kilimajer


TACKEL wrote:


Hi,

I have a php file that set up a cookie that receives from a form and also uses it. 
My problem is the first time the value is submitted via form. The cookie is setup 
but I cannot not use it so I'd need to reload the web after setting up the cookie.


Myfile.php

if ($form_value != "0"){

// you should use if(isset($form_value)) {


   setcookie("mycookie",$form_value,time() + 30660);
   

   $cookie=$form_value; // and no need to reload


   }
$cookie = $HTTP_COOKIE_VARS["mycookie"];


Any suggestion?

Thanks,
Tackel.



 



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




[PHP] Mysql update problems

2003-01-05 Thread Jesse Lawrence
I've been scratching my head over the following code
for a while now.  It's supposed to check a given
weblog for specific tags, and if they're present,
update the weblog's table in my database.  I believe
the problem is around the execution of the db query,
but I can't seem to get it figured out.

function is_news($address, $blogtitle, $host, $user,
$pass, $dbname){
   $f = fopen($address, 'r');
   $read = fread($f, 2);
   fclose($f);
   $title_start = strpos($read, "");
   $title_end = strpos($read, "");
   $title = substr($read, $title_start, ($title_end -
$title_start));


   $blog_start = strpos($read, "");
   $blog_end = strpos($read, "");
   $blog = substr($read, $blog_start, ($blog_end -
$blog_start));

   $link = mysql_connect($host, $user, $pass) 
 or die("Can't connect to
database");
  
  $query = "update bloggers set cache='$blog',
title='$title' where url='$address'";
  if(mysql_db_query ($dbname, $query, $link)) {
 $is_news = 1; 
  }else{
 $is_news = 0;
  }

   return $is_news;

}

Thanks a million for any help,

Jesse Lawrence



__ 
Post your free ad now! http://personals.yahoo.ca

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




RE: [PHP] Perl > PHP

2003-01-05 Thread Mark Charette
The first line of the script had the magic incantation:

#!/usr/local/bin/perl

(or something very similar) which makes the leading 'perl' superfluous.

PHP scripts can be made into "self executing" scripts in a similar fashion
if the 1st line looks like:

#!/path/to/the/php/command/line/executable

This only applies to Unix and the executable bit must be set.

Mark C.

> -Original Message-
> From: Jurre Thiel [mailto:[EMAIL PROTECTED]]
> Sorry, i didn't think of that. I still think exec('perl
> perl.pl'); does the
> job, not exec('perl.pl');
>>


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




[PHP] web reload

2003-01-05 Thread TACKEL
Hi,

I have a php file that set up a cookie that receives from a form and also uses it. 
My problem is the first time the value is submitted via form. The cookie is setup 
but I cannot not use it so I'd need to reload the web after setting up the cookie.


Myfile.php

if ($form_value != "0"){
setcookie("mycookie",$form_value,time() + 30660);
// Web should be reload here;
}
$cookie = $HTTP_COOKIE_VARS["mycookie"];


Any suggestion?

Thanks,
Tackel.



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




Re: [PHP] Perl > PHP

2003-01-05 Thread Jurre Thiel
Sorry, i didn't think of that. I still think exec('perl perl.pl'); does the
job, not exec('perl.pl');

"Marek Kilimajer" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>
>
> Jurre Thiel wrote:
>
> >That doesn't make any sense and has nothing to do with Perl, since PHP
will
> >magically convert perl.pl to 'perl.pl'.
> >
> I think perl will be magically converted to perl and pl to pl, and those
> two strings concatenated
> together using . inbetween will be perlpl
>
> >
> >
> >
> >
>



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




[PHP] [announce] AtomicBoard v0.6.1

2003-01-05 Thread Vincent Vollers
Hi,

AtomicBoard v0.6.1, an advanced template-based forum system has just been
released. please try it, we need your feedback.

If you are a PHP developer looking for a challenging and fun project, please
have a look at AtomicBoard, we are in need of more developers.

have a look at:
http://cal007300.student.utwente.nl/atomicboard/

cheers,
- Vincent



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




[PHP] JPgraph Font Problems

2003-01-05 Thread Alexandre Soares
Hi All,

So I install the jpgraph in Linux RedHat version 8.0, everything
running ok, except examples need special fonts resource, the message follow
bellow:

"Font File "/usr/X11R6/lib/X11/fonts/truetype/arialbd.ttf is not
readable or does not exist"

This problems occour when I execute the ganttext01.php present in
example directory, I know this directory don't exist in my system, but what
the procedure necessery to make this facility work,


Realy Thanks
Alex



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.427 / Virus Database: 240 - Release Date: 12/6/2002


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




Re: [PHP] Perl > PHP

2003-01-05 Thread Marek Kilimajer


Jurre Thiel wrote:


That doesn't make any sense and has nothing to do with Perl, since PHP will
magically convert perl.pl to 'perl.pl'.


I think perl will be magically converted to perl and pl to pl, and those 
two strings concatenated
together using . inbetween will be perlpl



 



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




Re: [PHP] please help me, y have a error

2003-01-05 Thread Marek Kilimajer
Means php tried to access memory page address it did not have. Try to
find out if it was php itself or a loaded module, then upgrade the 
offending
part and see if it still happens again.

Ysrael Guzmán wrote:

this is the message of the ERROR:


PHP has encountered an Access Violation at 012B7DE7

what this


Ysrael Guzmán Meza



 



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




Re: [PHP] File Modification Date/Time

2003-01-05 Thread Marek Kilimajer
This should be right, $TimeDiff is in seconds.

Christopher J. Crane wrote:


Doyou know how to compare time. I would like to get the difference in time
from now to when the file was last accessed.

I was thinking something like this:

$DirToCheck = "tempdata/";
echo "$Now\n";
$TimeNow = time();
if ($handle = opendir($DirToCheck)) {
   while (false !== ($file = readdir($handle))) {
 $FileTimeUnix = fileatime($DirToCheck . $file);
 $TimeDiff = $TimeNow - $FileTimeUnix;
   echo "  $file - Last accessed: " . date("F d Y H:i:s.",
fileatime($DirToCheck . $file)) . " - $TimeDiff\n";
  if($TimeDiff > 1) { unlink($DirToCheck . $file); }
 $TimeDiff = 0;
}
   closedir($handle);
}
?>

"Marek Kilimajer" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 

you must prepend $DirToCheck to $file:

filemtime($DirToCheck . $file)



Christopher J. Crane wrote:

   

I am trying to parse through a directory and get the modification dates
 

of
 

the file.


$DirToCheck = "tempdata/";
if ($handle = opendir($DirToCheck)) {
  while (false !== ($file = readdir($handle))) {
  echo "  $file - Last Modified: " . date("F d Y H:i:s.",
filemtime($file)) . "\n";
   }
  closedir($handle);
}
?>

All the files are coming back with a date of December 31 1969 19:00:00.
 

What
 

am I doing wrong? The next step is I want to check if the file is older
 

than
 

30 minutes and if so, I want to delete it. How would I go about that?






 




 



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




Re: [PHP] counter problem

2003-01-05 Thread Anthony Ritter
Hi Mike,
I tried the first script you posted on the NG.

This is what happens when I copy and paste your script:

The formbox appears.
I insert a number.
I click submit.
The number reverts back to 0.

The URL script that you sent me works fine.

I'm using MS Win 98/ Apache / PHP 4

Please advise if you get a chance if you know why I can't get this script to
work.
Thank you.
Tony Ritter


---
[This E-mail scanned for viruses by gonefishingguideservice.com]


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




Re: [PHP] Perl > PHP

2003-01-05 Thread Jurre Thiel
That doesn't make any sense and has nothing to do with Perl, since PHP will
magically convert perl.pl to 'perl.pl'. I think you should do something
like:



Assumming you are on an Unix enviroment and Perl is installed.

"Leif K-Brooks" <[EMAIL PROTECTED]> schreef in bericht
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Not good at perl, but you need to do:
> 
>
> Sam wrote:
>
> >I don't know what the heck this is but it works:
> >
> >#!/usr/bin/perl
> >
> >$ENV{LD_LIBRARY_PATH} .=":.:..:../lib";
> >$ENV{CLASSPATH} .= ":Verisign.jar:.";
> >print `javac PFProJava.java`;
> >print `java PFProJava test-payflow.verisignscks.com`;
> >
> >How can it be done with PHP?
> >
> >OR
> >
> >run the perl script from a PHP script.
> >
> >
> >
> >didn't work.
> >
> >Thanks,
> >Sam
> >
> >
> >
> >
>
> --
> 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




[PHP] Re: undocumented OOP feature/bug?

2003-01-05 Thread Jurre Thiel
You could check if a variable in $this exists:

class A
{
var $bla;

function Go()
{
switch(isset($this->bla))
{
case true: echo 'Called Dynamicaly'; break;
case true: echo 'Called Statically'; break;
}
}
}

Or, if that doesn't work, you could do this:

class A
{
var $dynamic = true;

function Go()
{
switch(isset($this->bla) && $this->bla == true)
{
case true: echo 'Called Dynamicaly'; break;
case true: echo 'Called Statically'; break;
}
}
}

Or:

class A
{
var $dynamic;

function A()
{
$this->dynamic = true;
}

function Go()
{
switch(isset($this->bla) && $this->bla == true)
{
case true: echo 'Called Dynamicaly'; break;
case true: echo 'Called Statically'; break;
}
}
}

Just some things you could try.

"Sean Malloy" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Consider the following code...
>
> class A
> {
>   function Go()
>   {
> switch (isset($this))
> {
>   case true: echo 'Called Dynamically'; break;
>   case false: echo 'Called Statically'; break;
> }
>   }
> }
>
> class B
> {
>   function Go()
>   {
> A::Go();
>   }
> }
>
> A::Go();
> $a = new A();
> $a->Go();
>
> B::Go();
> $b = new B();
> $b->Go();
>
>
> My understanding is that the output should be:
>
> Called Statically
> Called Dynamically
> Called Statically
> Called Statically
>
> Yet the output is actually:
>
> Called Statically
> Called Dynamically
> Called Statically
> Called Dynamically
>
>
> Now my question is, is this what was intended?
>
> It seems that if you call a static class from within a dynamic instance of
a
> class, the static class then decides $this should reference the class from
> which the static class was called
>
> Anyone else come across this?
>
> It could be useful, but right now, its bloody annoying! I need a class to
be
> called from within another clas, and it needs to know wether it has had an
> instance created, or wether it is being statically called, and now I'll
have
> to write some kludge code instead...
>
>
>
>
> ///
> // Sean Malloy
> // Developer
> // element
> // t: +61 3 9510 
> // f: +61 3 9510 7755
> // m: 0413 383 683
> ///
>
> DISCLAIMER:
> © copyright protected element digital pty ltd 2002.
> the information contained herein is the intellectual property
> of element digital pty ltd and may contain confidential material.
> you must not disclose, reproduce, copy, or use this information
> in any way unless authorised by element digital pty ltd in writing
> or except as permitted by any applicable laws including the
> copyright act 1968 (cth).
>



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




Re: [PHP] Re: security in guest book and user forums

2003-01-05 Thread Jurre Thiel
The bad side of this that all other HTML tags than  and  will be
removed.

> on 05/01/03 5:24 AM, Seraphim ([EMAIL PROTECTED]) wrote:
>
> > I use the htmlspecialchars() function to disable all html. This function
> > basically puts a '\' in front of eacht html character and thus disables
all
> > html.
> > You may not want to do this if you want to allow, for example  or
> > other friendly html. If so you can use a regex to disable the 

[PHP] Re: php_admin values in httpd.conf

2003-01-05 Thread Jurre Thiel
I think they are just the same as in php.ini.

"Jochen Kaechelin" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> 
> > php_admin_flag engine on
> > php_admin_flag log_errors on
> > php_admin_value error_reporting 7
> > php_flag display_errors on
> > php_admin_value doc_root /var/www/ HERE WHAT TO WRITE TO HAVE
> 
>
> Where can I find a list of all these php_admin parameters to use in
> Apaches' httpd.conf?
> --
> Jochen Kaechelin
>
> [EMAIL PROTECTED]
>



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




[PHP] php_admin values in httpd.conf

2003-01-05 Thread Jochen Kaechelin

> php_admin_flag engine on
> php_admin_flag log_errors on
> php_admin_value error_reporting 7
> php_flag display_errors on
> php_admin_value doc_root /var/www/ HERE WHAT TO WRITE TO HAVE


Where can I find a list of all these php_admin parameters to use in
Apaches' httpd.conf?
-- 
Jochen Kaechelin

[EMAIL PROTECTED]


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




Re: [PHP] undefining an array element

2003-01-05 Thread David T-G
Tom, et al --

...and then Tom Rogers said...
% 
% Hi,

Hi!


% 
% Sunday, January 5, 2003, 9:46:05 PM, you wrote:
% 
...
% DTG> how do I undefine that element?
% 
% unset($a1['b']);

Ah!  And here I was looking for 'undefine' (and boy o boy are there a lot
of occurrences of *that* in the manual!).


% 
% -- 
% regards,
% Tom


Thanks a bunch! & HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg91651/pgp0.pgp
Description: PGP signature


Re: [PHP] undefining an array element

2003-01-05 Thread Tom Rogers
Hi,

Sunday, January 5, 2003, 9:46:05 PM, you wrote:
DTG> Hi, all --

DTG> If I have an array like

DTG>   $a1 = array ( 'a' => 'aaa' , 'b' => 'bbb' , 'c' => 'ccc' ) ;

DTG> and I want to completely remove 'b' from it (not just set $a1[b] to ""),
DTG> how do I undefine that element?


DTG> TIA & HAND

DTG> :-D

unset($a1['b']);

-- 
regards,
Tom


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




[PHP] undocumented OOP feature/bug?

2003-01-05 Thread Sean Malloy
Consider the following code...

class A
{
  function Go()
  {
switch (isset($this))
{
  case true: echo 'Called Dynamically'; break;
  case false: echo 'Called Statically'; break;
}
  }
}

class B
{
  function Go()
  {
A::Go();
  }
}

A::Go();
$a = new A();
$a->Go();

B::Go();
$b = new B();
$b->Go();


My understanding is that the output should be:

Called Statically
Called Dynamically
Called Statically
Called Statically

Yet the output is actually:

Called Statically
Called Dynamically
Called Statically
Called Dynamically


Now my question is, is this what was intended?

It seems that if you call a static class from within a dynamic instance of a
class, the static class then decides $this should reference the class from
which the static class was called

Anyone else come across this?

It could be useful, but right now, its bloody annoying! I need a class to be
called from within another clas, and it needs to know wether it has had an
instance created, or wether it is being statically called, and now I'll have
to write some kludge code instead...




///
// Sean Malloy
// Developer
// element
// t: +61 3 9510 
// f: +61 3 9510 7755
// m: 0413 383 683
///

DISCLAIMER:
© copyright protected element digital pty ltd 2002.
the information contained herein is the intellectual property
of element digital pty ltd and may contain confidential material.
you must not disclose, reproduce, copy, or use this information
in any way unless authorised by element digital pty ltd in writing
or except as permitted by any applicable laws including the
copyright act 1968 (cth).


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




[PHP] 'php_network_getaddresses'

2003-01-05 Thread zzori
I didn't wrote english well, Apache 1.3.27 + PHP 4.2.3

Compiled option
./configure --with-apxs=/usr/local/apache/bin/apxs \
--with-config-file-path=/usr/local \
--enable-trans-sid \
--enable-track-vars \
--with-zlib-dir=/usr/lib \
--with-zlib \
--enable-ftp \
--enable-calendar \
--enable-exif \
--with-mcrypt \
--with-mysql \
--disable-debug \
--enable-inline-optimization \
--enable-mailparse \
--with-gd=/usr/local/gd \
--with-freetype-dir=/usr/include/freetype2 \
--enable-freetype-4bit-antialias-hack \
--enable-gd-native-ttf \
--enable-gd-imgstrttf \
--with-ttf \
--with-imap \
--with-imap-ssl \
--with-kerberos \
--with-jpeg-dir=/usr/lib \
--with-png-dir=/usr/lib \
--with-gif-dir=/usr/lib

install and works fine all
but,

http://URL/cgi-bin/count/zerocount/count.php";; ?>

sometimes happened following error
system, network, dns checking but all is fine and good work now

Warning:
php_network_getaddresses:

getaddrinfo failed: Temporary failure in name resolution
in /wecan/USER_ID/HOME_DIR/nemo.html

on line 64

Warning: Failed
opening 'http://SITE_URL/cgi-bin/count/zerocount/count.php'

for
inclusion (include_path='.:/usr/local/lib/php') in
/wecan/USER_ID/HOME_DIR/nemo.html
on line 64


No errors


Please Search Google :
php_network_getaddresses


isn't PHP Problem?? only SYSTEM, Networking??




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




[PHP] undefining an array element

2003-01-05 Thread David T-G
Hi, all --

If I have an array like

  $a1 = array ( 'a' => 'aaa' , 'b' => 'bbb' , 'c' => 'ccc' ) ;

and I want to completely remove 'b' from it (not just set $a1[b] to ""),
how do I undefine that element?


TIA & HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg91647/pgp0.pgp
Description: PGP signature


Re: [PHP] array help please

2003-01-05 Thread David T-G
John, et al --

...and then John Fishworld said...
% 
% can someone give me a bit of help / walthrough the following for me !

Let's see if I can help.


% this first bits is okay
% $mysql query1
% result
% array[cityid][cityname]
% 
% mysql query2
% result
% array[cityid][cityname]

Are CityIDs unique, like US-GA-ATL and CN-QC-MON or 214365 and 214387, or
is duplication possible?  If the IDs are unique then adding duplicates
won't cause duplicate entries.


% 
% now what i want to do is kick out any doubles in my array and resort them
% alphebetically by cityname ?!

Check out array_merge and array_multisort to put the two together and
sort on the second key, respectively.


% 
% 
% help !


HTH & HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, "Science and Health"
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg91646/pgp0.pgp
Description: PGP signature


[PHP] array help please

2003-01-05 Thread John Fishworld
can someone give me a bit of help / walthrough the following for me !
this first bits is okay
$mysql query1
result
array[cityid][cityname]

mysql query2
result
array[cityid][cityname]

now what i want to do is kick out any doubles in my array and resort them
alphebetically by cityname ?!


help !



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




[PHP] Re: PHP and MySQL bug

2003-01-05 Thread Nuno Lopes
Here is the source code:

Seleccione a localização para o download:Localização Principal";
if ($mirrors) {
echo " Mirrors";
$m=explode("»",$mirrors);
foreach ($m as $v) {
$m2=explode("!",$v);
echo "$m2[0]";
}
echo "Nota: Deve escolher o mirror mais próximo da sua localização,
para acelerar o dowload. No caso de um mirror estar indisponível, utilize
outro.";
}
}
@MYSQL_CLOSE();
?>



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




php-general Digest 5 Jan 2003 09:19:52 -0000 Issue 1804

2003-01-05 Thread php-general-digest-help

php-general Digest 5 Jan 2003 09:19:52 - Issue 1804

Topics (messages 130242 through 130301):

No Global Code Fixing
130242 by: Michael J. Pawlowsky
130244 by: Rasmus Lerdorf
130245 by: Michael J. Pawlowsky
130248 by: Michael J. Pawlowsky
130249 by: Tularis
130250 by: Jason Sheets

Re: security in guest book and user forums
130243 by: Seraphim
130246 by: Tularis
130254 by: Jason Wong
130285 by: Justin French
130286 by: Justin French

mssql functions
130247 by: Duncan

Re: One more form question
130251 by: Ford, Mike   [LSS]

Re: PHP and MySQL bug
130252 by: Stefan Hinz, iConnect \(Berlin\)
130253 by: Michael J. Pawlowsky

You gotta love it...
130255 by: Michael J. Pawlowsky
130256 by: Andy Turegano

Re: [PEAR-DEV] Announcing open CVS for phpDocumentor project
130257 by: Greg Beaver

I can't code today to save my life! :(
130258 by: Phil Powell
130259 by: Chris Hayes
130260 by: Michael J. Pawlowsky
130261 by: Michael J. Pawlowsky

Re: upgrading WAMP environment
130262 by: David T-G

counter problem
130263 by: Anthony Ritter
130265 by: Michael J. Pawlowsky
130266 by: Michael J. Pawlowsky
130270 by: Anthony Ritter
130281 by: Michael J. Pawlowsky

Second (Bizarre) Question regarding PHP and ASP
130264 by: Phil Powell
130267 by: Michael J. Pawlowsky
130268 by: Andrew Brampton
130273 by: Gerald Timothy Quimpo
130280 by: Phil Powell
130284 by: Michael J. Pawlowsky

Perl > PHP
130269 by: Sam
130275 by: Leif K-Brooks

web visitor viewing a script?
130271 by: Larry Brown
130277 by: Timothy Hitchens \(HiTCHO\)
130282 by: Michael J. Pawlowsky
130294 by: Larry Brown

PHP and empty() if form value is 0
130272 by: Phil Powell
130278 by: Michael Sims
130279 by: Phil Powell
130300 by: Michael Sims

Re: exec() not exec-ing?
130274 by: Brendon Gearin

Read-only gif support in 4.3.0
130276 by: Adam Plocher
130283 by: Michael J. Pawlowsky
130287 by: Adam Plocher
130288 by: Michael J. Pawlowsky
130289 by: Adam Plocher
130292 by: Rasmus Lerdorf
130293 by: Michael J. Pawlowsky

Function to catch all mySQL errors?
130290 by: Jeff Lewis
130291 by: Adam Plocher
130296 by: Michael J. Pawlowsky
130298 by: Tom Rogers

pack, unpack and little endian double values
130295 by: timmer

Re: Recommend payment processors?
130297 by: Jonathan Rosenberg \(Tabby's Place\)
130299 by: David McInnis

php4.3.0 & GD library
130301 by: thkiat

Administrivia:

To subscribe to the digest, e-mail:
[EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]

To post to the list, e-mail:
[EMAIL PROTECTED]


--

--- Begin Message ---
Well I've been fixing up all my code (and other peoples which is worst) getting ready 
to do an upgrade to 4.3. and turning off globals and warnings on.

I very often move parameters that were once POSTed as a GETs.
For instance... some one does a search but is not logged in, they can see the results 
but don's see the "Edit" results button.
So they log in, and I send them back to the search they just did.

The first search is done by a POST and when I redirect them after the login it's done 
by a GET.

So I use to simply not specify if it was a GET or POST and looked to see if the var 
existed or not to see how to load that page.

Now I've been adding alot of:


if (isset($_POST['keyword'])){
$keyword = $_POST['keyword'];
}elseif (isset($_GET['keyword'])){
$keyword = $_GET['keyword'];
} else {
unset($keyword);
}


I suppose I could also do something like this (which is not much different)

 if(isset($_POST['keyword']) || isset($_GET['keyword'])){
$keyword = isset($_POST['keyword'])?$_POST['keyword']:$_GET['keyword'];
 }else{
   unset($keyword);
 }

I guess I could get rid of the unset, but I like it there just in case something 
earlier filled that puppy.

So I end up with alot of these right now at the top of each page.
Especially if the URI is something like 
http:www.mysite.com/index.php?this=that&id=1&lang=en&so=on&so=on&so=on&so=on&so=on&so=on

Know what I mean?

So just wondering if anyine had something really elegant to replace it.


Cheers,
Mike


--- End Message ---
--- Begin Message ---
Why don't you just use $_REQUEST['keyword'] ?

On Sat, 4 Jan 2003, Michael J. Pawlowsky wrote:

> Well I've been fixing up all my code (and other peoples which is worst) getting 
>ready to do an upgrade to 4.3. and turning off globals and warnings on.

[PHP] php4.3.0 & GD library

2003-01-05 Thread thkiat
Do you kow how can I upgrade the PHP 4.1.1 in PHPTriad to PHP 4.3.0?
I need PHP 4.3.0. as it includes a version of gd (GD Library) as "standard
equipment."

TQ!



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