Re: [PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread techzeus

Now that, the function has been verified,

what else could be wrong?

- Original Message -
From: "Jack Dempsey" <[EMAIL PROTECTED]>
To: "Jason Lotito" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; "'PHP General List. (E-mail)'"
<[EMAIL PROTECTED]>
Sent: Saturday, March 17, 2001 3:08 PM
Subject: Re: [PHP] Re: Invalid or Valid because the same.


> http://www.php.net/manual/en/function.mysql-num-rows.php
>
> jack
>
> Jason Lotito wrote:
> >
> > Look in the script...
> >
> > > -Original Message-
> > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, March 16, 2001 10:50 PM
> > > To: 'PHP General List. (E-mail)'
> > > Subject: Re: [PHP] Re: Invalid or Valid because the same.
> > >
> > >
> > > //HTML headers here
> > >
> > >  > > if ($Submit == "Submit") {  // If form has been submitted
> > > $errormsg = array();
> > >
> > >
> > > if (!$email)
> > > {
> > > $errormsg[] = "Please fill in your email address";
> > >
>
>  }
> > >
> > >
> > > $count = count($errormsg);
> > >
> > > #echo $count."";
> > >
> > > if ($count > 0) {
> > > for ($i=0; $i > > echo $errormsg[$i]."";
> > >
> > > }
> > >
> > > }
> > >
> > > elseif ($count == 0)
> > >  {
> > > #Insert Database checking ( NO ERROR )
> > >
> > > $host="localhost";
> > > $dbuser="root";
> > > $dbpassword="root";
> > >
> > > mysql_connect($host, $dbuser,
$dbpassword)
> > > or die ("Unable to Connect to Database");
> > > mysql_select_db("secretDB");
> > > $query = "Select username,password
from
> > > users where email = '$email'";
> > > $sqlquery = mysql_query($query);
> >
> > Now, maybe this is just me, but...I would take a strong look at your
> > mysql_numrows() function...their is an msql_numrows, but unless I am off
my
> > rocker...there is no mysql_numrows function.  That might be part of the
> > problem...
> >
> > > $num = mysql_numrows($sqlquery);
> > >
> > > if ($num == 0) #Not valid
> > > {
> > > ?>
> > > So sorry, your
> > > email is not
> > > valid.
> > >  > >
> > >
> > > }
> > > else if ($num == 1) #Valid
> > > {
> > > ?>
> > > Sent mail.
> > >
> > >
> > >  > >
> > > }
> > >
> > > }
> > >
> > > }
> > > if ($reset == "Reset"){
> > > $username = "";
> > > $real_name = "";
> > > $password = "";
> > > $email = "";
> > > }
> > >
> > >
> > > ?>
> > >
> > > // Form here
> > >
> > >
> > > - Original Message -
> > > From: "Jason Lotito" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Saturday, March 17, 2001 5:59 PM
> > > Subject: RE: [PHP] Re: Invalid or Valid because the same.
> > >
> > >
> > > > I have attached a php file together with this email.
> > > >
> > > > I apologize if you are having to download an extra 2k with this
message.
> > > >
> > > > Please help me out. Thank you.
> > > >
> > > > -Original Message-
> > > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > > > Sent: Friday, March 16, 2001 10:36 PM
> > > > To: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> > > > Subject: [PHP] Re: Invalid or Valid because the same.
> > > >
> > > >
> > > > Sorry, heres the attached file.
> > > >
> > > >
> > > > Nope, still no file.  You might want to just paste the important
stuff
> > > into
> > > > the email to the group.
> > > >
> > > > Jason Lotito
> > > > [EMAIL PROTECTED]
> > > > www.newbienetwork.net
> > > >
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > To contact the list administrators, e-mail:
[EMAIL PROTECTED]
> > >
> > >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread Jason Lotito

Yeah..I saw that last line AFTER having posted that.  =)  Goes to show
myself that even when you search for a function, and the manual says it
doesn't exist...it still might.  Haha...

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jack
> Dempsey
> Sent: Friday, March 16, 2001 11:09 PM
> To: Jason Lotito
> Cc: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> Subject: Re: [PHP] Re: Invalid or Valid because the same.
>
>
> http://www.php.net/manual/en/function.mysql-num-rows.php
>
> jack
>
> Jason Lotito wrote:
> >
> > Look in the script...
> >
> > > -Original Message-
> > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, March 16, 2001 10:50 PM
> > > To: 'PHP General List. (E-mail)'
> > > Subject: Re: [PHP] Re: Invalid or Valid because the same.
> > >
> > >
> > > //HTML headers here
> > >
> > >  > > if ($Submit == "Submit") {  // If form has been submitted
> > > $errormsg = array();
> > >
> > >
> > > if (!$email)
> > > {
> > > $errormsg[] = "Please fill in your email address";
> > >
>
>  }
> > >
> > >
> > > $count = count($errormsg);
> > >
> > > #echo $count."";
> > >
> > > if ($count > 0) {
> > > for ($i=0; $i > > echo $errormsg[$i]."";
> > >
> > > }
> > >
> > > }
> > >
> > > elseif ($count == 0)
> > >  {
> > > #Insert Database checking ( NO ERROR )
> > >
> > > $host="localhost";
> > > $dbuser="root";
> > > $dbpassword="root";
> > >
> > > mysql_connect($host, $dbuser,
> $dbpassword)
> > > or die ("Unable to Connect to Database");
> > > mysql_select_db("secretDB");
> > > $query = "Select
> username,password from
> > > users where email = '$email'";
> > > $sqlquery = mysql_query($query);
> >
> > Now, maybe this is just me, but...I would take a strong look at your
> > mysql_numrows() function...their is an msql_numrows, but unless
> I am off my
> > rocker...there is no mysql_numrows function.  That might be part of the
> > problem...
> >
> > > $num = mysql_numrows($sqlquery);
> > >
> > > if ($num == 0) #Not valid
> > > {
> > > ?>
> > > So sorry, your
> > > email is not
> > > valid.
> > >  > >
> > >
> > > }
> > > else if ($num == 1) #Valid
> > > {
> > > ?>
> > > Sent mail.
> > >
> > >
> > >  > >
> > > }
> > >
> > > }
> > >
> > > }
> > > if ($reset == "Reset"){
> > > $username = "";
> > > $real_name = "";
> > > $password = "";
> > > $email = "";
> > > }
> > >
> > >
> > > ?>
> > >
> > > // Form here
> > >
> > >
> > > - Original Message -
> > > From: "Jason Lotito" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Saturday, March 17, 2001 5:59 PM
> > > Subject: RE: [PHP] Re: Invalid or Valid because the same.
> > >
> > >
> > > > I have attached a php file together with this email.
> > > >
> > > > I apologize if you are having to download an extra 2k with
> this message.
> > > >
> > > > Please help me out. Thank you.
> > > >
> > > > -Original Message-
> > > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > > > Sent: Friday, March 16, 2001 10:36 PM
> > > > To: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> > > > Subject: [PHP] Re: Invalid or Valid because the same.
> > > >
> > > >
> > > > Sorry, heres the attached file.
> > > >
> > > >
> > > > Nope, still no file.  You might want to just paste the
> important stuff
> > > into
> > > > the email to the group.
> > > >
> > > > Jason Lotito
> > > > [EMAIL PROTECTED]
> > > > www.newbienetwork.net
> > > >
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > To contact the list administrators, e-mail:
> [EMAIL PROTECTED]
> > >
> > >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


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

Re: [PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread Jack Dempsey

http://www.php.net/manual/en/function.mysql-num-rows.php

jack

Jason Lotito wrote:
> 
> Look in the script...
> 
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, March 16, 2001 10:50 PM
> > To: 'PHP General List. (E-mail)'
> > Subject: Re: [PHP] Re: Invalid or Valid because the same.
> >
> >
> > //HTML headers here
> >
> >  > if ($Submit == "Submit") {  // If form has been submitted
> > $errormsg = array();
> >
> >
> > if (!$email)
> > {
> > $errormsg[] = "Please fill in your email address";
> >

 }
> >
> >
> > $count = count($errormsg);
> >
> > #echo $count."";
> >
> > if ($count > 0) {
> > for ($i=0; $i > echo $errormsg[$i]."";
> >
> > }
> >
> > }
> >
> > elseif ($count == 0)
> >  {
> > #Insert Database checking ( NO ERROR )
> >
> > $host="localhost";
> > $dbuser="root";
> > $dbpassword="root";
> >
> > mysql_connect($host, $dbuser, $dbpassword)
> > or die ("Unable to Connect to Database");
> > mysql_select_db("secretDB");
> > $query = "Select username,password from
> > users where email = '$email'";
> > $sqlquery = mysql_query($query);
> 
> Now, maybe this is just me, but...I would take a strong look at your
> mysql_numrows() function...their is an msql_numrows, but unless I am off my
> rocker...there is no mysql_numrows function.  That might be part of the
> problem...
> 
> > $num = mysql_numrows($sqlquery);
> >
> > if ($num == 0) #Not valid
> > {
> > ?>
> > So sorry, your
> > email is not
> > valid.
> >  >
> >
> > }
> > else if ($num == 1) #Valid
> > {
> > ?>
> > Sent mail.
> >
> >
> >  >
> > }
> >
> > }
> >
> > }
> > if ($reset == "Reset"){
> > $username = "";
> > $real_name = "";
> > $password = "";
> > $email = "";
> > }
> >
> >
> > ?>
> >
> > // Form here
> >
> >
> > - Original Message -
> > From: "Jason Lotito" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Saturday, March 17, 2001 5:59 PM
> > Subject: RE: [PHP] Re: Invalid or Valid because the same.
> >
> >
> > > I have attached a php file together with this email.
> > >
> > > I apologize if you are having to download an extra 2k with this message.
> > >
> > > Please help me out. Thank you.
> > >
> > > -Original Message-
> > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, March 16, 2001 10:36 PM
> > > To: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> > > Subject: [PHP] Re: Invalid or Valid because the same.
> > >
> > >
> > > Sorry, heres the attached file.
> > >
> > >
> > > Nope, still no file.  You might want to just paste the important stuff
> > into
> > > the email to the group.
> > >
> > > Jason Lotito
> > > [EMAIL PROTECTED]
> > > www.newbienetwork.net
> > >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > To contact the list administrators, e-mail: [EMAIL PROTECTED]
> >
> >
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread Jason Lotito

Look in the script...

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 10:50 PM
> To: 'PHP General List. (E-mail)'
> Subject: Re: [PHP] Re: Invalid or Valid because the same.
>
>
> //HTML headers here
>
>  if ($Submit == "Submit") {  // If form has been submitted
> $errormsg = array();
>
>
> if (!$email)
> {
> $errormsg[] = "Please fill in your email address";
> }
>
>
> $count = count($errormsg);
>
> #echo $count."";
>
> if ($count > 0) {
> for ($i=0; $i echo $errormsg[$i]."";
>
> }
>
> }
>
> elseif ($count == 0)
>  {
> #Insert Database checking ( NO ERROR )
>
> $host="localhost";
> $dbuser="root";
> $dbpassword="root";
>
> mysql_connect($host, $dbuser, $dbpassword)
> or die ("Unable to Connect to Database");
> mysql_select_db("secretDB");
> $query = "Select username,password from
> users where email = '$email'";
> $sqlquery = mysql_query($query);


Now, maybe this is just me, but...I would take a strong look at your
mysql_numrows() function...their is an msql_numrows, but unless I am off my
rocker...there is no mysql_numrows function.  That might be part of the
problem...

> $num = mysql_numrows($sqlquery);
>
> if ($num == 0) #Not valid
> {
> ?>
> So sorry, your
> email is not
> valid.
> 
>
> }
> else if ($num == 1) #Valid
> {
> ?>
> Sent mail.
>
>
> 
> }
>
> }
>
> }
> if ($reset == "Reset"){
> $username = "";
> $real_name = "";
> $password = "";
> $email = "";
> }
>
>
> ?>
>
> // Form here
>
>
> - Original Message -
> From: "Jason Lotito" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Saturday, March 17, 2001 5:59 PM
> Subject: RE: [PHP] Re: Invalid or Valid because the same.
>
>
> > I have attached a php file together with this email.
> >
> > I apologize if you are having to download an extra 2k with this message.
> >
> > Please help me out. Thank you.
> >
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, March 16, 2001 10:36 PM
> > To: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> > Subject: [PHP] Re: Invalid or Valid because the same.
> >
> >
> > Sorry, heres the attached file.
> >
> >
> > Nope, still no file.  You might want to just paste the important stuff
> into
> > the email to the group.
> >
> > Jason Lotito
> > [EMAIL PROTECTED]
> > www.newbienetwork.net
> >
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] XML Newbie.!

2001-03-16 Thread Rick St Jean

If it was a question about tables and how you can use them with PHP then yes.
Take this off-list if you have something important to say please.


At 07:39 AM 3/17/01 +0100, Nik Gare wrote:
>In article <[EMAIL PROTECTED]>,
>Rick St Jean <[EMAIL PROTECTED]> wrote:
> > Make sure you read the whole message before you comment.  There was a
> > relative question at the bottom.
>
>I have a question concerning  tags.
>I also have a question concerning PHP.
>Should I ask both questions here, or just the PHP related question?
>
>Nik
>
>btw, the references, ie who you are replying to, in your mail is
>incorrect.
>

##
#  Rick St Jean,
#  [EMAIL PROTECTED]
#  President of Design Shark,
#  http://www.designshark.com/
#  Quick Contact:  http://www.designshark.com/messaging.ihtml
#  Tel: 905-684-2952
##


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread techzeus

//HTML headers here

";

if ($count > 0) {
for ($i=0; $i";

}

}

elseif ($count == 0)
 {
#Insert Database checking ( NO ERROR )

$host="localhost";
$dbuser="root";
$dbpassword="root";

mysql_connect($host, $dbuser, $dbpassword)
or die ("Unable to Connect to Database");
mysql_select_db("secretDB");
$query = "Select username,password from
users where email = '$email'";
$sqlquery = mysql_query($query);
$num = mysql_numrows($sqlquery);

if ($num == 0) #Not valid
{
?>
So sorry, your email is not
valid.

Sent mail.




// Form here


- Original Message -
From: "Jason Lotito" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, March 17, 2001 5:59 PM
Subject: RE: [PHP] Re: Invalid or Valid because the same.


> I have attached a php file together with this email.
>
> I apologize if you are having to download an extra 2k with this message.
>
> Please help me out. Thank you.
>
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 10:36 PM
> To: [EMAIL PROTECTED]; 'PHP General List. (E-mail)'
> Subject: [PHP] Re: Invalid or Valid because the same.
>
>
> Sorry, heres the attached file.
>
>
> Nope, still no file.  You might want to just paste the important stuff
into
> the email to the group.
>
> Jason Lotito
> [EMAIL PROTECTED]
> www.newbienetwork.net
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Require vs include

2001-03-16 Thread NGUYEN DINH Quoc Huy

Hi

Can someone explain me what's the difference between include() and require() ??
I did not catch the explanation in the docs.
When should I use include() and when should I use require() ??

I'm not on the list so reply me to: [EMAIL PROTECTED]

Thnx

-- 
=
 NGUYEN DINH Quoc Huy (SnAKes)
   http://www.snakesbox.com/
  [EMAIL PROTECTED] - ICQ# 3398187
  telnet://snakesbox.com:/  <-- Puissance 4
=



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] XML Newbie.!

2001-03-16 Thread Nik Gare

In article <[EMAIL PROTECTED]>,
   Rick St Jean <[EMAIL PROTECTED]> wrote:
> Make sure you read the whole message before you comment.  There was a
> relative question at the bottom.

I have a question concerning  tags.
I also have a question concerning PHP.
Should I ask both questions here, or just the PHP related question?

Nik

btw, the references, ie who you are replying to, in your mail is
incorrect.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Re: Invalid or Valid because the same.

2001-03-16 Thread techzeus



Sorry, heres the attached file.

  - Original Message - 
  From: 
  [EMAIL PROTECTED] 
  To: 'PHP General List. (E-mail)' 

  Sent: Saturday, March 17, 2001 2:35 
  PM
  Subject: Invalid or Valid because the 
  same.
  
  Hello,
   
  Sorry to disturb you guys of your precious programing time 
  ;-)
   
  I'm stumped, I have coded everything properly and everything 
  looks perfectly fine but I'm still getting error. I'm doing a lostpassword 
  script such that when a user fills in their email, the database will check if 
  there is such an email and then send the username\password according 
  to the email.
   
  But when I type in a valid or an invalid email at the first 
  time, a error\valid message will appear as normally but then, after that, what 
  ever email I typed in (whether valid or invalid) will not show any error 
  anymore and just clears up.
   
  I have attached a php file together with this email. 
  
   
  I apologize if you are having to download an extra 2k with 
  this message. 
   
  Please help me out. Thank you.
   
  
  David 
  Chua-

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


[PHP] Invalid or Valid because the same.

2001-03-16 Thread techzeus

Hello,

Sorry to disturb you guys of your precious programing time ;-)

I'm stumped, I have coded everything properly and everything looks perfectly fine but 
I'm still getting error. I'm doing a lostpassword script such that when a user fills 
in their email, the database will check if there is such an email and then send the 
username\password according to the email.

But when I type in a valid or an invalid email at the first time, a error\valid 
message will appear as normally but then, after that, what ever email I typed in 
(whether valid or invalid) will not show any error anymore and just clears up.

I have attached a php file together with this email. 

I apologize if you are having to download an extra 2k with this message. 

Please help me out. Thank you.


David Chua
-




[PHP] RE: articles to install Red Hat server, mysql, php

2001-03-16 Thread Nyon

Hi,

I found a lot of articles that teaches how to install Red Hat Linux, MySQL
and PHP.
However, most of them are not elaborate enough to go through the entire
process.
Anyone with some solid resources on these ?

Also, can one install the server version of Red Hat with a GUI interface
rather the plain
command line ?

Nyon

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] XML Newbie.!

2001-03-16 Thread Rick St Jean

Make sure you read the whole message before you comment.  There was a 
relative question at the bottom.

Rick

At 12:59 AM 3/17/01 +0100, Nik Gare wrote:
>In article <[EMAIL PROTECTED]>, Diego
>Fulgueira <[EMAIL PROTECTED]> wrote:
> > Hi! Ok, this is not a question about PHP, but since this is such a
> > great discussion forum, I am certain it is a good place to get started
> > with a new technology.
>
>
>Oh, but it is a PHP mail list/newsgroup.
>This question does not belong here.
>
>Nik
>

##
#  Rick St Jean,
#  [EMAIL PROTECTED]
#  President of Design Shark,
#  http://www.designshark.com/
#  Quick Contact:  http://www.designshark.com/messaging.ihtml
#  Tel: 905-684-2952
##


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] XML Newbie.!

2001-03-16 Thread Nik Gare

In article <[EMAIL PROTECTED]>, Diego
Fulgueira <[EMAIL PROTECTED]> wrote:
> Hi! Ok, this is not a question about PHP, but since this is such a
> great discussion forum, I am certain it is a good place to get started
> with a new technology.


Oh, but it is a PHP mail list/newsgroup.
This question does not belong here.

Nik


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] mail() implementation problem

2001-03-16 Thread Tim Frank

Mathieu,

I believe the feature you are looking for has been made available in the 
new PHP 4.0.5 that is upcoming.  They have added a 5th paramether to the 
mail() function so you can actually pass sendmail command line arguments 
such as -f.  For those of us not running the development version, someone 
was kind enough to post a really good work around that isn't hard and 
gives the same functionality.  I won't post it here, but it can be found 
as the last of the user comments at 
http://www.php.net/manual/en/function.mail.php dated March 9th at 5:02 
am.  I implemented this on my servers and it works great.  You do have to 
add the one line to the scripts that use the mail function, but that is 
really it after sendmail is configured.
Hope that was what you were looking for.

Tim Frank

>> Original Message <<

On 16/03/01, 5:05:13 AM, [EMAIL PROTECTED] (Mathieu Arnold) wrote 
regarding Re: [PHP] mail() implementation problem:


> Manuel Lemos wrote:
> >
> > Hello,
> >
> > Mathieu Arnold wrote:
> > >
> > > Hi
> > >
> > > The actual implementation of the mail fonction use sendmail -t and
> > > relies on sendmail to parse the headers to get the recipients.
> > > It would be great if it was possible to switch from this way of using
> > > sendmail to a more classic
> > > sendmail -f sender rcpt
> > > it should be quite easy, but I lack time to do it.
> >
> > You may want to try this PHP MIME message composing and sending class
> > that has subclasses for sending messages using directly sendmail, qmail
> > or even a SMTP server.
> >
> > http://phpclasses.UpperDesign.com/browse.html/package/9

> looks nice, but I'm not going to ask all my clients to change their php
> scripts ;)
> I just need to change the way php calls sendmail :)
> I believe I'm going to do it myself next week or so.

> --
> Mathieu Arnold

> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] metabase docs and DB abstraction

2001-03-16 Thread Dean Hall

Anyone have opinions on which DB abstraction layer is best for what
situation? Is there an article somewhere that compares the various DB
abstraction layers?

(Cross-post:)

Anyone know where I can find documentation or samples for metabase?

Dean.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] header:(location) error

2001-03-16 Thread Brett


> I am receiving the following error from my app, and I'd be gratefull if
> somebody would point out the usual cause of   it. I am doing a redirect
> based on a form validation routine. Thank you.
>
> Warning: Cannot add header information - headers already sent in
> /usr/home/stas/html/cathedral/scripts/act_save_resume.php on line 175

Make sure you have no whitespace above your  tags.  If any output is
sent to the browser then you can not add a header, session, cookie.

Brett


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Putting php at end of html?

2001-03-16 Thread Richard Lynch

> > YES!
> > The only "problem" will be that these .php pages will be
> > maybe 5% slower since PHP is "parsing" them.
>
> That and all the links pointing to the old .html files will be
> broken...

That's what using .php in advance will avoid.

> So if you mix PHP and HTML in a file, PHP will be slower
> to parse those files?  I thought it was smart enough to
> parse only what was within the recognized start and end
> tags (, , ,
> etc)?

PHP *is* smart enough, but it has to "look" in the HTML to see any http://www.zend.com/store/
Wanna help me out?  Like Music?  Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Running script on remote server

2001-03-16 Thread Patrick Dunford

The PHP 4.0 manual contains this information:
-
Chapter 20. Using remote files
As long as support for the "URL fopen wrapper" is enabled when you configure
PHP (which it is unless you explicitly pass the --disable-url-fopen-wrapper
flag to configure (for versions up to 4.0.3) or set allow_url_fopen to off
in php.ini (for newer versions), you can use HTTP and FTP URLs with most
functions that take a filename as a parameter, including the require() and
include() statements.

Note: You can't use remote files in include() and require() statements on
Windows.

For example, you can use this to open a file on a remote web server, parse
the output for the data you want, and then use that data in a database
query, or simply to output it in a style matching the rest of your website.
-

The example in the Help shows opening a file at http://www.php.net/ with
fopen(). Are they accessing the source code of the script, or the HTML code
that is output by the PHP server when it runs the PHP script that it loads
from that location?

What I want to be able to do is, to get around the problem that the server
that I am running my site on does not have database, I want to run the
database on another server elsewhere on the Web. I want to be able to, by
fopen() -ing the page via its URL, to be passing some variables to the
script, have the remote PHP server run the script and pass back to me the
output as a file, which I can then load into my web page and display.

===
Patrick Dunford, Christchurch, NZ - http://pdunford.godzone.net.nz/

   You are all sons of God through faith in Christ Jesus, for all
of you who were baptized into Christ have clothed yourselves with
Christ.
-- Galatians 3:26-27
http://www.heartlight.org/cgi-shl/todaysverse.cgi?day=20010316
===
Created by Mail2Sig - http://pdunford.godzone.net.nz/software/mail2sig/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] header:(location) error

2001-03-16 Thread stas

Hello,

I am receiving the following error from my app, and I'd be gratefull if
somebody would point out the usual cause of   it. I am doing a redirect
based on a form validation routine. Thank you.

Warning: Cannot add header information - headers already sent in
/usr/home/stas/html/cathedral/scripts/act_save_resume.php on line 175



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4(PHP_4_0_5) /ext/standard output.c

2001-03-16 Thread Zeev Suraski

zeevFri Mar 16 19:05:07 2001 EDT

  Modified files:  (Branch: PHP_4_0_5)
/php4/ext/standard  output.c 
  Log:
  MFH
  
  
Index: php4/ext/standard/output.c
diff -u php4/ext/standard/output.c:1.48 php4/ext/standard/output.c:1.48.2.1
--- php4/ext/standard/output.c:1.48 Tue Mar  6 11:38:33 2001
+++ php4/ext/standard/output.c  Fri Mar 16 19:05:07 2001
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: output.c,v 1.48 2001/03/06 19:38:33 zeev Exp $ */
+/* $Id: output.c,v 1.48.2.1 2001/03/17 03:05:07 zeev Exp $ */
 
 #include "php.h"
 #include "ext/standard/head.h"
@@ -157,6 +157,7 @@
orig_buffer->value.str.len = OG(active_ob_buffer).text_length;
orig_buffer->type = IS_STRING;
orig_buffer->refcount=2;/* don't let call_user_function() 
destroy our buffer */
+   orig_buffer->is_ref=1;
 
ALLOC_INIT_ZVAL(z_status);
Z_TYPE_P(z_status) = IS_LONG;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard output.c

2001-03-16 Thread Zeev Suraski

zeevFri Mar 16 19:03:50 2001 EDT

  Modified files:  
/php4/ext/standard  output.c 
  Log:
  Fix the output buffering bug Andre found
  
  
Index: php4/ext/standard/output.c
diff -u php4/ext/standard/output.c:1.48 php4/ext/standard/output.c:1.49
--- php4/ext/standard/output.c:1.48 Tue Mar  6 11:38:33 2001
+++ php4/ext/standard/output.c  Fri Mar 16 19:03:50 2001
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: output.c,v 1.48 2001/03/06 19:38:33 zeev Exp $ */
+/* $Id: output.c,v 1.49 2001/03/17 03:03:50 zeev Exp $ */
 
 #include "php.h"
 #include "ext/standard/head.h"
@@ -157,6 +157,7 @@
orig_buffer->value.str.len = OG(active_ob_buffer).text_length;
orig_buffer->type = IS_STRING;
orig_buffer->refcount=2;/* don't let call_user_function() 
destroy our buffer */
+   orig_buffer->is_ref=1;
 
ALLOC_INIT_ZVAL(z_status);
Z_TYPE_P(z_status) = IS_LONG;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] PSpell?

2001-03-16 Thread Jonathan Sharp

I have checked my phpinfo() and it shows that PSPell is enabled.

But when i run the following script (per php.net/manual/ example) i get the
following (following) error...

$pspell_link = pspell_new ("en");

if (pspell_check ($pspell_link, "testt")) {
echo "This is a valid spelling";
} else {
echo "Sorry, wrong spelling";
}

"Warning: PSPELL couldn't open the dictionary. reason: I'm sorry I can't
find any sutable word lists for the language-tag "en". in
/parte/htdocs/public_html/pspell/test1.php on line 10

Warning: 0 is not an PSPELL result index in
/parte/htdocs/public_html/pspell/test1.php on line 12
Sorry, wrong spelling "

I have pspell-.11.2

Thanks,
-Jonathan


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Zend?

2001-03-16 Thread Chris Anderson

I've heard alot about the Zend Encoder. Using it can I encode I file so that php still 
executes it, but a person cannot read my source by looking at the file? I'm 
programming components for people and would prefer if they could use it, but not see 
my source. Does it require any extra server settings etc?



Re: [PHP] Associative vs normal arrays

2001-03-16 Thread Alexander Wagner

[EMAIL PROTECTED] wrote:
> > There are only assotiative arrays in PHP.
>
> PHP has associative and numeric (normal) arrays. But is_array() says
> only if it is an array or not. The distinction could only be made if
> you look at keys. Keys can be integers or strings. I hope this was
> correct, if not, Andrei can correct me :)

If I'm not completely mistaken, PHP has only associative arrays, 
which can act more or less like "normal" indexed arrays when numbers 
are used as keys, which is the default when no keys are set explicitly, 
like in:

$arr = array('a', 'b', 'c');
which equals
$arr = array(0 => 'a', 1 => 'b', 2 => 'c');

But they are still associative, afaik.
However, I agree, the only way to make a distinction is to look if the 
keys are integers.

regards
Wagner

-- 
Assumption is the mother of all fuck-ups.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




php-general Digest 17 Mar 2001 02:24:05 -0000 Issue 571

2001-03-16 Thread php-general-digest-help


php-general Digest 17 Mar 2001 02:24:05 - Issue 571

Topics (messages 44262 through 44351):

dbadmin improved
44262 by: Peter Van Dijck

Re: Strange Behaviour in non-reference globals?
44263 by: Yasuo Ohgaki

Can you recommend an ISP with the following?
44264 by: Jamie Jackson
44270 by: Mal McKay
44273 by: John Huggins
44277 by: Cal Evans
44285 by: Jamie Jackson
44293 by: Brett
44306 by: Boaz Yahav

echo only displays first character
44265 by: Tom Harris
44283 by: Chris Lee
44302 by: Mal McKay

Re: ODBC to mysql?
44266 by: yawstick

Re: Website, Design, hosting and maintenance for only $999.00 per year
44267 by: Mal McKay

Re: Benchmarks
44268 by: Chris Adams
44278 by: Pierre-Yves Lemaire

Re: the mail() again
44269 by: Romeo Manzur

passing variables using hidden fields
44271 by: george
44282 by: Chris Lee
44289 by: george

How do I get Variables out of a string?
44272 by: Shawn Pritchard
44276 by: Cal Evans

Re: PostToHost
44274 by: Boget, Chris

Building PHP on SYSV
44275 by: Dan Mahoney

protecting password file on ISP
44279 by: Jamie McClelland

Re: FAQ
44280 by: Keith Vance
44344 by: Nik Gare

send file truh mail() function???
44281 by: Romeo Manzur

Webmin
44284 by: Michael Kimsal
44343 by: Mike Tuller

sendmail
44286 by: Marius Kirschner
44287 by: Robert Covell
44288 by: Marius Kirschner

PHP standalone script
44290 by: Don Pro
44333 by: Meir kriheli

$PHP_SELF vs. functions, arrays and variable
44291 by: Scott Fletcher
44292 by: John Lim

Problem with VARIABLES
44294 by: Ian LeBlanc
44299 by: Hardy Merrill

Re: With all this talk about editors ...
44295 by: Boget, Chris

Re: Shopping Carts and Sessions
44296 by: DynamicHTML.aol.com
44297 by: Aaron Tuller
44304 by: Data Driven Design
44321 by: DynamicHTML.aol.com

Re: Putting php at end of html?
44298 by: Boget, Chris

phpinfo() displayed old info
44300 by: Revina
44301 by: Revina
44303 by: harun.crb.elga.net.id

Login System with access levels
44305 by: Jordan Elver
44307 by: Pierre-Yves Lemaire
44327 by: yavo
44328 by: yavo

Re: [PHP-DB] Login System with access levels
44308 by: Rick Emery
44313 by: Jack Sasportas

XML Newbie. HELP!
44309 by: Diego Fulgueira

XML Newbie.!
44310 by: Diego Fulgueira

inner workings of extract
44311 by: dempsejn.georgetown.edu

include php3 -vs- 4
44312 by: Jack Sasportas
44314 by: Boget, Chris
44315 by: Philip Olson
44316 by: rm

Re: Bug IDs #8772, #9002, maybe #9724 - session write handler and register_globals
44317 by: Jaime Bozza

dynamic url from MySql field data
44318 by: Claudia

FileUpload problematic
44319 by: Thalis A. Kalfigopoulos

managing image files with PHP/Mysql
44320 by: Mig
44325 by: Jack Sasportas

Hello! PHP
44322 by: Celestino Roberto Alejandro
44332 by: bard

Can CONSTANT's be made persistent?
44323 by: Johnson, Kirk
44324 by: Aaron Tuller

Associative vs normal arrays
44326 by: Joe
44331 by: Alexander Wagner
44335 by: Joe
44336 by: eschmid+sic.s.netic.de

Frames
44329 by: Randy Johnson
44330 by: Randy Johnson

I can't do a connection to POSTGRES from PHP4 as NSAPI
44334 by: Norberto Rojas
44337 by: Martin A. Marques

Radio Button Returns (Pleasre Read)
44338 by: Fred
44345 by: Nathan Cook

Change POST for GET
44339 by: Jorge Alvarez

highlight_string parsing in an article
44340 by: Jason Lotito

serialize/unzerialize help
44341 by: andrie

PHP not seeming to work
44342 by: Don Weeks

avoiding redirect
44346 by: mat t

Re: Good Free PHP Editor?
44347 by: Jeffrey A.Stuart

Sessions and CHECKBOXES :(
44348 by: karakedi

Re: Error with ldap
44349 by: Brett Bandy

Re: Opening/closing a DB
44350 by: Brett Bandy

JDBC?Was: [PHP] Hello! PHP
44351 by: andrew

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]


--



I just tried out
http://sourceforge.net/projects/phpmyedit/
it's like Paul's dbadmin script for generating admin, but seems bettter 
(has paging, ...).
Peter
~~
http://liga1.com: building multiple language/culture websites




- Original Message - 
From: "John" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sen

[PHP] JDBC? Was: [PHP] Hello! PHP

2001-03-16 Thread andrew

On a related noted, does PHP have JDBC support?

I'm unable to find anything about this - anyone know if it's possible?

regards,
andrew



On 3/15/01 5:49 PM, "bard" <[EMAIL PROTECTED]> wrote:

> If you want to e mail me privately I'll go into greater detail.
> But, to be brief, let me just say this.
> 
> DON'T DO IT.
> 
> Use jsp or python or anything else that talks to java. I've tried
> every available permutation of php/java on SEVERAL different plat-
> forms with simlilarly bad results on all of them.
> 
> Just say NO.
> 
> Brad
> 
> On Fri, 16 Mar 2001, Celestino Roberto Alejandro wrote:
> 
>> Hello, i'm working with PHP, and i need use a classes that this company have
>> developed in java, can i use it from php?
>> ...yes, i know that i can, but, when i make the configuration of the php.ini,
>> run the hello example, all rights, but, when i make a class
>> that use a frame of awt, for show a window, doesn't work, WHY?, the errors
>> are, of Null pointer, and not found classes, but?, i need copy all classes of
>> the basic structure of java, in my java.classpath?...where i can found more
>> info?
>> :-)
>> Robert 
>> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Opening/closing a DB

2001-03-16 Thread Brett Bandy

With InterBase using persistent connections will save a lot of time.
However,
you need to be extra careful with how you manage transactions.  InterBase
uses
a versioning engine for transaction management and you can easily screw up
the
system performance if you don't manage your transactions correctly.

Make sure you use short quick transactions.  Don't leave a transaction open,
always make
sure the transaction is committed or rolledback.  Lingering transactions are
probably the
biggest performance problem you'll encounter with InterBase.

Brett

""Daniel Grace"" <[EMAIL PROTECTED]> wrote in message
004101c0a992$80fa98c0$b4bc9a40@hades">news:004101c0a992$80fa98c0$b4bc9a40@hades...
> On Saturday, March 10, 2001 at 7:03 AM, Todd Cary
<[EMAIL PROTECTED]>
> wrote:
>
> > I have some questions about PHP and it's interaction with a DB (namely,
> > Interbase).  My client's application uses a DB extensively and I am not
> > clear about opening and closing a DB -  the price one pays.
> >
> > First, I notice that the approximate time to open a connection to my DB
> > on my test system is 1 second with a "locate time" of another second.
> > So, 50% of the time is opening the DB.
> -- snip --
>
> I haven't used Interbase, but if it's like most of PHP's database
> interfaces, it isn't too critical to worry about closing the database
> connection. PHP will do so automatically when your script ends.
>
> -- unsnip --
> >
> > The next question envolves closing the DB and returning memory.
> >
> > ibase_free_result;
> > ibase_close($dbh);
> >
> > What will happen if in my code I forget to do this in a place or two?
> > Will the system eventually crash?
> -- snip --
>
> The Interbase extensions to PHP support persistent connections:
> http://www.php.net/manual/en/function.ibase-pconnect.php (see
> mysql_pconnect() as well for more general info on persistent connections).
> With persistent connections, the overhead in connecting to the database
> backend is minimized since the same connection can be shared across
multiple
> pages. This won't work with the CGI version of PHP however.
>
>  - Daniel Grace 
>
>   "Space may be the final frontier but its made in a Hollywood basement."
> - Red Hot Chili Peppers - Californication
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Error with ldap

2001-03-16 Thread Brett Bandy

php_ldap.dll also requires libsasl.dll, so make sure you move this dll to
\winnt\system32 as well.

Brett

"Alain ROMERO" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I copy 'msvcrtd.dll' in winnt\system32 and php3 works fine, but not php4

HELP !

Alain ROMERO a écrit :

> PHP 4.0.2 on Win32
> or PHP 3 on Win32
> extension=php_ldap.dll   is on in the php.ini file
>
> I get 'Unable to load php_ldap.dll' (PHP4) when I call a php file ?
> I get 'Call to an unsupported function ldap_connect()' (PHP3)  ?
>
> Help please ?
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Sessions and CHECKBOXES :(

2001-03-16 Thread karakedi

i ve 20 film names stored at database, and i want to show them in
alphebetical order. And i want to show 10 of them at each page. Nothing is
wrong here. At the end of each film name there is a CHECKBOX, here is the
code:

$count = 0;
while ($row = mysql_fetch_array($result)){

echo "";

echo ""   ; // getting film names here
echo $row['film'] ;
echo ""  ;


$sepet = $row['tur'] ;   // putting checkboxes here
$sepet2 = $row['film'];
$sepetsonuc = $sepet. " " .$sepet2 ;
echo "" ;

echo ""  ;
$count++;
}


its good till here. everything is working... now since there are two pages i
want to register checkbox variables  which are CHECKED with
"session_register "so that i can use them at the second page. without that
my code simply cant remember the checked ones at the previous pages.

Can someone help me to register these checkbox values into sessions ?
PLS dont refer me to php.net manual/sessions  :(

i spent my last two days working on this so really need help :(  any help is
HIGHLY APPRECIATED!!!
thx in adv.




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Good Free PHP Editor?

2001-03-16 Thread Jeffrey A . Stuart

In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] says...
> On 12 Mar 2001 03:51:13 -0800, [EMAIL PROTECTED] (Nick Davies) wrote:
> 
> >How about linux ones?
> >
> >I just tend to use vim or emacs but i'm sure there are some out there.
> 
> I've used Xemacs. Do you know if there is a PHP mode for it?
> 
> Otherwise you could check out Screem (www.screem.org) or Quanta
> (quanta.sourceforge.com).
> 
> V
> 
> 

yes, there is a number of PHP modes for Xemacs... Go here 
(http://www-public.tu-bs.de:8080/
~y0008422/krabutzig/emacsphp.html) for a good listing. 

--
Jeff Stuart
[EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] avoiding redirect

2001-03-16 Thread mat t

I have a form that allows user to either upload a file from the client to the server 
or take the contents of the textarea and dump it in a new file on the server. 

Unfortunately I have tried to make the form write the new file to the server and at 
the same time redirect to the this new file. It seems that php takes a second to write 
the new file and therefore only works if I delay the process by redirecting as 
follows: 

printf ("http://coolsite/test/newfile.html\">");

Is there any better process I can use?



_
Pick up your email anywhere in the world ---> http://www.remail.net

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Radio Button Returns (Pleasre Read)

2001-03-16 Thread Nathan Cook

This question baffles me.  Just to clarify do you have at least two radio
buttons on this page and are they both under the same name?

It also could be if the HTML you mailed the list is the same you have in
your generated page then you may want an '=' sign between the value"index"

.:: Nathan Cook [ [EMAIL PROTECTED] ] ::.
PCS Edventures.com
Programmer :: Systems & Network Administrator
[ phone - 208.343.3110 ][ pager - 208.387.9983 ]

\"You know you\'re in big trouble when you try to escape character your
e-mail\'s\"

- Original Message -
From: "Fred" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, March 16, 2001 4:22 PM
Subject: [PHP] Radio Button Returns (Pleasre Read)


> this is the code:
>$page .= " value\"$info[PageID]\">";
>
> this is the html source generated:
> 
>
> and this is what $pageid returns:
> 'on'
>
> 2 questions is
> why? and how do i fix it?
>
> thanks to all who take the time to awnser :-)
> ~Fred
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] FAQ

2001-03-16 Thread Nik Gare

In article <[EMAIL PROTECTED]>,
   Rick St Jean <[EMAIL PROTECTED]> wrote:
> The problem is that people are lazy or just to stupid to look for
> stuff. 


I guess people are either too lazy or just too stupid to learn how to
quote in emails. ;-)

> I guess I am frustrated because all the lists I am on are filled with
> lazy people who whine and want someone else to do all their work for
> them.


I get frustrated by people sending huge quotes, and leaving 4 of those
auto generated list tags behind.  If they didn't, the traffic on the list,
size wise, would be halved.

Nik


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Webmin

2001-03-16 Thread Mike Tuller

Webmin uses templates, so you could create anything you want. If you go into
Webmin configuration under the Webmin tab, you will see templates. When you
go in there you will see a menu for current theme. It should have Calderas
theme. That at least means they are open to template creation.

I agree though, it would be nice in PHP, but I think that you can still do a
little more system level scripting in Perl right now.


> From: Michael Kimsal <[EMAIL PROTECTED]>
> Reply-To: [EMAIL PROTECTED]
> Date: Fri, 16 Mar 2001 11:33:46 -0500
> To: [EMAIL PROTECTED]
> Subject: [PHP] Webmin
> 
> Although I somewhat agree with the webmin sentiment,
> after having tried to do simple maintenance on a cobalt for someone,
> it seems a real dog for anything outside the normal scope of what
> they want you to do.  We needed to edit an httpd.conf file,
> but there doesn't seem to be a way to do it.  Ditto for restarting Apache.
> Add a MIME type?  No dice.
> 
> Webmin is not the slickest interface, but seems to offer a lot of flexibility.
> 
> Rather than rewriting something, perhaps you could vounteer to design
> a better interface for existing webmin stuff.
> 
> A PHP-based version of webmin would be nice, but it's already a rather
> developed project, and after considering how to do it myself, I realized
> there's a whole hell of a lot of configurations and systems to have to
> consider beyond my few linux distros.
> 
> John Huggins wrote:
> 
>> You mention a large desire for a good web based administrator.  I wonder if
>> there is a version of a web based system administrator available that works
>> like Cobalt, but can be installed on any hosting setup.  Have you folks
>> heard of such a thing?  I am aware of Webmin, but am not too impressed with
>> it yet.
>> 
>> I have toyed with the idea of writing my own.  Jamie, what items do you feel
>> must be controllable in a web hosting account administration panel?  Yes, we
>> all know the basics, like email, dns, etc. but a bulleted list would be a
>> good start at organizing a development effort.
>> 
>> John
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] PHP not seeming to work

2001-03-16 Thread Don Weeks




I am having a 
helluva time getting PHP 4.0 to work with my apache browser. I add code for the 
PHP software for instance:
 

   
phpinfo();
?>
 
And all I get is a 
blank screen. I built php as an apache DSO. I know it is getting loaded cause it 
bitches if the libphp file is not available. I have recompiled several time. I'd 
sure like some help with this. Spending way to much time getting it to work and 
no time developing the app.


 -- 
Don    
.~. 
Weeks  
/V\     L I N 
U X 
[EMAIL PROTECTED]    // \\   >Phear the Penguin< 

[EMAIL PROTECTED] /(   )\ 
      ^^-^^
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


[PHP] serialize/unzerialize help

2001-03-16 Thread andrie

Hello all members,
  i am confuse to pass my class object over page (read my
  quote below).
  can u give a little example to demonstrate this using serialize
  and unserialize function.
  thaks for your attention..


andrie

Tuesday, March 13, 2001, 9:03:08 PM, Loe nulis gini:

PK> do you have register_globals enabled in your php.ini? you also have to have
PK> the class definition available when unserializing it to properly reconstruct
PK> the class with all the methods. if you're using PHP4 it's quite handy to use
PK> the built-in session functionality to implement persistent classes.


PK> Pavel


PK> - Original Message -
PK> From: "andrie" <[EMAIL PROTECTED]>
PK> To: <[EMAIL PROTECTED]>


>> Hello php-db,
>>
>>   if i have a class
>>  class myDog {
>>  VAR $name;
>>  Function bark();
>>  }
>>
>>  $dog = new myDog;
>>
>>   and i want to pass this class over page. someone in this forum said
>>   to me to use serialize and pass it using cookies.
>>   setcookie("dog", serialize($dog));
>>   the question is, when i used unserialize to get this class from
>>   other page ,
>>  unserialize($dog);
>>
>>   i have found out that i can find my class structure or any
>> properties and it values there.
>>   anybody can help me ?
>>
>> --
>> Best regards,
>>  andrie  mailto:[EMAIL PROTECTED]



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] highlight_string parsing in an article

2001-03-16 Thread Jason Lotito

Okay, I have a bugger here.  I am working on a script for my site to parse
articles, comments, so that people use a special markup (like [b] [/b] for
 , etc).  One of the feature I want to implement is a [code] feature
that will parse the code between [code] and [/code] like it would in
hightlight_string().

The problem is, I want this for all the code that could possible be
represented in a comment or an article.  In some of the articles I write, I
have several examples of the code, and I would like each instance put
through the above process, but not the entire article.

So, I have hit a snag.  First, highlight_string actually prints out the
results, so as far as I know, it doesn't return anything
(http://www.php.net/manual/en/function.highlight-string.php) except for a
true/false result.

What I want to have happen is parse the document, and take the stuff between
the [code] tags, and parse that out.  Of course, the entire article is being
put through, so I imagine I will have to be using regular expressions or
explode(), though I expect more the former.

For example, take this:

-
A quick overview of echo, and how and why you should try and use inline HTML
instead of outputting with echo. Just something real quick and easy that I
think is rather important.

A quick overview of echo, and how it compares to coding your HTML as Inline.
Test results have shown that inline display is 2 times faster than echo.

echo - 0.063347 secs
inline - 0.035276 secs

For example:
[code]

[/code]
If you compare that to this:
[code]
Yes is not Yes
[/code]
While this may not be immediately noticeable in small programs, if the
program is large, or it starts to recieve a lot of hits, than you will
appreciate the little extra speed that inline prints give you.  Sure, it
requires a bit of extra work on your part, but it does make for nicer
programming.

Also, if you think about it, its much easier to use inline than echo'ing
everything you do.  No more escaping the " in the  HTML in the echo's.  And
you should use the " even if you plan on using echo, as its good form.
---

Now, that would be in the database.  When the article is veiwed, it is sent
through a parser.  The parser will pick up the code tags, and parse what is
in between through highlight_string().

Unfortunately, like I said, I cannot figure out how to do this, maintaining
the structure of the article, while keeping it in one area.  I don't want to
create a seperate table to hold the code, and have that inserted into the
articles as need parsed, just doesn't seem efficient enough.

Any help would be appreciated.  If you could point me to even a script that
does something like this, I could hack my way through it, but I have don't
know where to start with this.  Thanks.

Jason Lotito
[EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Change POST for GET

2001-03-16 Thread Jorge Alvarez

Hi there,

I was using POST method on all my forms but I had to change them to GET
because of "expired page" errors (I noticed this as soon as I began using
PHP4 sessions).

It seems that GET works well so far, but I wonder if there's something else
I should be aware of. Are both methods equivalent?

TIA,

Jorge Alvarez



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Radio Button Returns (Pleasre Read)

2001-03-16 Thread Fred

this is the code:
   $page .= "";

this is the html source generated:


and this is what $pageid returns:
'on'

2 questions is
why? and how do i fix it?

thanks to all who take the time to awnser :-)
~Fred



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] I can't do a connection to POSTGRES from PHP4 as NSAPI

2001-03-16 Thread Martin A. Marques

El Vie 16 Mar 2001 19:53, Norberto Rojas escribió:
> Hi,
>
> I built the latest PHP4to use it as NSAPI with postgress connection:
>
>./configure --with-nsapi=/usr/netscape/server4/
> --with-pgsql=/var/lib/pgsql --enable-libgcc --enable-track-vars
>make
>   make install
>   "stop web server" & "restart"
>
> ,but when I try to pg_connect to postgres, I get the following:
>
> PHP Fatal Error: call to undefined function
>
> : pg_connect line 8

Norberto, check the compilation (make command), because you are simple not 
compiling PHP with postgres support. Check the configure, to see if it really 
finds the postgres distro, or if it checks it, doesn't find it, and says "I 
won't give support for postgres".

> I dont understand why this is happening.
> What can I do? I searched for this error and could not find any help.
>
> Thanks in advance

-- 
System Administration: It's a dirty job, 
but someone told me I had to do it.
-
Martín Marqués  email:  [EMAIL PROTECTED]
Santa Fe - Argentinahttp://math.unl.edu.ar/~martin/
Administrador de sistemas en math.unl.edu.ar
-

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Associative vs normal arrays

2001-03-16 Thread eschmid+sic

On Fri, Mar 16, 2001 at 11:43:17PM +0100, Alexander Wagner wrote:
> Joe wrote:
> > Is there a way to determine if an array is associative or not?  Maybe
> > something similar to the is_array() function ??
> 
> There are only assotiative arrays in PHP.

PHP has associative and numeric (normal) arrays. But is_array() says only
if it is an array or not. The distinction could only be made if you look
at keys. Keys can be integers or strings. I hope this was correct, if not,
Andrei can correct me :)

-Egon

-- 
http://www.linuxtag.de/
http://php.net/books.php 
http://www.concert-band.de/
http://www.php-buch.de/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Associative vs normal arrays

2001-03-16 Thread Joe

Oops, how embarassing :-(
My son must have been playing with it.
Thanks!

- Original Message - 
From: Chris Mulcahy <[EMAIL PROTECTED]>
To: 'Joe' <[EMAIL PROTECTED]>
Sent: Friday, March 16, 2001 3:51 PM
Subject: RE: [PHP] Associative vs normal arrays


> Joe:
> 
> Were you aware your system time was set to March 16, 2018?
> 
> Chris
> 
> -Original Message-
> From: Joe [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2018 3:44 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Associative vs normal arrays
> 
> 
> Is there a way to determine if an array is associative or not?  Maybe
> something similar to the is_array() function ??
> 
> Thanks,
> 
> JOE
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] I can't do a connection to POSTGRES from PHP4 as NSAPI

2001-03-16 Thread Norberto Rojas

Hi,

I built the latest PHP4to use it as NSAPI with postgress connection:

   ./configure --with-nsapi=/usr/netscape/server4/  
--with-pgsql=/var/lib/pgsql --enable-libgcc --enable-track-vars
   make
  make install
  "stop web server" & "restart"

,but when I try to pg_connect to postgres, I get the following:

PHP Fatal Error: call to undefined function 
: pg_connect line 8

I dont understand why this is happening.
What can I do? I searched for this error and could not find any help.

Thanks in advance 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] PHP standalone script

2001-03-16 Thread Meir kriheli

On Friday 16 March 2001 19:31, Don Pro wrote:
> Hi,
>
> I've used PHP scripts in my HTML to provide dynamic content but I was
> wondering if I can also use PHP to create standalone scripts on my UNIX
> box.  If so, where is the PHP interpreter and how do I invoke it?

You should configure and compile PHP as a standalone executeable (without 
--with-apxs or without --with-apache) and in the top of your script you 
should put

#!/usr/bin/php -q

or whatever the path to PHP is (check the output of phpinfo() ).

the -q flag is to supress headers.

-- 
Meir Kriheli

  There's someone in my head, but it's not me - Pink Floyd

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Hello! PHP

2001-03-16 Thread bard

If you want to e mail me privately I'll go into greater detail. 
But, to be brief, let me just say this.

DON'T DO IT.

Use jsp or python or anything else that talks to java. I've tried
every available permutation of php/java on SEVERAL different plat-
forms with simlilarly bad results on all of them.

Just say NO.

Brad

On Fri, 16 Mar 2001, Celestino Roberto Alejandro wrote:

> Hello, i'm working with PHP, and i need use a classes that this company have 
>developed in java, can i use it from php?
> ...yes, i know that i can, but, when i make the configuration of the php.ini, run 
>the hello example, all rights, but, when i make a class
> that use a frame of awt, for show a window, doesn't work, WHY?, the errors are, of 
>Null pointer, and not found classes, but?, i need copy all classes of the basic 
>structure of java, in my java.classpath?...where i can found more info?
> :-)
> Robert 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Associative vs normal arrays

2001-03-16 Thread Alexander Wagner

Joe wrote:
> Is there a way to determine if an array is associative or not?  Maybe
> something similar to the is_array() function ??

There are only assotiative arrays in PHP.

regards
Wagner

-- 
Assumption is the mother of all fuck-ups.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Frames

2001-03-16 Thread Randy Johnson

is there a way in php if a page is supposed to be in frames and the user
tries to view it outside of the frame it automatically reloads the page into
the frame.

thanks

Randy


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Frames

2001-03-16 Thread Randy Johnson

is there a way in php if a page is supposed to be in frames and the user
tries to view it outside of the frame it automatically reloads the page into
the frame.

thanks

Randy


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Login System with access levels

2001-03-16 Thread yavo

"Jordan Elver" <[EMAIL PROTECTED]> wrote in message

01031619280300.01338@localhost">news:01031619280300.01338@localhost...

> Hi,

> I've got a db with a username and password in it. I can let people log in,

> like SELECT * FROM table WHERE username = username AND password =

password.



How about you make another table with permisions and have a many-to-many

relationship with the users table. Then you'll just check if the user has

the given permission. It's harder to do but you'll apresiate the flexibility

it provides.

--yavo




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Login System with access levels

2001-03-16 Thread yavo

"Jordan Elver" <[EMAIL PROTECTED]> wrote in message
01031619280300.01338@localhost">news:01031619280300.01338@localhost...
> Hi,
> I've got a db with a username and password in it. I can let people log in,
> like SELECT * FROM table WHERE username = username AND password =
password.


How about you make another table with permisions and have a many-to-many
relationship with the users table. Then you'll just check if the user has
the given permission. It's harder to do but you'll apresiate the flexibility
it provides.

--yavo



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Associative vs normal arrays

2001-03-16 Thread Joe

Is there a way to determine if an array is associative or not?  Maybe something 
similar to the is_array() function ??

Thanks,

JOE



Re: [PHP] managing image files with PHP/Mysql

2001-03-16 Thread Jack Sasportas

Don't know how to do this, but basically I beleive Java will be the only way to 
execute on the fly and load the image in question so it can be approved so to speak 
which is what I beleive you are trying to do

Good Luck...

Mig wrote:

> Hello, I want to thank Kathleen and other people for ideas about uploading / 
>displaying images using PHP and Mysql.
> I checked these ideas and they work very well, so I will use them into my program. 
>For storing and retrieving image streams, I used addslashes and stripslashes PHP 
>functions.
>
> The only problem still remaining is on client-side point of view. When somebody 
>going to upload file, browsers open little box to let user choose file (type="FILE"...>).
> I wish user to know somewhat is the image he/she is going to upload, so I want to 
>display this image before user uploading. For this action, I would be able to control 
>the 'BROWSE'  button that appears on form.
> Since this button doesn't apply to POST method, nor it will execute function on Form 
>command, how can I control this action?
> Is there some doc explaining features of these objects?
>
> Thanks
>
> Miguel
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

--
___
Jack Sasportas



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Can CONSTANT's be made persistent?

2001-03-16 Thread Aaron Tuller

put your defines in an include that all your pages include.

-aaron

At 2:28 PM -0700 3/16/01, Johnson, Kirk wrote:
>Can a defined()'d CONSTANT be made persistent between pages? According to my
>experiments, the answer is "no". Am I missing something?
>
>TIA
>
>Kirk
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Can CONSTANT's be made persistent?

2001-03-16 Thread Johnson, Kirk

Can a defined()'d CONSTANT be made persistent between pages? According to my
experiments, the answer is "no". Am I missing something?

TIA

Kirk

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Hello! PHP

2001-03-16 Thread Celestino Roberto Alejandro

Hello, i'm working with PHP, and i need use a classes that this company have developed 
in java, can i use it from php?
...yes, i know that i can, but, when i make the configuration of the php.ini, run the 
hello example, all rights, but, when i make a class
that use a frame of awt, for show a window, doesn't work, WHY?, the errors are, of 
Null pointer, and not found classes, but?, i need copy all classes of the basic 
structure of java, in my java.classpath?...where i can found more info?
:-)
Robert 



Re: [PHP] Shopping Carts and Sessions

2001-03-16 Thread DynamicHTML

In a message dated 3/16/01 2:02:07 PM Eastern Standard Time, 
[EMAIL PROTECTED] writes:


> Can this be used via .htaccess in a shared hosting situation?
> 

I believe it can -- never done it personally though...


don



[PHP] managing image files with PHP/Mysql

2001-03-16 Thread Mig

Hello, I want to thank Kathleen and other people for ideas about uploading / 
displaying images using PHP and Mysql.
I checked these ideas and they work very well, so I will use them into my program. For 
storing and retrieving image streams, I used addslashes and stripslashes PHP functions.

The only problem still remaining is on client-side point of view. When somebody going 
to upload file, browsers open little box to let user choose file ().
I wish user to know somewhat is the image he/she is going to upload, so I want to 
display this image before user uploading. For this action, I would be able to control 
the 'BROWSE'  button that appears on form.
Since this button doesn't apply to POST method, nor it will execute function on Form 
command, how can I control this action?
Is there some doc explaining features of these objects?

Thanks

Miguel


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] FileUpload problematic

2001-03-16 Thread Thalis A. Kalfigopoulos

Helloppl,
a problem with a file_upload form :-( Here is what I've done so far:

File test.php which has the form is this:











Here is the included php file (handle_upload.php):
You have succesfully sent the following file:\n";
print "path: $up_file\n";
print "filename: $up_file_name\n";
print "filesize: $up_file_size\n";
print "filetype: $up_file_type\n";
}
?>

When one submits a file (file exists and is within given MAX_FILE_SIZE boundaries), 
the handle_upload.php condition is true, so I get the following output in my browser:

You have succesfully sent the following file:
path: /tmp/phpvtMKjj
filename: test2.jpg
filesize: 27365
filetype: image/jpeg


Then I go and check under /tmp and I do not find anything :-(

I have in my php.ini:

; File Uploads ;

file_uploads= On
upload_tmp_dir  = /tmp
upload_max_filesize = 2M

I am using Apache 1.3.14 with DSO and php is a .so and Php is version 4.0.4

It is not a permissions problem cause I checked the Apache logs, and all dirs that 
need to be accessed are actually writable by the httpd user. I have read through 
"Handling file uploads" (http://www.php.net/manual/it/features.file-upload.php) and I 
don't see what is wrong :-(


thanks ins advance,
thalis


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] dynamic url from MySql field data

2001-03-16 Thread Claudia

I am attempting to create a dynamic url from a field that has the value of
the dynamic url.

Here is the scenario:

1 - Field in MySql database = $logo_link_var =
page.php3?afl=$afl&site=$site&page=contact&ad=$ad_type
2 - Select logo_link_var from database and assign to $logo_link -- code is:

$search_query = "select site.logo_link_var from site where ( $afl =
site.afl_name )";
$result = mysql_query ( $search_query );

$logo_link = mysql_result ( $result, 0, "site.logo_link_var" ); (only 1
record matches query)
$logo = "";

When I click on the link I receive parse errors -- and the window displays
this section in the url:

page.php3?afl=$afl&site=$site&page=contact&ad=$ad_type

The program is not finding the $afl or $site values

if I create the $logo variable as follows -- it works OK.

$logo = "";

Any suggestions?








-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] RE: Bug IDs #8772, #9002, maybe #9724 - session write handler and register_globals

2001-03-16 Thread Jaime Bozza

Hello,
   (Using both 4.0.4pl1 and latest CVS as of today.)  I have been having
similar problems with defining my own session handling routings and
register_globals.  If register_globals is off, a new session doesn't seem to
call the "write" handler, thus the session never gets stored.  With
register_globals=on, the session gets stored correctly.

   I've done some testing and found out a fix to the problems which ends up
being better than keeping register_globals on.  Here's my code for my "read"
handler (PostgreSQL-based).


--
function sess_read($sid) {
global $SESS_DBH;

$qry = "SELECT value FROM sessions WHERE sid = '$sid'";
$qid = pg_exec($SESS_DBH, $qry);

if (pg_numrows($qid) > 0) {
list($value) = pg_fetch_row($qid, 0);
return $value;
}

return "";
}
---

   Originally (last line in function above)[EMAIL PROTECTED], I was
returning a FALSE instead of a blank string.  When I switched over to
returning a blank string (when there wasn't any data in the session
database), my "write" handler gets called correctly.


   I'm not sure if this will fix anybody else's problems, but if you change
your read handler to return a blank string instead of a FALSE condition, it
may start working for you as well!  (If it DOES help you out, please let me
know.)


Jaime Bozza


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard array.c basic_functions.c php_array.h

2001-03-16 Thread Andrei Zmievski

andrei  Fri Mar 16 12:46:35 2001 EDT

  Modified files:  
/php4/ext/standard  array.c basic_functions.c php_array.h 
  Log:
  @- Added array_filter(), which allows filtering of array elements via
  @  the specified callback. (Andrei) 
  
  
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.104 php4/ext/standard/array.c:1.105
--- php4/ext/standard/array.c:1.104 Fri Mar 16 11:51:08 2001
+++ php4/ext/standard/array.c   Fri Mar 16 12:46:33 2001
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.104 2001/03/16 19:51:08 andrei Exp $ */
+/* $Id: array.c,v 1.105 2001/03/16 20:46:33 andrei Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -2887,6 +2887,82 @@

*return_value = *result;
 }
+/* }}} */
+
+
+/* {{{ proto array array_filter(array input [, mixed callback])
+   Filters elements from the array via the callback. */
+PHP_FUNCTION(array_filter)
+{
+   zval **input, **callback = NULL;
+   zval **operand;
+   zval **args[1];
+   zval *retval = NULL;
+   char *callback_name;
+   char *string_key;
+   ulong string_key_len;
+   ulong num_key;
+   HashPosition pos;
+   
+   if (ZEND_NUM_ARGS() < 1 || ZEND_NUM_ARGS() > 2 ||
+   zend_get_parameters_ex(ZEND_NUM_ARGS(), &input, &callback) == FAILURE) 
+{
+   WRONG_PARAM_COUNT;
+   }
+
+   if (Z_TYPE_PP(input) != IS_ARRAY) {
+   php_error(E_WARNING, "%s() expects argument 1 to be an array",
+ get_active_function_name());
+   return;
+   }
+
+   if (ZEND_NUM_ARGS() > 1) {
+   if (!zend_is_callable(*callback, 0, &callback_name)) {
+   php_error(E_WARNING, "%s() expects argument 2, '%s', to be a 
+valid callback",
+ get_active_function_name(), callback_name);
+   efree(callback_name);
+   return;
+   }
+   }
+
+   array_init(return_value);
+   if (zend_hash_num_elements(Z_ARRVAL_PP(input)) == 0)
+   return;
+
+   for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(input), &pos);
+zend_hash_get_current_data_ex(Z_ARRVAL_PP(input), (void **)&operand, 
+&pos) == SUCCESS;
+zend_hash_move_forward_ex(Z_ARRVAL_PP(input), &pos)) {
+
+   if (callback) {
+   args[0] = operand;
+   if (call_user_function_ex(EG(function_table), NULL, *callback, 
+&retval, 1, args, 0, NULL) == SUCCESS && retval) {
+   if (!zend_is_true(retval)) {
+   zval_ptr_dtor(&retval);
+   continue;
+   } else
+   zval_ptr_dtor(&retval);
+   } else {
+   php_error(E_WARNING, "%s() had an error invoking the 
+reduction callback", get_active_function_name());
+   return;
+   }
+   } else if (!zend_is_true(*operand))
+   continue;
+
+   zval_add_ref(operand);
+   switch (zend_hash_get_current_key_ex(Z_ARRVAL_PP(input), &string_key, 
+&string_key_len, &num_key, 0, &pos)) {
+   case HASH_KEY_IS_STRING:
+   zend_hash_update(Z_ARRVAL_P(return_value), string_key,
+string_key_len, 
+operand, sizeof(zval *), NULL);
+   break;
+
+   case HASH_KEY_IS_LONG:
+   zend_hash_index_update(Z_ARRVAL_P(return_value), 
+num_key,
+  operand, 
+sizeof(zval *), NULL);
+   break;
+   }
+   }
+}
+/* }}} */
+
 
 /*
  * Local variables:
Index: php4/ext/standard/basic_functions.c
diff -u php4/ext/standard/basic_functions.c:1.316 
php4/ext/standard/basic_functions.c:1.317
--- php4/ext/standard/basic_functions.c:1.316   Fri Mar 16 10:18:01 2001
+++ php4/ext/standard/basic_functions.c Fri Mar 16 12:46:33 2001
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.316 2001/03/16 18:18:01 sniper Exp $ */
+/* $Id: basic_functions.c,v 1.317 2001/03/16 20:46:33 andrei Exp $ */
 
 #include "php.h"
 #include "php_main.h"
@@ -581,6 +581,7 @@
PHP_FE(array_intersect, NULL)
PHP_FE(array_diff,  
NULL)
PHP_FE(array_sum,   
NULL)
+   PHP_FE(array_filter,   

Re: [PHP] include php3 -vs- 4

2001-03-16 Thread rm

try something like

define("CONFIGURATION", "YES");
in xyz-inc-1.php

if (CONFIGURATION != "YES") {
include("/xyz-inc-1.php");
in the script

--- Jack Sasportas <[EMAIL PROTECTED]>
wrote:
> Is there a workaround under php3 for include_once ?
> 
> Thanks
> 
>
___
> Jack Sasportas
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> To contact the list administrators, e-mail:
> [EMAIL PROTECTED]
> 


__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] include php3 -vs- 4

2001-03-16 Thread Philip Olson

there's a few worthy notes within user comments under include() in manual,
have a look here :

http://www.php.net/manual/en/function.include.php

regards,
philip


On Fri, 16 Mar 2001, Jack Sasportas wrote:

> Is there a workaround under php3 for include_once ?
> 
> Thanks
> 
> ___
> Jack Sasportas
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] include php3 -vs- 4

2001-03-16 Thread Boget, Chris

> Is there a workaround under php3 for include_once ?

if( !$this_include_file_only_variable_declared ) {
  $this_include_file_only_variable_declared = 1;

  // your include script here

}

And if you attempt to include the file more than once
in a script, the IF() will resolve true and skip past the
include script.

Chris



Re: [PHP] RE: [PHP-DB] Login System with access levels

2001-03-16 Thread Jack Sasportas

Just a note...you can hash the password in the database.

Rick Emery wrote:

> First, I would NOT store passwords in a database.  Rather, I'd store a hash
> based upon the password and username.  Storing a password is dangerous as
> regards security.
>
> Second, if you're asking for syntax on how to add the security level column:
>   ALTER TABLE mytable ADD access tinyint unsigned not null default "0";
>
> This will allow you to assigned security levels from 0 to 255.  You would
> set 0 as the lowest level and 255 (admin) as the highest.
>
> While you're at it, add the has security hash entry (discussed above):
>   ALTER TABLE mytable ADD md5hash char(32) not null default "";
>
> Hashes are always 32 characters.
>
> Finally, as far as a query:
>   SELECT * FROM mytable WHERE access <= $level;
>
> This will permit the searcher to locate anything whereby the level is at
> $level or lower.
> -Original Message-
> From: Jordan Elver [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 1:28 PM
> To: PHP General Mailing List; PHP DB Mailing List
> Subject: [PHP-DB] Login System with access levels
>
> Hi,
> I've got a db with a username and password in it. I can let people log in,
> like SELECT * FROM table WHERE username = username AND password = password.
>
> But how can I add an access level column so that I can have different levels
>
> of security. So admin's can read everything, but users can only read certain
>
> sections.
>
> How could I add to my db and structure a query?
>
> Any ideas would be good,
>
> Cheers,
>
> Jord
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

--
___
Jack Sasportas
Innovative Internet Solutions
Phone 305.665.2500
Fax 305.665.2551
www.innovativeinternet.com
www.web56.net



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] include php3 -vs- 4

2001-03-16 Thread Jack Sasportas

Is there a workaround under php3 for include_once ?

Thanks

___
Jack Sasportas



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] inner workings of extract

2001-03-16 Thread dempsejn

Hi all,

I've recently discovered the extract function (thanks to the poster 
regarding it), and have found it to save lots of time. 
I'm having a problem though. 99 times out of 100 when someone thinks 
they've found a "bug" it's actually their misuse of the function, so i'm 
pretty sure this is the case with me. Anyway, here's the deal:

I have a function. Inside this function i have

global $name, $type, $location; (and others)

I make a call to a mysql database and get the result in $result.
Then I used to do this:

$name = $row["name"];
$type = $type["type"];
etc.

extract makes this a lot nicer. However, at the end of this function i 
call another function. This also uses the same global variables. Previous 
this worked fine. But now that i'm using extract, while i do have access 
to the variables in the function, i can't get them in the next. 

My guess is that the way extract works, (somehow, who knows), its 
creating a local variable named $name and setting my info to that, as 
opposed to $name = $row["name"] which sets the global. So, even though i 
can access $name in the function, its lost to the next. 
This isn't a huge issue--i can go back to the old way, or pass the 
variables in the function, but there are enough that i wanted to know if 
anyone else has experienced this. Is there some way to tell extract to 
extract the variables and set the results to the global versions?
Maybe i'm way off and its a small code error, but I really do doubt this, 
as i've commented out lines and gone back and forth and get the same 
result. here's the basic idea though:
function tester(){
global $name;
$row = mysql_fetch_array($sql_result);
$name = $row["name"];
nextone();
/*this works fine, but if i have extract($row) and comment out
the $name = $row["name"] line, then i can't see the variable in the 
next function*/

}
function nextone(){
global $name;
echo $name;
}

any ideas?

thanks,
jack



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] XML Newbie.!

2001-03-16 Thread Diego Fulgueira

Hi! Ok, this is not a question about PHP, but since this is such a great
discussion forum, I am certain it is a good place to get started with a new
technology.

The thing is I have a DTD specification and I want to translate it into a DB
schema, and then create an "add-delete-modify" application.

OK!! It might seem I am asking too much, but I don´t even know if this can
be done, so any comments will appreciated. It would be great if you just
gave me a link to a good XML and DTD tutorial.

I also want to know if I can create XML documents with PHP, what kind of
software do i need to parse those documents, and how can I put the data in
my DB. Any clue, and I mean ANY, will be appreciated.

THANKS A LOT IN ADVANCE!
Cheers, Diego.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] XML Newbie. HELP!

2001-03-16 Thread Diego Fulgueira

Hi! Ok, this is not a question about PHP, but since this is such a great
discussion forum, I am certain it is a good place to get started with a new
technology.

The thing is I have a DTD specification and I want to translate it into a DB
schema, and then create an "add-delete-modify" application.

OK!! It might seem I am asking too much, but I don´t even know if this can
be done, so any comments will appreciated. It would be great if you just
gave me a link to a good XML and DTD tutorial.

I also want to know if I can create XML documents with PHP, what kind of
software do i need to parse those documents, and how can I put the data in
my DB. Any clue, and I mean ANY, will be appreciated.

THANKS A LOT IN ADVANCE!
Cheers, Diego.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] RE: [PHP-DB] Login System with access levels

2001-03-16 Thread Rick Emery

First, I would NOT store passwords in a database.  Rather, I'd store a hash
based upon the password and username.  Storing a password is dangerous as
regards security.

Second, if you're asking for syntax on how to add the security level column:
  ALTER TABLE mytable ADD access tinyint unsigned not null default "0";

This will allow you to assigned security levels from 0 to 255.  You would
set 0 as the lowest level and 255 (admin) as the highest.

While you're at it, add the has security hash entry (discussed above):
  ALTER TABLE mytable ADD md5hash char(32) not null default "";

Hashes are always 32 characters.

Finally, as far as a query:
  SELECT * FROM mytable WHERE access <= $level;

This will permit the searcher to locate anything whereby the level is at
$level or lower.
-Original Message-
From: Jordan Elver [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 16, 2001 1:28 PM
To: PHP General Mailing List; PHP DB Mailing List
Subject: [PHP-DB] Login System with access levels


Hi,
I've got a db with a username and password in it. I can let people log in, 
like SELECT * FROM table WHERE username = username AND password = password.

But how can I add an access level column so that I can have different levels

of security. So admin's can read everything, but users can only read certain

sections. 

How could I add to my db and structure a query? 

Any ideas would be good, 

Cheers,

Jord

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard array.c

2001-03-16 Thread Andrei Zmievski

andrei  Fri Mar 16 11:51:08 2001 EDT

  Modified files:  
/php4/ext/standard  array.c 
  Log:
  All user callbacks should be to EG(function_table).
  
  
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.103 php4/ext/standard/array.c:1.104
--- php4/ext/standard/array.c:1.103 Fri Mar 16 11:48:40 2001
+++ php4/ext/standard/array.c   Fri Mar 16 11:51:08 2001
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.103 2001/03/16 19:48:40 fmk Exp $ */
+/* $Id: array.c,v 1.104 2001/03/16 19:51:08 andrei Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -521,7 +521,7 @@
Bucket *s;
pval **args[2];
pval *retval_ptr;
-   CLS_FETCH();
+   ELS_FETCH();
BLS_FETCH();
 
f = *((Bucket **) a);
@@ -530,7 +530,7 @@
args[0] = (pval **) f->pData;
args[1] = (pval **) s->pData;
 
-   if (call_user_function_ex(CG(function_table), NULL, 
*BG(user_compare_func_name), &retval_ptr, 2, args, 0, NULL)==SUCCESS
+   if (call_user_function_ex(EG(function_table), NULL, 
+*BG(user_compare_func_name), &retval_ptr, 2, args, 0, NULL)==SUCCESS
&& retval_ptr) {
long retval;
 
@@ -609,7 +609,7 @@
pval *args[2];
pval retval;
int status;
-   CLS_FETCH();
+   ELS_FETCH();
BLS_FETCH();
 
args[0] = &key1;
@@ -637,7 +637,7 @@
Z_TYPE(key2) = IS_LONG;
}
 
-   status = call_user_function(CG(function_table), NULL, 
*BG(user_compare_func_name), &retval, 2, args);
+   status = call_user_function(EG(function_table), NULL, 
+*BG(user_compare_func_name), &retval, 2, args);

zval_dtor(&key1);
zval_dtor(&key2);
@@ -958,7 +958,6 @@
ulong  num_key;
HashPosition pos;
BLS_FETCH();
-   CLS_FETCH();
ELS_FETCH();
 
/* Allocate space for key */



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Login System with access levels

2001-03-16 Thread Pierre-Yves Lemaire


One solution:
You set up a separate table:
user_level { level_id (unsigned int), level_description (varchar 100 )}

it looks like this:
level_idlevel_description
100 admin
200user

In your user table you add level_id as a field.
After a good validation of the user (username and password), you grab the
level_id
and make a session variable out of it.

Than in you page you decide what you show or not to the user based upon the
level_id

if( $level_id <= 100 ){
show link for admin
}
if( $level_id >= 101 && $level_id <= 200 ){
show link for user
}

Having another table and separating the id by a hundred number lets you add
more security level as the site grows.

This is one solution, I am shure there is many more and I would
like to see what other people do as well...

py





- Original Message -
From: Jordan Elver <[EMAIL PROTECTED]>
To: PHP General Mailing List <[EMAIL PROTECTED]>; PHP DB Mailing
List <[EMAIL PROTECTED]>
Sent: Friday, March 16, 2001 7:28 PM
Subject: [PHP] Login System with access levels


> Hi,
> I've got a db with a username and password in it. I can let people log in,
> like SELECT * FROM table WHERE username = username AND password =
password.
>
> But how can I add an access level column so that I can have different
levels
> of security. So admin's can read everything, but users can only read
certain
> sections.
>
> How could I add to my db and structure a query?
>
> Any ideas would be good,
>
> Cheers,
>
> Jord
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard array.c

2001-03-16 Thread Frank M. Kromann

fmk Fri Mar 16 11:48:40 2001 EDT

  Modified files:  
/php4/ext/standard  array.c 
  Log:
  Fixing build on Win32 by adding missing   BLS_FETCH();
  
  
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.102 php4/ext/standard/array.c:1.103
--- php4/ext/standard/array.c:1.102 Fri Mar 16 11:29:23 2001
+++ php4/ext/standard/array.c   Fri Mar 16 11:48:40 2001
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.102 2001/03/16 19:29:23 andrei Exp $ */
+/* $Id: array.c,v 1.103 2001/03/16 19:48:40 fmk Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -957,6 +957,7 @@
ulong  string_key_len;
ulong  num_key;
HashPosition pos;
+   BLS_FETCH();
CLS_FETCH();
ELS_FETCH();
 



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Can you recommend an ISP with the following?

2001-03-16 Thread Boaz Yahav

Check out : 

http://www.weberdev.com/index.php3?GoTo=phenominet/prices.htm

This is your one stop shop for hosting. WeberDev.com is hosted there
and I can tell you that their service is amazing. They are fast, reliable
and more than anything, very professional (specially in PHP / MySQL).

Sincerely

  berber

Visit http://www.weberdev.com Today!!! 
To see where PHP might take you tomorrow.


-Original Message-
From: Jamie Jackson [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 16, 2001 5:45 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Can you recommend an ISP with the following?


I'm looking to move from an old Web host (stormweb.net) that has
entirely stopped responding to customer support emails. I liked what
they had to offer, before they became unresponsive, so I'm looking for
a similar ISP with:

*PHP4
*MySQL
*Telnet access
*Decent Support
*Preferably a Cobalt server (or one with a VERY good Web-based
administrator, most other types of Web administrators I've seen have
been clunky and a PITA)
*Pretty Cheap

I've checked out ISP check, and it would be great if they listed the
type of Wed-based administrator, but they don't. It's VERY tedious to
get a demo account, and see that their Web-based administrator is
junk. I'm used to the very slick administrator found on Cobalt
servers. I have given up after a half-dozen attempts at other servers.
I sincerely hope someone can help.

Thank you very much,
Jamie

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard array.c

2001-03-16 Thread Andrei Zmievski

andrei  Fri Mar 16 11:29:23 2001 EDT

  Modified files:  
/php4/ext/standard  array.c 
  Log:
  @- Fixed all relevant array functions to avoid moving the internal array
  @ pointer during operations. (Andrei)
  
  

Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.101 php4/ext/standard/array.c:1.102
--- php4/ext/standard/array.c:1.101 Mon Mar 12 02:14:00 2001
+++ php4/ext/standard/array.c   Fri Mar 16 11:29:23 2001
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.101 2001/03/12 10:14:00 stas Exp $ */
+/* $Id: array.c,v 1.102 2001/03/16 19:29:23 andrei Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -954,9 +954,11 @@
  *retval_ptr,  /* Return value - unused */
  *key; /* Entry key */
char  *string_key;
+   ulong  string_key_len;
ulong  num_key;
+   HashPosition pos;
CLS_FETCH();
-   BLS_FETCH();
+   ELS_FETCH();
 
/* Allocate space for key */
MAKE_STD_ZVAL(key);
@@ -965,22 +967,22 @@
args[1] = &key;
args[2] = userdata;
 
-   zend_hash_internal_pointer_reset(target_hash);
+   zend_hash_internal_pointer_reset_ex(target_hash, &pos);
 
/* Iterate through hash */
-   while(zend_hash_get_current_data(target_hash, (void **)&args[0]) == SUCCESS) {
+   while(zend_hash_get_current_data_ex(target_hash, (void **)&args[0], &pos) == 
+SUCCESS) {
/* Set up the key */
-   if (zend_hash_get_current_key(target_hash, &string_key, &num_key, 1) 
== HASH_KEY_IS_LONG) {
+   if (zend_hash_get_current_key_ex(target_hash, &string_key, 
+&string_key_len, &num_key, 0, &pos) == HASH_KEY_IS_LONG) {
Z_TYPE_P(key) = IS_LONG;
Z_LVAL_P(key) = num_key;
} else {
Z_TYPE_P(key) = IS_STRING;
Z_STRVAL_P(key) = string_key;
-   Z_STRLEN_P(key) = strlen(string_key);
+   Z_STRLEN_P(key) = string_key_len-1;
}

/* Call the userland function */
-   if (call_user_function_ex(CG(function_table), NULL, 
*BG(array_walk_func_name),
+   if (call_user_function_ex(EG(function_table), NULL, 
+*BG(array_walk_func_name),
   &retval_ptr, userdata ? 3 : 2, 
args, 0, NULL) == SUCCESS) {

zval_ptr_dtor(&retval_ptr);
@@ -988,11 +990,7 @@
php_error(E_WARNING,"Unable to call %s() - function does not 
exist",
  (*BG(array_walk_func_name))->value.str.val);
 
-   /* Clean up the key */
-   if (zend_hash_get_current_key_type(target_hash) == HASH_KEY_IS_STRING)
-   efree(Z_STRVAL_P(key));
-   
-   zend_hash_move_forward(target_hash);
+   zend_hash_move_forward_ex(target_hash, &pos);
 }
efree(key);

@@ -1156,6 +1154,7 @@
char *var_name, *final_name;
ulong num_key, var_name_len;
int var_exists, extract_type, key_type, count = 0;
+   HashPosition pos;
 
switch(ZEND_NUM_ARGS()) {
case 1:
@@ -1204,9 +1203,9 @@
return;
}

-   zend_hash_internal_pointer_reset(Z_ARRVAL_PP(var_array));
-   while(zend_hash_get_current_data(Z_ARRVAL_PP(var_array), (void **)&entry) == 
SUCCESS) {
-   key_type = zend_hash_get_current_key_ex(Z_ARRVAL_PP(var_array), 
&var_name, &var_name_len, &num_key, 0, NULL);
+   zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(var_array), &pos);
+   while(zend_hash_get_current_data_ex(Z_ARRVAL_PP(var_array), (void **)&entry, 
+&pos) == SUCCESS) {
+   key_type = zend_hash_get_current_key_ex(Z_ARRVAL_PP(var_array), 
+&var_name, &var_name_len, &num_key, 0, &pos);
final_name = NULL;
var_exists = 0;
 
@@ -1217,7 +1216,7 @@
final_name = emalloc(MAX_LENGTH_OF_LONG + Z_STRLEN_PP(prefix) 
+ 2);
zend_sprintf(final_name, "%s_%ld", Z_STRVAL_PP(prefix), 
num_key);
} else {
-   zend_hash_move_forward(Z_ARRVAL_PP(var_array));
+   zend_hash_move_forward_ex(Z_ARRVAL_PP(var_array), &pos);
continue;
}

@@ -1271,7 +1270,7 @@
efree(final_name);
}
 
-   zend_hash_move_forward(Z_ARRVAL_PP(var_array));
+   zend_hash_move_forward_ex(Z_ARRVAL_PP(var_array), &pos);
}
 
RETURN_LONG(count);
@@ -1279,8 +1278,7 @@
 /* }}} */
 
 
-/* {{{ void _compact_var(HashTable *eg_active_symbol_table, zval *return

[PHP] Login System with access levels

2001-03-16 Thread Jordan Elver

Hi,
I've got a db with a username and password in it. I can let people log in, 
like SELECT * FROM table WHERE username = username AND password = password.

But how can I add an access level column so that I can have different levels 
of security. So admin's can read everything, but users can only read certain  
sections. 

How could I add to my db and structure a query? 

Any ideas would be good, 

Cheers,

Jord

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Shopping Carts and Sessions

2001-03-16 Thread Data Driven Design

Can this be used via .htaccess in a shared hosting situation?

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, March 16, 2001 10:15 AM
Subject: Re: [PHP] Shopping Carts and Sessions


> In a message dated 3/16/01 9:39:16 AM Eastern Standard Time,
> [EMAIL PROTECTED] writes:
>
>
> > I thought Search engines couldnt spyder dynamic pages such as
> > "1.php?foo=bar"
> >
>
> True - but with the magic of Apache's mod_rewrite -- you can make a URL
> appear to a browser as: http://www.yourdomain.com/bar -- but on your
server,
> it can be rewritten as: http://www.yourdomain.com/1.php?foo=bar.
>
> mod_rewrite is extremely cool. you can read more about it at:
> http://httpd.apache.org/docs/mod/mod_rewrite.html
>
> don
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] phpinfo() displayed old info

2001-03-16 Thread harun

I've migrated from apache 1.3.12 + php 3.0.16 
to apache 1.3.19 + php 4.0.2. 
but 
 
still displaying old info like : 
Configure Command : ./configure' '--with-mysql=/usr/local/mysql' 
'--with-apache=../apache_1.3.12'  
Apache Version : Apache/1.3.12 
some informations displayed correcly : 
page title : PHP Version 4.0.2 
SERVER_SOFTWARE : Apache/1.3.19 (Unix) PHP/4.0.2 
help me, please. 
--revina-- 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] echo only displays first character

2001-03-16 Thread Mal McKay

Are you sure $name is an array. t appears to be a string and the $name[$i]
references one character in that string

mal

-Original Message-
From: Tom Harris [mailto:[EMAIL PROTECTED]]
Sent: 16 March 2001 15:50
To: [EMAIL PROTECTED]
Subject: [PHP] echo only displays first character


Here's an interesting problem.

The following only prints the first letter of the name

for ($i=0; isset($empid[$i]); $i++) {

echo "$empid[$i] $name[$i]";

}

But if I change the variable $name to $employeename throughout the script it
displays fine.

$empid[] and $name[] are both assigned earlier in the script by pulling data
from a MySQL database.

Is $name a reserved word or something? Anyone know why just changing the
array's name fixes the problem?

Thanks,

-Tom



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] phpinfo() displayed old info

2001-03-16 Thread Revina

I've migrated from apache 1.3.12 + php 3.0.16
to apache 1.3.19 + php 4.0.2.
but

still displaying old info like :
Configure Command : ./configure' '--with-mysql=/usr/local/mysql' 
'--with-apache=../apache_1.3.12' 
Apache Version : Apache/1.3.12
some informations displayed correcly :
page title : PHP Version 4.0.2
SERVER_SOFTWARE : Apache/1.3.19 (Unix) PHP/4.0.2
help me, please. 

 --revina-- 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] phpinfo() displayed old info

2001-03-16 Thread Revina

I'va migrated from apache 1.3.12 + php 3.0.16
to apache 1.3.19 + php 4.0.2.
but

still displaying old info like :
Configure Command : ./configure' '--with-mysql=/usr/local/mysql' 
'--with-apache=../apache_1.3.12' 
Apache Version : Apache/1.3.12
some informations displayed correcly :
page title : PHP Version 4.0.2
SERVER_SOFTWARE : Apache/1.3.19 (Unix) PHP/4.0.2 

help me, please. 

 --revin-- 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Problem with VARIABLES

2001-03-16 Thread Hardy Merrill

Ian, I think what you want is a variable variable - have a look at

   http://www.php.net/manual/en/html/language.variables.variable.html

I think you might want something like this:

   ${$Color$Temp[$f]}

HTH.

-- 
Hardy Merrill
Mission Critical Linux, Inc.
http://www.missioncriticallinux.com

Ian LeBlanc [[EMAIL PROTECTED]] wrote:
> I have this page where I am printing some items that are defined by size 
> and color which all the info is pulled from a database.
> 
> in the first item loop
> PRINT ("\n");
> translated looks like this.
> 
> 
> meaning the color white and the size Small.
> 
> Now the next loop does what it is suppose to and returns a value of
> 
> 
> These get posted to the next page.
> Now for the PROBLEM
> 
> without hard coding it how can I get the value of BlackS
> meaning I know the color and sizes but how do I put the variable together 
> to print the value of it.
> 
> On the 2nd page I would like to echo $Color$Temp[$f] but that does not 
> return the value of the item.
> I need $Color$Temp[$f] to turn into the variable not a value. So I can echo 
> the variable.
> Someone please help.
> 
> (*NOTE* the reason I do not want to hard code it is that I have a list of 
> 102 colors which makes for a really long script.)
> 
> PLEASE CC ME ON THE MESSAGE BECAUSE I AM ONLY SUBSCRIBED TO THE DIGEST (I 
> will have to wait some 12 odd hours for the answer)
> Regards,
> 
> Ian LeBlanc
> Web Development
> Rask, Inc. - www.rask.com
> Phone: (727) 517-2000
> Fax:   (727) 517-2001
> 
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Putting php at end of html?

2001-03-16 Thread Boget, Chris

> YES!
> The only "problem" will be that these .php pages will be 
> maybe 5% slower since PHP is "parsing" them.

That and all the links pointing to the old .html files will be
broken...

So if you mix PHP and HTML in a file, PHP will be slower
to parse those files?  I thought it was smart enough to 
parse only what was within the recognized start and end
tags (, , ,
etc)?

Chris



Re: [PHP] Shopping Carts and Sessions

2001-03-16 Thread Aaron Tuller

or you can use Apache to ForceType bar to use PHP.

then just write a generic URL parsing script and you're done.

if you want it for all of your URL's, make DocumentRoot a PHP script. 
you might tricky problems with images and other non-script files, but 
that's ok because you can just check for the file extensions, echo he 
mie tpye and readfile() it.

-aaron

At 1:15 PM -0500 3/16/01, [EMAIL PROTECTED] wrote:
>In a message dated 3/16/01 9:39:16 AM Eastern Standard Time,
>[EMAIL PROTECTED] writes:
>
>
>>  I thought Search engines couldnt spyder dynamic pages such as
>>  "1.php?foo=bar"
>>
>
>True - but with the magic of Apache's mod_rewrite -- you can make a URL
>appear to a browser as: http://www.yourdomain.com/bar -- but on your server,
>it can be rewritten as: http://www.yourdomain.com/1.php?foo=bar.
>
>mod_rewrite is extremely cool. you can read more about it at:
>http://httpd.apache.org/docs/mod/mod_rewrite.html
>
>don


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/standard basic_functions.c

2001-03-16 Thread Jani Taskinen

sniper  Fri Mar 16 10:18:02 2001 EDT

  Modified files:  
/php4/ext/standard  basic_functions.c 
  Log:
  This has got to be the last one..
  
Index: php4/ext/standard/basic_functions.c
diff -u php4/ext/standard/basic_functions.c:1.315 
php4/ext/standard/basic_functions.c:1.316
--- php4/ext/standard/basic_functions.c:1.315   Sun Mar 11 19:06:53 2001
+++ php4/ext/standard/basic_functions.c Fri Mar 16 10:18:01 2001
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.315 2001/03/12 03:06:53 andrei Exp $ */
+/* $Id: basic_functions.c,v 1.316 2001/03/16 18:18:01 sniper Exp $ */
 
 #include "php.h"
 #include "php_main.h"
@@ -247,7 +247,7 @@
PHP_FE(gethostbyaddr,   NULL)
PHP_FE(gethostbyname,   NULL)
PHP_FE(gethostbynamel,  NULL)
-#if HAVE_LIBBIND && !(defined(__BEOS__)||defined(PHP_WIN32))
+#if HAVE_RES_SEARCH && !(defined(__BEOS__)||defined(PHP_WIN32))
PHP_FE(checkdnsrr, 
 NULL)
PHP_FE(getmxrr,
 second_and_third_args_force_ref)
 #else



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Shopping Carts and Sessions

2001-03-16 Thread DynamicHTML

In a message dated 3/16/01 9:39:16 AM Eastern Standard Time, 
[EMAIL PROTECTED] writes:


> I thought Search engines couldnt spyder dynamic pages such as
> "1.php?foo=bar"
> 

True - but with the magic of Apache's mod_rewrite -- you can make a URL 
appear to a browser as: http://www.yourdomain.com/bar -- but on your server, 
it can be rewritten as: http://www.yourdomain.com/1.php?foo=bar.

mod_rewrite is extremely cool. you can read more about it at: 
http://httpd.apache.org/docs/mod/mod_rewrite.html

don



RE: [PHP] With all this talk about editors ...

2001-03-16 Thread Boget, Chris

> http://www.php.net/manual/en/ref.funchand.php
> This page must be your friends.

I took a look at this page (and all the functions referenced
therein).  While there must be a use for these functions
otherwise they wouldn't have been included in PHP, I'm at
a total loss as to why anyone would ever use them.  Why
wouldn't you just call the function (or do whatever) yourself?
Could anyone offer some insight?

Chris



[PHP] Problem with VARIABLES

2001-03-16 Thread Ian LeBlanc

I have this page where I am printing some items that are defined by size 
and color which all the info is pulled from a database.

in the first item loop
PRINT ("\n");
translated looks like this.


meaning the color white and the size Small.

Now the next loop does what it is suppose to and returns a value of


These get posted to the next page.
Now for the PROBLEM

without hard coding it how can I get the value of BlackS
meaning I know the color and sizes but how do I put the variable together 
to print the value of it.

On the 2nd page I would like to echo $Color$Temp[$f] but that does not 
return the value of the item.
I need $Color$Temp[$f] to turn into the variable not a value. So I can echo 
the variable.
Someone please help.

(*NOTE* the reason I do not want to hard code it is that I have a list of 
102 colors which makes for a really long script.)

PLEASE CC ME ON THE MESSAGE BECAUSE I AM ONLY SUBSCRIBED TO THE DIGEST (I 
will have to wait some 12 odd hours for the answer)
Regards,

Ian LeBlanc
Web Development
Rask, Inc. - www.rask.com
Phone: (727) 517-2000
Fax:   (727) 517-2001




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Can you recommend an ISP with the following?

2001-03-16 Thread Brett



> I'm looking to move from an old Web host (stormweb.net) that has
> entirely stopped responding to customer support emails. I liked what
> they had to offer, before they became unresponsive, so I'm looking for
> a similar ISP with:
>

I would  do a search on google for cobalt virtual hosts.  If you want my
recommendation, I have been using Interliant for a year now for co-location.
They have excellent support, offer Cobalt RAQs virtual hosting, and have
great connection speeds and uptime.

Brett




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] $PHP_SELF vs. functions, arrays and variable

2001-03-16 Thread John Lim

Hi Scott,

Good question! $PHP_SELF is a global variable, so you need to declare it in
functions:

function a()
{ 
global $PHP_SELF;

print $PHP_SELF;
}

John

"Scott Fletcher" <[EMAIL PROTECTED]> wrote in message 
98tjgv$40e$[EMAIL PROTECTED]">news:98tjgv$40e$[EMAIL PROTECTED]...
> Hi!
> 
> I noticed when using $PHP_SELF in the script, you can use only the
> variables.  So, I tried it with the arrays or functions and found that it
> does not work.  So, is $PHP_SELF limited to variables only?
> 
> Scott
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] $PHP_SELF vs. functions, arrays and variable

2001-03-16 Thread Scott Fletcher

Hi!

I noticed when using $PHP_SELF in the script, you can use only the
variables.  So, I tried it with the arrays or functions and found that it
does not work.  So, is $PHP_SELF limited to variables only?

Scott



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/hyperwave hg_comm.c hg_comm.h

2001-03-16 Thread Uwe Steinmann

steinm  Fri Mar 16 09:40:38 2001 EDT

  Modified files:  
/php4/ext/hyperwave hg_comm.c hg_comm.h 
  Log:
  - Inserting links without any delimiters is now possible
  
  
Index: php4/ext/hyperwave/hg_comm.c
diff -u php4/ext/hyperwave/hg_comm.c:1.39 php4/ext/hyperwave/hg_comm.c:1.40
--- php4/ext/hyperwave/hg_comm.c:1.39   Sun Feb 25 22:06:57 2001
+++ php4/ext/hyperwave/hg_comm.cFri Mar 16 09:40:37 2001
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: hg_comm.c,v 1.39 2001/02/26 06:06:57 andi Exp $ */
+/* $Id: hg_comm.c,v 1.40 2001/03/16 17:40:37 steinm Exp $ */
 
 /* #define HW_DEBUG */
 
@@ -523,6 +523,19 @@
if(strncmp(str, "background", 10) == 0)

cur_ptr->linktype=HW_BACKGROUND_LINK;
else
+   if(strncmp(str, "intagnodel", 10) == 
+0) { /* New type introduced by Uwe Steinmann 16.03.2001 */
+   
+cur_ptr->linktype=HW_INTAGNODEL_LINK;
+   cur_ptr->tagattr = NULL;
+   if(NULL != (str = 
+strstr(object, "TagAttr="))) {
+   str += 8;
+   str1 = str;
+   while((*str1 != '\n') 
+&& (*str1 != '\0'))
+   str1++;
+   cur_ptr->tagattr = 
+emalloc(str1 - str + 1);
+   
+memcpy(cur_ptr->tagattr, str, str1 - str);
+   cur_ptr->tagattr[str1 
+- str] = '\0';
+   }
+   } else
if(strncmp(str, "intag", 5) == 0) {

cur_ptr->linktype=HW_INTAG_LINK;
cur_ptr->tagattr = NULL;
@@ -695,6 +708,11 @@
offset -= 4; /* because there is no 
closing tag  */
 /* laststart = cur_ptr->start; */
break;
+   case HW_INTAGNODEL_LINK:
+   snprintf(istr, BUFFERLEN, "%s", 
+cur_ptr->link);
+   offset -= 4; /* because there is no 
+closing tag  */
+/* laststart = cur_ptr->start; */
+   break;
case HW_APPLET_LINK:
if(cur_ptr->codebase)
  snprintf(istr, BUFFERLEN, " 
CODEBASE='%s' CODE='%s'", cur_ptr->codebase, cur_ptr->code);
@@ -727,7 +745,10 @@
else
snprintf(istr, BUFFERLEN, " 
%s='%s/%s'", cur_ptr->tagattr, scriptname[HW_INTAG_LINK], cur_ptr->destdocname); 
offset -= 4; /* because there is no 
closing tag  */
-/* laststart = cur_ptr->start; */
+   break;
+   case HW_INTAGNODEL_LINK:
+   snprintf(istr, BUFFERLEN, "%s", 
+cur_ptr->destdocname);
+   offset -= 4; /* because there is no 
+closing tag  */
break;
case HW_APPLET_LINK:
if(cur_ptr->codebase)
Index: php4/ext/hyperwave/hg_comm.h
diff -u php4/ext/hyperwave/hg_comm.h:1.13 php4/ext/hyperwave/hg_comm.h:1.14
--- php4/ext/hyperwave/hg_comm.h:1.13   Sun Feb 25 22:06:57 2001
+++ php4/ext/hyperwave/hg_comm.hFri Mar 16 09:40:37 2001
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: hg_comm.h,v 1.13 2001/02/26 06:06:57 andi Exp $ */
+/* $Id: hg_comm.h,v 1.14 2001/03/16 17:40:37 steinm Exp $ */
 
 #ifndef HG_COMM_H
 #define HG_COMM_H
@@ -85,6 +85,7 @@
 #define HW_BACKGROUND_LINK2
 #define HW_INTAG_LINK 3
 #define HW_APPLET_LINK4
+#define HW_INTAGNODEL_LINK5
 
 #define COPY  0
 #de

[PHP] PHP standalone script

2001-03-16 Thread Don Pro

Hi,

I've used PHP scripts in my HTML to provide dynamic content but I was
wondering if I can also use PHP to create standalone scripts on my UNIX
box.  If so, where is the PHP interpreter and how do I invoke it?


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /tests .cvsignore

2001-03-16 Thread Jani Taskinen

sniper  Fri Mar 16 09:10:46 2001 EDT

  Modified files:  
/php4/tests .cvsignore 
  Log:
  .php files should not be ignored. Typo?
  
Index: php4/tests/.cvsignore
diff -u php4/tests/.cvsignore:1.1 php4/tests/.cvsignore:1.2
--- php4/tests/.cvsignore:1.1   Tue Nov 21 00:00:13 2000
+++ php4/tests/.cvsignore   Fri Mar 16 09:10:46 2001
@@ -1,4 +1,3 @@
 *.exp
 *.out
-*.php
 phpt.*



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] passing variables using hidden fields

2001-03-16 Thread george

 Thanks Chris.

George



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] sendmail

2001-03-16 Thread Marius Kirschner

Damn, the "-t -i" did the trick  I can't believe the fix was so easy and
I spent DAYS (really) trying to figure out what's wrong!  Thanks so much,
Robert. :)

---Marius

> -Original Message-
> From: Robert Covell [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 11:41 AM
> To: Marius Kirschner; [EMAIL PROTECTED]
> Subject: RE: [PHP] sendmail
>
>
> Do you have the switches for sendmail in your path?
>
> Our installs have: /usr/sbin/sendmail -t -i for the path information...
>
> Sincerely,
>
> Robert T. Covell
> President / Owner
> Rolet Internet Services, LLC
> Web: www.rolet.com
> Email: [EMAIL PROTECTED]
> Phone: 816.210.7145
> Fax: 816.753.1952
>
> -Original Message-
> From: Marius Kirschner [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 10:43 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] sendmail
>
>
> I'm at a lossI've searched throught the knowledgebase, archives, docs,
> etc but I can't figure out what's going on.  The problem is when using the
> mail() function nothing gets send and I don't get any error
> messages either.
> It's like the message gets eaten by a black hole.
>
> I'm running PHP4 on a BSDI 3.1 box with Apache 3.9 and sendmail 8.9.3, my
> php.ini file has the "sendmail_path   =   /usr/sbin/sendmail"
> in there,
> but still when I click on submit nothing gets send.  I know the script is
> working (works on another system) plus I've tried other "form
> mailers" with
> the same problem.  Does anybody have some clue as to where I should start
> looking to fix this?  Thanks,
>
> ---Marius
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] sendmail

2001-03-16 Thread Robert Covell

Do you have the switches for sendmail in your path?

Our installs have: /usr/sbin/sendmail -t -i for the path information...

Sincerely,

Robert T. Covell
President / Owner
Rolet Internet Services, LLC
Web: www.rolet.com
Email: [EMAIL PROTECTED]
Phone: 816.210.7145
Fax: 816.753.1952

-Original Message-
From: Marius Kirschner [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 16, 2001 10:43 AM
To: [EMAIL PROTECTED]
Subject: [PHP] sendmail


I'm at a lossI've searched throught the knowledgebase, archives, docs,
etc but I can't figure out what's going on.  The problem is when using the
mail() function nothing gets send and I don't get any error messages either.
It's like the message gets eaten by a black hole.

I'm running PHP4 on a BSDI 3.1 box with Apache 3.9 and sendmail 8.9.3, my
php.ini file has the "sendmail_path   =   /usr/sbin/sendmail" in there,
but still when I click on submit nothing gets send.  I know the script is
working (works on another system) plus I've tried other "form mailers" with
the same problem.  Does anybody have some clue as to where I should start
looking to fix this?  Thanks,

---Marius


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] sendmail

2001-03-16 Thread Marius Kirschner

I'm at a lossI've searched throught the knowledgebase, archives, docs,
etc but I can't figure out what's going on.  The problem is when using the
mail() function nothing gets send and I don't get any error messages either.
It's like the message gets eaten by a black hole.

I'm running PHP4 on a BSDI 3.1 box with Apache 3.9 and sendmail 8.9.3, my
php.ini file has the "sendmail_path   =   /usr/sbin/sendmail" in there,
but still when I click on submit nothing gets send.  I know the script is
working (works on another system) plus I've tried other "form mailers" with
the same problem.  Does anybody have some clue as to where I should start
looking to fix this?  Thanks,

---Marius


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Can you recommend an ISP with the following?

2001-03-16 Thread Jamie Jackson

The biggies are:
*An intuitive email config interface, with list management, aliases,
etc.
*Ability to "sub-let" out webspace/ftp area to people ("users"
directories)
*Web-space administration and monitoring (to regulate "sub"-users'
webspace)
*Good backup system. (RAQs let you download a compressed backup, which
can be easily uploaded, and reverted to).

Cobalt servers do these things.

Jamie

On 16 Mar 2001 08:10:24 -0800, [EMAIL PROTECTED] ("John Huggins")
wrote:

>You mention a large desire for a good web based administrator.  I wonder if
>there is a version of a web based system administrator available that works
>like Cobalt, but can be installed on any hosting setup.  Have you folks
>heard of such a thing?  I am aware of Webmin, but am not too impressed with
>it yet.
>
>I have toyed with the idea of writing my own.  Jamie, what items do you feel
>must be controllable in a web hosting account administration panel?  Yes, we
>all know the basics, like email, dns, etc. but a bulleted list would be a
>good start at organizing a development effort.
>
>John
>
>> -Original Message-
>> From: Jamie Jackson [mailto:[EMAIL PROTECTED]]
>> Sent: Friday, March 16, 2001 10:45 AM
>> To: [EMAIL PROTECTED]
>> Subject: [PHP] Can you recommend an ISP with the following?
>>
>>
>> I'm looking to move from an old Web host (stormweb.net) that has
>> entirely stopped responding to customer support emails. I liked what
>> they had to offer, before they became unresponsive, so I'm looking for
>> a similar ISP with:
>>
>> *PHP4
>> *MySQL
>> *Telnet access
>> *Decent Support
>> *Preferably a Cobalt server (or one with a VERY good Web-based
>> administrator, most other types of Web administrators I've seen have
>> been clunky and a PITA)
>> *Pretty Cheap
>>
>> I've checked out ISP check, and it would be great if they listed the
>> type of Wed-based administrator, but they don't. It's VERY tedious to
>> get a demo account, and see that their Web-based administrator is
>> junk. I'm used to the very slick administrator found on Cobalt
>> servers. I have given up after a half-dozen attempts at other servers.
>> I sincerely hope someone can help.
>>
>> Thank you very much,
>> Jamie
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Webmin

2001-03-16 Thread Michael Kimsal

Although I somewhat agree with the webmin sentiment,
after having tried to do simple maintenance on a cobalt for someone,
it seems a real dog for anything outside the normal scope of what
they want you to do.  We needed to edit an httpd.conf file,
but there doesn't seem to be a way to do it.  Ditto for restarting Apache.
Add a MIME type?  No dice.

Webmin is not the slickest interface, but seems to offer a lot of flexibility.

Rather than rewriting something, perhaps you could vounteer to design
a better interface for existing webmin stuff.

A PHP-based version of webmin would be nice, but it's already a rather
developed project, and after considering how to do it myself, I realized
there's a whole hell of a lot of configurations and systems to have to
consider beyond my few linux distros.

John Huggins wrote:

> You mention a large desire for a good web based administrator.  I wonder if
> there is a version of a web based system administrator available that works
> like Cobalt, but can be installed on any hosting setup.  Have you folks
> heard of such a thing?  I am aware of Webmin, but am not too impressed with
> it yet.
>
> I have toyed with the idea of writing my own.  Jamie, what items do you feel
> must be controllable in a web hosting account administration panel?  Yes, we
> all know the basics, like email, dns, etc. but a bulleted list would be a
> good start at organizing a development effort.
>
> John


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




  1   2   >