php-general Digest 26 Aug 2003 07:35:50 -0000 Issue 2259

Topics (messages 160678 through 160733):

Re: "back" works in opera but not in internet explorer
        160678 by: Eric Wood

how to keep decimals from rounding
        160679 by: Rob Yelvington
        160684 by: DvDmanDT
        160713 by: Curt Zirzow

PHP permissions problem
        160680 by: Lowell Allen
        160715 by: Curt Zirzow

Uploading by email
        160681 by: Wouter van Vliet
        160728 by: Manuel Lemos

Displaying Multidimensional Arrays
        160682 by: Jason Williard
        160690 by: Chris W. Parker
        160718 by: Jason Williard

preg_match bug
        160683 by: Christian Calloway
        160697 by: John W. Holmes
        160706 by: Christian Calloway
        160710 by: Curt Zirzow
        160711 by: Curt Zirzow

Re: Window.status message
        160685 by: Chris W. Parker

Re: ob_start and transparent sessions 4.3.2
        160686 by: Wouter van Vliet

Re: [Newbie Guide] For the benefit of new members
        160687 by: Chris W. Parker
        160724 by: Burhan

Re: Problem with date('w')
        160688 by: Jennifer Goodie
        160731 by: BEOI 7308

verifying sql INSERTs
        160689 by: Chris W. Parker
        160695 by: John W. Holmes

Re: CMS question.
        160691 by: Robert Cummings
        160694 by: jabber.raditha.com

Re: Session problem in back button
        160692 by: Paul Fitzpatrick
        160719 by: murugesan

Re: Recursive Object Troubles
        160693 by: Mike Migurski

Re: querystring and frameset issue
        160696 by: jabber.raditha.com

help with parse error
        160698 by: Stevie D Peele
        160702 by: Paul Fitzpatrick

Impossible error
        160699 by: Mjec
        160700 by: Ashley M. Kirchner
        160701 by: Jennifer Goodie

Re: How to open random Flash page with hyperlink?
        160703 by: Cody Phanekham

if seat is sold
        160704 by: Jay Fitzgerald

FTP hosting PHP releases?
        160705 by: Simon Fredriksson
        160708 by: Sascha Schumann

SMTP - Authorization?
        160707 by: Mathiau
        160726 by: Manuel Lemos

Re: Unix end of line versus windows end of line
        160709 by: Curt Zirzow

mb_send_mail displays boundary marker
        160712 by: Martin Towell

Re: Use PHP or MySQL for MD5 function
        160714 by: Curt Zirzow

Re: Cookie saving path on Clinet
        160716 by: Tom Rogers

Re: need help figuring out how to delete rows?
        160717 by: Deadsam

determine how many checkboxes are selected.
        160720 by: Angelo Zanetti
        160722 by: murugesan
        160732 by: Ralph Guzman

php-cli stopping on exit.
        160721 by: Simon Fredriksson

onchange = "$_SESSION['Alarm']  = getelementbyid('alarmReport').value ;"
        160723 by: Mrunal Wagh

MD5 System Password check with PHP
        160725 by: Chinmoy Barua
        160727 by: murugesan
        160729 by: Justin French
        160730 by: Burhan

Problem with session_start after upgrading from 4.0.6 to 4.3.1
        160733 by: Richard NAGY

Administrivia:

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

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

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


----------------------------------------------------------------------
--- Begin Message ---
To fix this, I put:

  session_cache_limiter ('private, must-revalidate');

at the beginning of all my pages.  Seems to work.

-eric wood


anders thoresson wrote:
> When I push the back buttom in Opera, I get back to the previous
> (database/php-generated) page in my site, but when I'm using IE and
> push back, I get a message saying that the page isn't valid any more.
> 
> Is this an internal IE-issue, or could I make my php-script
> IE-friendly? 
> 
> --
> anders thoresson

--- End Message ---
--- Begin Message --- Is there a way to surpress round() or number_format() from rounding decimal places?

I have a value of ".253338" being returned via a calc function.

I take that value and multiply by 100 because I want "25.333" to be displayed.

I've used round(), sprintf(), and number_format() and each of them rounds the value up.

I had a problem with precision earlier which I solved...my 'precision' setting in php.ini was set too low. Is there something in php.ini that controls rounding?

Any heads up are appreciated!

Thanks,

~Rob
--- End Message ---
--- Begin Message ---
use floor(), I think that rounds it down... ceil() rounds it up...

-- 
// DvDmanDT
MSN: [EMAIL PROTECTED]
Mail: [EMAIL PROTECTED]
"Rob Yelvington" <[EMAIL PROTECTED]> skrev i meddelandet
news:[EMAIL PROTECTED]
> Is there a way to surpress round() or number_format() from rounding
> decimal places?
>
> I have a value of ".253338" being returned via a calc function.
>
> I take that value and multiply by 100 because I want "25.333" to be
> displayed.
>
> I've used round(), sprintf(), and number_format() and each of them
> rounds the value up.
>
> I had a problem with precision earlier which I solved...my 'precision'
> setting in php.ini was set too low.  Is there something in php.ini that
> controls rounding?
>
> Any heads up are appreciated!
>
> Thanks,
>
> ~Rob

--- End Message ---
--- Begin Message ---
* Thus wrote Rob Yelvington ([EMAIL PROTECTED]):
> Is there a way to surpress round() or number_format() from rounding 
> decimal places?
> 
> I have a value of ".253338" being returned via a calc function.
> 
> I take that value and multiply by 100 because I want "25.333" to be 
> displayed.
> 
> I've used round(), sprintf(), and number_format() and each of them 
> rounds the value up.

One  would expect sprintf not too round, but, behold, it does.
According to bugs.php.net, it is not a bug.

> 
> I had a problem with precision earlier which I solved...my 'precision' 
> setting in php.ini was set too low.  Is there something in php.ini that 
> controls rounding?
> 
> Any heads up are appreciated!

Perhaps by truncating the string to your precision that you desire.

Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
My commercial host is set up with the public root directory, "public_html",
owned by user: userid, group: nobody. Directories I create within
public_html are owned by user: userid, group: userid. As a result, PHP does
not have permission to create files or write to files in public_html, but it
does within its subdirectories.

Is this a common setup? Are there security problems with changing the
ownership of public_html to user: userid, group: userid so PHP can create
files within the root directory? Advice, opinions, and links to relevant
information are requested.

PHP 4.3.2/Linux/Apache 1.3.28

--
Lowell Allen

--- End Message ---
--- Begin Message ---
* Thus wrote Lowell Allen ([EMAIL PROTECTED]):
> My commercial host is set up with the public root directory, "public_html",
> owned by user: userid, group: nobody. Directories I create within
> public_html are owned by user: userid, group: userid. As a result, PHP does
> not have permission to create files or write to files in public_html, but it
> does within its subdirectories.
> 
> Is this a common setup? Are there security problems with changing the
> ownership of public_html to user: userid, group: userid so PHP can create
> files within the root directory? Advice, opinions, and links to relevant
> information are requested.

I usually keep my writable directories outside the public_html
directory. 

homedir/public_html/*   All read only by webserver.
homedir/private_data/*  Make these files read/write


Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
Hi,

I know it's slightly not totally about PHP.. but since I wanna do it with
PHP, i'll post it here. I was wondering if anybody can help me to accomplish
the following:

- Somebody sends an email to, for example, [EMAIL PROTECTED] This
email has some attachments, being photo's to be added to some system.
- Sendmail recievers the email, and sends it to some PHP script
- This script parses the input it gets, ...

Now, what would I need to do for all this to happen?
Wouter

--- End Message ---
--- Begin Message --- Hello,

On 08/25/2003 05:41 PM, Wouter Van Vliet wrote:
I know it's slightly not totally about PHP.. but since I wanna do it with
PHP, i'll post it here. I was wondering if anybody can help me to accomplish
the following:

- Somebody sends an email to, for example, [EMAIL PROTECTED] This
email has some attachments, being photo's to be added to some system.
- Sendmail recievers the email, and sends it to some PHP script
- This script parses the input it gets, ...

Now, what would I need to do for all this to happen?

The generic portable solution is to make your messages be deliverd to a POP3 mailbox and the connect to the POP3 server to retrieve and process the message.


I do that very often and use this POP3 client class to retrieve and delete processed messages:

http://www.phpclasses.org/pop3class

--

Regards,
Manuel Lemos

Free ready to use OOP components written in PHP
http://www.phpclasses.org/

--- End Message ---
--- Begin Message ---
I am trying to create a function that will take a multidimensional array and
turn it into a form based off the information in the array.  I have run into
a bit of a road block when it comes to displaying the array.  Would anyone
be able to offer some assistance on this front?

 - Jason

--- End Message ---
--- Begin Message ---
Jason Williard <mailto:[EMAIL PROTECTED]>
    on Monday, August 25, 2003 2:00 PM said:

> Would anyone be able to offer some assistance on this front?

Sure... if you give us more info. (i.e. maybe the array layout?)



c.

--- End Message ---
--- Begin Message ---
I actually found a way of handling this on my own.  Thanks.

- Jason

"Jason Williard" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I am trying to create a function that will take a multidimensional array
and
> turn it into a form based off the information in the array.  I have run
into
> a bit of a road block when it comes to displaying the array.  Would anyone
> be able to offer some assistance on this front?
>
>  - Jason

--- End Message ---
--- Begin Message ---
Hey I wanted to see if anyone was getting the same problem. Using preg_match
in the following pattern:

"/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/"

PHP seems to be crashing. I get a "Page cannot be displayed" message from
the browser. I've come across this before, and I just upgraded to 4.3.3, and
no difference.

--- End Message ---
--- Begin Message --- Christian Calloway wrote:

Hey I wanted to see if anyone was getting the same problem. Using preg_match
in the following pattern:

"/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/"

You need to escape the double quotes in your string at the very least.


--
---John Holmes...

Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/

php|architect: The Magazine for PHP Professionals – www.phparch.com
--- End Message ---
--- Begin Message ---
Obviously its an example, otherwise the script wouldn't have even parsed.

$regularExpression = '"/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/';

preg_match ($regularExpression, $fileString, $matches)

This regular expression causes PHP to crash for me, not a parsing error.

"John W. Holmes" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Christian Calloway wrote:
>
> > Hey I wanted to see if anyone was getting the same problem. Using
preg_match
> > in the following pattern:
> >
> > "/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/"
>
> You need to escape the double quotes in your string at the very least.
>
> --
> ---John Holmes...
>
> Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
>
> php|architect: The Magazine for PHP Professionals – www.phparch.com

--- End Message ---
--- Begin Message ---
* Thus wrote Christian Calloway ([EMAIL PROTECTED]):
> Hey I wanted to see if anyone was getting the same problem. Using preg_match
> in the following pattern:
> 
> "/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/"
> 
> PHP seems to be crashing. I get a "Page cannot be displayed" message from
> the browser. I've come across this before, and I just upgraded to 4.3.3, and
> no difference.

An error from the browser doesn't exactly prove that php is
'Crashing'. Please look in the system logs for the crash.

Also, in order to be able to reproduce this a small snipplet of
code that can reproduce the 'crash' would be exrememly helpful.


Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
* Thus wrote Christian Calloway ([EMAIL PROTECTED]):
> Obviously its an example, otherwise the script wouldn't have even parsed.

You provided an example that he had to make certain guesses for why
you think php is crashing.

> 
> $regularExpression = '"/<tr bgcolor="#FFFFFF">(.|\n)+?<\/tr>/';

This still is not right.  preg will think your looking for
  /tr bgcolor=

and will complain about the junk after the second ".

> 
> preg_match ($regularExpression, $fileString, $matches)
> 
> This regular expression causes PHP to crash for me, not a parsing error.

Please provide an exact sample that will cause php crash. And
somebody  here will test it for you.

Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
murugesan <mailto:[EMAIL PROTECTED]>
    on Monday, August 25, 2003 1:51 AM said:

> echo "<a class=MEDIUMFONTB href='/list.php
> onmouseover=\"javascript:window.status='hai'\" >Click here </a>";

Google* is your friend!!!!

http://hotwired.lycos.com/webmonkey/96/40/index3a.html?tw=programming


Chris.


* search terms used were "window.status"

--- End Message ---
--- Begin Message ---
Hi,

I too am running PHP4.3.2 and never took any notice about the session id's
being appended and stuff .. after reading your message I got a little
alarmed, since I'm also using output buffering. So, I turned off my cookies,
restarted my browser and saw that indeed no session id's were appended. Now,
when I checked php.ini, the value appeared to be '0'. That was quite an
explanation. I changed it to '1' and it all worked.

Maybe this makes your problem a little weirder.. But the problem is not on
the PHP version. You might want to check if session.use_trans_sid is really
set to 'On'. If it is, try changing it to '1', restart apache and see if it
works now. Also, check if your cookies are turned off, since with them
turned on, there's no need for php to add the session ID and thus it won't
happen.

Wouter

 -> -----Oorspronkelijk bericht-----
 -> Van: Miek Lohmann [mailto:[EMAIL PROTECTED]
 -> Verzonden: vrijdag 22 augustus 2003 18:41
 -> Aan: [EMAIL PROTECTED]
 -> Onderwerp: [PHP] ob_start and transparent sessions 4.3.2
 ->
 ->
 -> Hi,
 ->
 -> I've got a strange problem with enabled transparent sessions
 -> for my scripts.
 -> Before upgrading to PHP 4.3.2 I could use output buffering
 -> (ob_start()) and
 -> sessions without problems. Meanwhile with this new version the
 -> PHPSESSID is
 -> NOT appended to any link like html - tag (a href or something
 -> like that).
 ->
 -> I found a solution by writing my own session-handling and using regular
 -> expressions to append the session-id to any link, after outputting the
 -> content of the buffer, but this is not a really good solution, I think.
 ->
 -> (Btw. session.use_trans_id is on ;))
 ->
 -> Has someone found a solution or has had an equal problem with 4.3.2?
 ->
 ->
 ->
 -> Thanks.
 ->
 -> Mike
 ->
 ->
 -> Mike Lohmann
 ->
 -> [werk01]
 ->
 ->
 ->
 ->
 -> --
 -> PHP General Mailing List (http://www.php.net/)
 -> To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
    on Monday, August 25, 2003 5:11 AM said:

> 5. Provide a clear descriptive subject line. Avoid general subjects
> like "Help!!", "A Question" etc.

Change to:

5. Provide a clear descriptive subject line. Avoid general subjects like
"Help!!", "A Question", etc. Especially avoid blank subjects. Many
people see this as rude and will ignore your mail outright, myself
included.


(Does it make sense to put "urgent help needed!" in your subject? Isn't
everyone's email "urgent" to one degree or another?)

8. It's always a good idea to post back to the list once you've solved
your problem. People usually add [SOLVED] to the subject line of their
email when posting solutions. By posting your solution you're helping
the next person with the same question.


.02

Chris.

--- End Message ---
--- Begin Message ---
Quoting "Chris W. Parker" <[EMAIL PROTECTED]>:

> [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
>     on Monday, August 25, 2003 5:11 AM said:
> 
> > 5. Provide a clear descriptive subject line. Avoid general subjects
> > like "Help!!", "A Question" etc.
> 
> Change to:
> 
> 5. Provide a clear descriptive subject line. Avoid general subjects like
> "Help!!", "A Question", etc. Especially avoid blank subjects. Many
> people see this as rude and will ignore your mail outright, myself
> included.
> 
> 
> (Does it make sense to put "urgent help needed!" in your subject? Isn't
> everyone's email "urgent" to one degree or another?)
> 

Along these lines, you might want to add :

Do not send your messages high priority, as some people have special filters 
for such messages.

Do not request return reciepts, received reciepts, etc.

Do not send attachments

If at all possible, send your message plain text.

Trim as the original post only to the parts that are relevant to your 
discussion. No point seeing the same code repeated in five emails.

Just my thoughts

-- 
Burhan
phplist[at]meidomus[dot]com
http://www.meidomus.com

--- End Message ---
--- Begin Message ---
> I have a problem with the date function
>
> <?
>  $theday = date("Y-m-d", time());
>   echo date((w), $theday);
> ?>

I'm pretty sure the optional second argument for date is a unix timestamp
that you would generate by using either time or mktime or strtotime.  You
are passing it something in the form of Y-m-d, or 2003-08-23 when it is
expecting 1061852640.
http://www.php.net/manual/en/function.date.php

--- End Message ---
--- Begin Message ---
i found out that using strtotime did the trick !!

<?
strtotime($theday);
$theday = date("Y-m-d", time());
echo date((w), $theday);
?>

> > I have a problem with the date function
> >
> > <?
> >  $theday = date("Y-m-d", time());
> >   echo date((w), $theday);
> > ?>
>
> I'm pretty sure the optional second argument for date is a unix timestamp
> that you would generate by using either time or mktime or strtotime.  You
> are passing it something in the form of Y-m-d, or 2003-08-23 when it is
> expecting 1061852640.
> http://www.php.net/manual/en/function.date.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

--- End Message ---
--- Begin Message ---
Hi!

(MySQL)

What's the best way to determine a sql INSERT statement has executed
successfully?

What I've got is a function whose sole purpose is to add new staff
members to an app. I've written. There's a basic form that the user
fills out (first name, last name, email address) and submits. Only one
record per email address is allowed.

Here is a pseudo code version of what I have right now.

function insertStaffer($fname, $lname, $email)
{
        $sql = "SELECT table WHERE email = '$email'";

        if(1 or more records are found)
        {
                return 0; // means email address is already used
        }
        else
        {
                $sql = "INSERT INTO table ...";

                return 1; // assume record inserted correctly
        }
}

Now for my question: Should I just assume the INSERT INTO has worked
correctly (like I'm currently doing) and return a 1? Or should I verify
that the INSERT worked correctly (by using the MySQL last_insert_id()
function)?

Alternatively... maybe the mysql_query() function returns a true/false
status based on what happens? Hmm... I should look into that.


I'd appreciate any advice you have to give.


Thanks,
Chris.

--- End Message ---
--- Begin Message --- Chris W. Parker wrote:

Hi!

(MySQL)

What's the best way to determine a sql INSERT statement has executed
successfully?

You should use mysql_error() to ensure your query did not fail for any reason. Assuming the query was successful, you can use mysql_affected_rows() to see if it actually had any impact on the database, i.e. the row was inserted.


--
---John Holmes...

Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/

php|architect: The Magazine for PHP Professionals – www.phparch.com
--- End Message ---
--- Begin Message ---
On Mon, 2003-08-25 at 10:14, Edmond Baroud wrote:
> On August 25, 2003 08:13 am, Jay Blanchard wrote:
> 
> > What makes you think that the developer did something unethical?
> 
> It looks like you're familiar with this particular case and the developper 
> happens to be your friend so you're defending him?
> Anyways, I believe I said "to make a long stroy short". but if you insist on 
> knowing why I said that he did something unethical (let me add to that 
> "unprofessional" ); he sold an intellectual property which he was paid to 
> developpe to competitors in the business.

Legalize is very specific. If the contract didn't specifically state
that rights to the intellectual property would be part of the deal, then
he has merely sold a solution, not the rights to the intellectual
property itself. many companies are contracted for solutions, many
companies retain the rights to their intellectual property after
completion of the solution. Unless the contract is clear, he has done
nothing unethical or unprofessional.

Cheers,
Rob.

> 
> 
> > I have seen those small icons used by numerous developers, but I don't
> > know if they are available for uncredited or uncompensated works. Other
> > than that those screenshots look like dozens of packages I have seen.
> 
> Thanks for the feedback.
> 
> > Capable to upload what in a batch?
> 
> Have you ever seen anyone upload bananas or oranges on the net? the most 
> obvious word that could be placed here is "files", excuse me for forgetting 
> to mention it!
> 
> BTW: thanks for the your time Jay.
> 
> Ed.
> 
> -- 
> Edmond Baroud 
> Senior UNIX sysadmin             mailto:[EMAIL PROTECTED]
> Fingerprint  140F 5FD5 3FDD 45D9 226D  9602 8C3D EAFB 4E19 BEF9
> "UNIX is very user friendly, it's just picky about who its friends are."
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
-- 
.---------------------------------------------.
| Worlds of Carnage - http://www.wocmud.org   |
:---------------------------------------------:
| Come visit a world of myth and legend where |
| fantastical creatures come to life and the  |
| stuff of nightmares grasp for your soul.    |
`---------------------------------------------'

--- End Message ---
--- Begin Message --- exactly. The development company usualy has all the rights. That's why NDAs were invented :-)

Robert Cummings wrote:

On Mon, 2003-08-25 at 10:14, Edmond Baroud wrote:


On August 25, 2003 08:13 am, Jay Blanchard wrote:



What makes you think that the developer did something unethical?


It looks like you're familiar with this particular case and the developper happens to be your friend so you're defending him?
Anyways, I believe I said "to make a long stroy short". but if you insist on knowing why I said that he did something unethical (let me add to that "unprofessional" ); he sold an intellectual property which he was paid to developpe to competitors in the business.



Legalize is very specific. If the contract didn't specifically state that rights to the intellectual property would be part of the deal, then he has merely sold a solution, not the rights to the intellectual property itself. many companies are contracted for solutions, many companies retain the rights to their intellectual property after completion of the solution. Unless the contract is clear, he has done nothing unethical or unprofessional.

Cheers,
Rob.





I have seen those small icons used by numerous developers, but I don't
know if they are available for uncredited or uncompensated works. Other
than that those screenshots look like dozens of packages I have seen.


Thanks for the feedback.



Capable to upload what in a batch?


Have you ever seen anyone upload bananas or oranges on the net? the most obvious word that could be placed here is "files", excuse me for forgetting to mention it!

BTW: thanks for the your time Jay.

Ed.

--
Edmond Baroud Senior UNIX sysadmin mailto:[EMAIL PROTECTED]
Fingerprint 140F 5FD5 3FDD 45D9 226D 9602 8C3D EAFB 4E19 BEF9
"UNIX is very user friendly, it's just picky about who its friends are."


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






--
http://www.raditha.com/php/progress.php
A progress bar for PHP file uploads.

--- End Message ---
--- Begin Message ---
Hi,

This will stop them seeing the login once they are in a registered
session
Only diplay the login form if NOT a registered session variable
'sessionname' (or some other session variable)


If (!isset($_SESSION['sessionname']))
{
   //Display login form code goes here
}

Cheers.




-----Original Message-----
From: murugesan [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 25, 2003 9:55 AM
To: murugesan; Cody Phanekham; [EMAIL PROTECTED]
Subject: [PHP] Session problem in back button

Hello all,
        Now i have a problem in back button.
        After signing in when I click back button It goes to login page.
But
when I click the forward button it is going to the main page.
How can I prevent this.

-murugesan

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

--- End Message ---
--- Begin Message ---
Seems confusing.

-------------------------
//include.php
session_name("sessionname");
session_start();
-------------------------->>
This was added in a separate file and included that file in all the files
including index.php
In index.php I registered a variable s_authed and initialised it to 0

-----------------------------
//index.php
include "include.php";
session_register("s_authed");
$s_authed = 0; // initialize session flag
----------------------------->>

And after sign up I am authenticating the user in a separate file
and setting a flag s_authed to 1
-----------------------------
//auth.php
if(check for authentication)
{
   ........
   $HTTP_SESSION_VARS['s_authed']=1;
}
----------------------------->>
Now in the main.php
I am checking
-----------------------------
//main.php

if($s_authed==1)
{
   //Display login form code goes here
}
else
{
    display "authentication required";
}
----------------------------->>



This is working fine. Even when I copy and paste the URL to another browser
it is showing authentication required page.
When I used

if (!isset($_SESSION['sessionname']))
{
   //Display login form code goes here
}

in main.php
it is not working. I mean that it display the page even when I copy and
paste URL in a new browser window.

Seems like an essay :)
Why is it so.
Is that my previous method was correct or any mistakes I did?



-murugesan






----- Original Message -----
From: "Paul Fitzpatrick" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 26, 2003 10:43 PM
Subject: RE: [PHP] Session problem in back button


>
> Hi,
>
> This will stop them seeing the login once they are in a registered
> session
> Only diplay the login form if NOT a registered session variable
> 'sessionname' (or some other session variable)
>
>
> If (!isset($_SESSION['sessionname']))
> {
>    //Display login form code goes here
> }
>
> Cheers.
>
>
>
>
> -----Original Message-----
> From: murugesan [mailto:[EMAIL PROTECTED]
> Sent: Monday, August 25, 2003 9:55 AM
> To: murugesan; Cody Phanekham; [EMAIL PROTECTED]
> Subject: [PHP] Session problem in back button
>
> Hello all,
>         Now i have a problem in back button.
>         After signing in when I click back button It goes to login page.
> But
> when I click the forward button it is going to the main page.
> How can I prevent this.
>
> -murugesan
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--- End Message ---
--- Begin Message ---
>I am building a recursive Menu object.  Inside each menu item there is an
>array which should allow me to add submenu items and so on.  I am having
>trouble, though, with getting the submenus to stay.  They are
>disappearing as I go along.

Without really going through your code (sorry) I would hazard a guess that
you are assigning by value, rather than by reference - by default, the '='
operator in PHP passes a copy of an object or variable, rather than a
reference to it. The 'new' language construct does this as well. So do
functions, when they return values. All of this is very annoying and
requires you to liberally sprinkle your code with the '&' that denotes
passing-by-reference.

---------------------------------------------------------------------
michal migurski- contact info and pgp key:
sf/ca            http://mike.teczno.com/contact.html

--- End Message ---
--- Begin Message ---
frame set will need to be in php try something like this
[code]
<frame src="page1.php?id=<? echo $id; ?>">
[/code]

all the best

Irvin Amoraal wrote:

Can somebody tell me how to pass a value between two php pages within a
frameset.

I have a simple two column framset: navbar on the left, content on the
right.

I have two pages that are displayed in the content area. Both are PHP pages.
I would like to pass an ID value from the first page(a list page) to the
second (a detail page). I tried renaming the frameset page and associated
links with a php extention but that didn't work.

The link from the list page does contain the ID var in the querystring but
it is not recieved in the display page where I try to echo the querystring
var.

Any ideas?
Does the frameset page need to have a php extention?


Thanks.


Irvin <><





--
http://www.raditha.com/php/progress.php
A progress bar for PHP file uploads.

--- End Message ---
--- Begin Message ---
I have a parse error on line 12 --
-------------------------------------------
<?php
include ('config.php');
$link = @mysql_pconnect($location, $username, $password)
     or die("Could not connect to the databaseserver. Please go back and
try again or try again later.");
@mysql_select_db($database,$link)
     or die ("Could not select database. Please go back and try again or
try again later.");
$sql = "SELECT Title, SubT, Author, Story FROM SiteNews;"
$news = mysql_query($sql,$link) or die(mysql_error());

if ($news){
   if (mysql_num_rows($news)== 0){
     echo("No newsitems found.");
   }
   else{
     while ($row = mysql_fetch_assoc($news)){
      echo("<b>");
      echo("<font size=6>");
      echo($row['Title']. "<br />");
      echo("</font>");
      echo("<font size=4>");
      echo($row['SubT']."<br />");
      echo("</font>");
      echo("</b>");
      echo($row['Author']. "<br />");
      echo($row['Story']);
      echo("<hr noshade color=black size=1/>");
      
    }
  }
}
else{
   echo("Queryproblem");
}

 ?>
------------------------------------------

Can anyone see what the error is?? I can't

Thanks

--- End Message ---
--- Begin Message ---
Hi,

Maybe..

$sql = "SELECT Title, SubT, Author, Story FROM SiteNews;"


should be 

$sql = "SELECT Title, SubT, Author, Story FROM SiteNews";


-----Original Message-----
From: Stevie D Peele [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 25, 2003 5:41 PM
To: [EMAIL PROTECTED]
Subject: [PHP] help with parse error

I have a parse error on line 12 --
-------------------------------------------
<?php
include ('config.php');
$link = @mysql_pconnect($location, $username, $password)
     or die("Could not connect to the databaseserver. Please go back and
try again or try again later.");
@mysql_select_db($database,$link)
     or die ("Could not select database. Please go back and try again or
try again later.");
$sql = "SELECT Title, SubT, Author, Story FROM SiteNews;"
$news = mysql_query($sql,$link) or die(mysql_error());

if ($news){
   if (mysql_num_rows($news)== 0){
     echo("No newsitems found.");
   }
   else{
     while ($row = mysql_fetch_assoc($news)){
      echo("<b>");
      echo("<font size=6>");
      echo($row['Title']. "<br />");
      echo("</font>");
      echo("<font size=4>");
      echo($row['SubT']."<br />");
      echo("</font>");
      echo("</b>");
      echo($row['Author']. "<br />");
      echo($row['Story']);
      echo("<hr noshade color=black size=1/>");
      
    }
  }
}
else{
   echo("Queryproblem");
}

 ?>
------------------------------------------

Can anyone see what the error is?? I can't

Thanks

--- End Message ---
--- Begin Message ---
Hi,

I have a 163 line file.  I get a parse error on line 164.  Ideas?

Thanks,

mjec

--- End Message ---
--- Begin Message --- Mjec wrote:

I have a 163 line file. I get a parse error on line 164. Ideas?

That generally means you've forgotten a bracket somewhere. Check and correct the missing bracket and you should be good to go.

--
H| I haven't lost my mind; it's backed up on tape somewhere.
+--------------------------------------------------------------------
Ashley M. Kirchner <mailto:[EMAIL PROTECTED]> . 303.442.6410 x130
IT Director / SysAdmin / WebSmith . 800.441.3873 x130
Photo Craft Laboratories, Inc. . 3550 Arapahoe Ave. #6
http://www.pcraft.com ..... . . . Boulder, CO 80303, U.S.A.

--- End Message ---
--- Begin Message ---
> I have a 163 line file.  I get a parse error on line 164.  Ideas?
> 

You're probably missing a } somewhere.

--- End Message ---
--- Begin Message ---
Curt,

Your absolutely right it is a security hole, however the response was a quick solution 
without much thought in regards to the security integrity of the script.

> -----Original Message-----
> From: Curt Zirzow [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, 26 August 2003 01:04
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] How to open random Flash page with hyperlink?
> 
> 
> * Thus wrote Cody Phanekham ([EMAIL PROTECTED]):
> > Murugesan,
> > 
> > main.php:
> > <?
> > session_name("mysessionname");
> > session_start();
> > if (!$s_authed) // check access
> > {
> >   // user hasnt been authorised, therefore redirect to login page
> 
> This is exactly why register globals is turned off by default now.
> 
> This is a major security hole, I can simply put in the url:
>   http://host/main.php?s_authed=1
> 
> And I would be considered authenticated, throughout the site.
> 
> Please turn register_globals off and use the $_SESSION variable to
> access your session vars.
> 
> 
> Curt
> -- 
> "I used to think I was indecisive, but now I'm not so sure."
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 


*************************************************************************************
This e-mail, including any attachments to it, may contain confidential and/or personal 
information.
If you have received this e-mail in error, you must not copy, distribute, or disclose 
it, use or take any action 
based on the information contained within it.

Please notify the sender immediately by return e-mail of the error and then delete the 
original e-mail.

The information contained within this e-mail may be solely the opinion of the sender 
and may not necessarily 
reflect the position, beliefs or opinions of Salmat on any issue.

This email has been swept for the presence of computer viruses known to Salmat's 
anti-virus systems.

For more information, visit our website at  www.salmat.com.au.
*************************************************************************************

--- End Message ---
--- Begin Message ---
1. here is my code:  http://codedump.phpfreaks.com/viewcode.php?id=1162
2. here is a screenie of my seating chart:  http://www.bayou.com/jay/chart.gif

3. what i am wanting to do is using CSS i want to "strike-through" the seats that are in the db - else, I want them to display normally

note: the seat numbers are not in the db unless someone chooses that seat....they are a while loop of numbers 1 through 240....

Anyone got any ideas?
--- End Message ---
--- Begin Message --- Is there any official FTP server hosting the PHP tar balls? I've done a shell script that downloads, compiles and installs PHP. Problem is that it's kinda hard to fetch the tarballs since there are no good static links. They seem to change with every release. Trying to run "wget http://www.php.net/get/php-4.3.3.tar.bz2/from/se.php.net/mirror"; doesn't really work. So, is there any FTP (or webserver that work with WGET) that I can fetch those from?

//Simon
--- End Message ---
--- Begin Message ---
On Tue, 26 Aug 2003, Simon Fredriksson wrote:

> Is there any official FTP server hosting the PHP tar balls? I've done a
> shell script that downloads, compiles and installs PHP. Problem is that
> it's kinda hard to fetch the tarballs since there are no good static
> links. They seem to change with every release. Trying to run "wget
> http://www.php.net/get/php-4.3.3.tar.bz2/from/se.php.net/mirror"; doesn't
> really work. So, is there any FTP (or webserver that work with WGET)
> that I can fetch those from?

    The tarballs are always in /distributions/ on all web
    servers.

    - Sascha

--- End Message ---
--- Begin Message ---
Hey all!

glad to bea here! got alot to learn!

k,

basically i am sending out a mailing list to customers, - using a PHP
script, however the SMTP i am using needs to have Authorization to log into
the outgoing SMTP  - i HAVE to use this authentication no if's and ot
butt's., otherwise i will be blocked by Yahooo / AOL and some other provider
for running a relay SMTP as they see it and contirbuting to spammers by
allow anon acces to my smtp.

I know i can put my SMTP server on an internal ip so the outside world can
not see if but that is a bandaid fix for me - i want to know if PHP can use
an SMTP server that requires authotization to use it?


HELP! me searches for this have turned up no results or people simply not
knowing what i need to get done.

Matt.

--- End Message ---
--- Begin Message --- Hello,

On 08/25/2003 09:34 PM, Mathiau wrote:
basically i am sending out a mailing list to customers, - using a PHP
script, however the SMTP i am using needs to have Authorization to log into
the outgoing SMTP  - i HAVE to use this authentication no if's and ot
butt's., otherwise i will be blocked by Yahooo / AOL and some other provider
for running a relay SMTP as they see it and contirbuting to spammers by
allow anon acces to my smtp.

I know i can put my SMTP server on an internal ip so the outside world can
not see if but that is a bandaid fix for me - i want to know if PHP can use
an SMTP server that requires authotization to use it?


HELP! me searches for this have turned up no results or people simply not knowing what i need to get done.

The mail() function does not support authentication. You may want to try this SMTP class that lets you send messages via a server that requires authentication.


http://www.phpclasses.org/smtpclass

Use it in conjunction with this other class that lets you compose and send properly formatted messages:

http://www.phpclasses.org/mimemessage

--

Regards,
Manuel Lemos

Free ready to use OOP components written in PHP
http://www.phpclasses.org/

--- End Message ---
--- Begin Message ---
* Thus wrote Bohdan Blaha ([EMAIL PROTECTED]):
> Hi,
> 
> I use PHP with apache on two systems..
> (linux and windows)
> 
> when I use PHP on linux, it is ok.. I get Unix end of line, when I write to the file 
> with fwrite function...
> when I run the same script on windows machine, I get Unix end of line too, but I 
> need there windows end of line,...
> 
> is it configuration of php.ini?? or how can I set it???

I believe your looking for the 't' option in fopen.
  http://php.net/fopen
  
It will translate end of lines. Also there is a setting in the
php.ini file called:
  auto_detect_line_endings

Which effects the line endings when reading a file with fgets().

HTH,

Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
I've written an email class that works fine when I use mail()

But now I have added support for mb_send_mail() and the boundary marker is
being displayed in the body of the email. Putting it back to mail() works
fine...

I'm doing all the header info myself (ie, mb_send_mail('', '', $body,
$headers))

This is the contents of $headers
----- START -----
X-Mailer: SEE-IT's PHP email_class (c)2001
Mime-Version: 1.0
Subject: Saturday Lotto - 2003-08-02 - $19m
Sensitivity: normal
Importance: normal
X-Message-Flag: 
Reply-By: 
Expiry-Date: 
To: Martin Towell <[EMAIL PROTECTED]>
From: Martin Towell <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Error-To: [EMAIL PROTECTED]
Cc: 
Bcc: 
Content-Type: multipart/mixed; boundary="f269fe8a8c57c93d707399ffb68beeb6"
----- END -----

And this is the $body
----- START -----
--f269fe8a8c57c93d707399ffb68beeb6
Content-Type: text/html

<html>
<body>
Test HTML text
</body>
</html>

--f269fe8a8c57c93d707399ffb68beeb6--
----- END -----

I thought I may have to use mb_encode_mimeheader() but that didn't seem to
work either :(

Anyone have any suggestions on where I may/am going wrong?

TIA
Martin

--- End Message ---
--- Begin Message ---
* Thus wrote Daevid Vincent ([EMAIL PROTECTED]):
> 
> If you really care, just make a program like this and do some MD5() calls in
> both mysql and php to see which is faster. I'd be curious to know as well...
> You'll have to modify appropriately, and only do a single MD5 check because
> I think looping 10000 mysql MD5 calls will be slower automatically since
> there is the connection to the db and stuff to contend with, so keep that in
> mind.
> 
Another factor with this is the length of the data is for md5(). If
the data is really long there will be communication overhead, with
md5'ing with php.

Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

--- End Message ---
--- Begin Message ---
Hi,

Monday, August 25, 2003, 12:01:53 PM, you wrote:
BA> Hi Everybody

BA> I know this is vague but couldn't find the answer.

BA> Where (i mean system path) cookies are saved on Client's machine.

BA> I though it is in windows/temp or temporaray internet files (in win 2000) but it 
wasn't there.

BA> Please tell me.

BA> Thanks
BA> Binay

You should find it in C:\Documents and Settings\login_user_name\Cookies

-- 
regards,
Tom

--- End Message ---
--- Begin Message ---
Cool thanks I'll try it out :)
Deadsam
"Marek Kilimajer" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Actualy, it will not. LIMIT can have only one argument with DELETE.
> This will ($count is the number of rows you need to get in a previous
> query):
>
> DELETE FROM table ORDER BY timestamp ASC LIMIT $count-40
>
> Marek Kilimajer wrote:
>
> > DELETE FROM table ORDER BY timestamp DESC LIMIT 40, 10000000
> >
> > untested, but should work
> >
> > Deadsam wrote:
> >
> >> Hi Im making a chatroom using flash and php, the one problem Im having
is
> >> deleting rows.
> >> What I'm looking for is when they click on the button to send the
message
> >> into php-->mySql  it will also
> >> check to see how many rows are in that table and if they are greater
then
> >> 40, then to delete the rows
> >> over 40, starting with the oldest ones ASC. I thought about using the
> >> chatID
> >> number but that will change
> >> everytime. So I was thinking of having it check for how many rows
> >> there is
> >> if its greater then 40 rows then
> >> delete thgose over 40 ASC.
> >> Hope I explained it good enough :)
> >> Anyhow if anyone has a solution for this I would really appreciate it.
> >> Thanks in advance
> >> Deadsam
> >>
> >>
> >>
> >>
> >
> >
>

--- End Message ---
--- Begin Message ---

Hi I have a tabel that gets populated dynamically from a DB query. Each row
is a seperate record and they all have a checkbox. I want to put a
button/image @ after the table and when it is click ed to determine which
checkboxes have beeen selected. I also name the checkboxes dynamically with
chk being the prefix and the record ID the suffix eg record 56: chk56 would
be the name of that particular checkbox.

If anyone could help with this design issue I would appreciate it!
Or any advice will be great as well.

angelo

TIA

--- End Message ---
--- Begin Message ---
First count the number of entries($count)  to be displayed in the page.
Accordingly assign the names

for($i=0;$i< $count;$i++)
{
 $chkval="chkv".$i;
 $chkfun="chkf".$i;
 echo "<input type=hidden name=$chkval value=off>";
echo "<input type=checkbox name="chkname".$i onclick=$chkfun()>
        ";
//display record $i
 echo "<script language=JavaScript>
  function $chkfun()
  {
   if(document.forms[0].$chkval.value=='off')
    document.forms[0].$chkval.value='on';
   else
    document.forms[0].$chkval.value='off';
  }</script>";
}

and upon subbmitting the form
you can determine the checked entries.

-murugesan


----- Original Message -----
From: "Angelo Zanetti" <[EMAIL PROTECTED]>
To: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
Sent: Tuesday, August 26, 2003 10:36 AM
Subject: [PHP] determine how many checkboxes are selected.


>
>
> Hi I have a tabel that gets populated dynamically from a DB query. Each
row
> is a seperate record and they all have a checkbox. I want to put a
> button/image @ after the table and when it is click ed to determine which
> checkboxes have beeen selected. I also name the checkboxes dynamically
with
> chk being the prefix and the record ID the suffix eg record 56: chk56
would
> be the name of that particular checkbox.
>
> If anyone could help with this design issue I would appreciate it!
> Or any advice will be great as well.
>
> angelo
>
> TIA
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--- End Message ---
--- Begin Message ---
Change box names to chk[] and assign the id as the value, so for
example:

<INPUT TYPE="checkbox" NAME="chk[]" VALUE="56">

to check which boxes have been checked simply traverse through the chk[]
array like this:

$chk_array = $_POST['chk'];

for($chk_array as $chk_key => $chk_value)
{
    print 'Checkbox Id:'. $chk_key . ' Value:'. $chk_value .'is
checked';
}

I have not tested this, but it should work.

-----Original Message-----
From: Angelo Zanetti [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 25, 2003 10:07 PM
To: [EMAIL PROTECTED]
Subject: [PHP] determine how many checkboxes are selected.



Hi I have a tabel that gets populated dynamically from a DB query. Each
row
is a seperate record and they all have a checkbox. I want to put a
button/image @ after the table and when it is click ed to determine
which
checkboxes have beeen selected. I also name the checkboxes dynamically
with
chk being the prefix and the record ID the suffix eg record 56: chk56
would
be the name of that particular checkbox.

If anyone could help with this design issue I would appreciate it!
Or any advice will be great as well.

angelo

TIA

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

--- End Message ---
--- Begin Message --- Can someone explain why PHP freezes when I don't specify a file for it? Like when I run "php -v" it outputs:

PHP 4.3.3 (cli) (built: Aug 24 2003 22:05:23)
Copyright (c) 1997-2003 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2003 Zend Technologies

Then stops. It doesn't return to the commandprompt. System: WinXP Pro.

//Simon
--- End Message ---
--- Begin Message ---
hi,

I have a SELECT in which I would like to store the variable value in the
Session variable of onchange event of the SELECT.  I am stuck up with the
syntax could u please help.

<Select name="AlarmReport" id = "AlarmReport" **I want to do this*****
onchange = "$_SESSION['Alarm'] = getelementbyid('AlarmReport').value >
        <option value='1 day'>1 day </option>
         <option value='2 days'>2 days </option>
         <option value='7 days'>7 days </option>
         <option value='1 month'>1 month </option>
         <option value='1 year'>1 year </option>
</Select>

Best Regards,
Mrunal

--- End Message ---
--- Begin Message ---
Hello everybody,

I want to authenticate my user from web with PHP
script. The user's passwords are stored in System as
MD5 format (in /etc/shadow). 

Can anybody help me?

- Chinmoy


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

--- End Message ---
--- Begin Message ---
First store the password in the DB as 
$passwd=md5($passwd)
insert into table values(.... $passwd);

get the user password and check by comparing
if(md5($password)==$fetchedpasswdfromDB)
{
    ...
}

-murugesan

----- Original Message ----- 
From: "Chinmoy Barua" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 26, 2003 11:34 AM
Subject: [PHP] MD5 System Password check with PHP


> Hello everybody,
> 
> I want to authenticate my user from web with PHP
> script. The user's passwords are stored in System as
> MD5 format (in /etc/shadow). 
> 
> Can anybody help me?
> 
> - Chinmoy
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
> http://sitebuilder.yahoo.com
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 

--- End Message ---
--- Begin Message --- On Tuesday, August 26, 2003, at 04:04 PM, Chinmoy Barua wrote:

Hello everybody,

I want to authenticate my user from web with PHP
script. The user's passwords are stored in System as
MD5 format (in /etc/shadow).

Can anybody help me?

Which part do you want help with?


The form?
The SQl query?
The whole lot?

My guess is the query

$sql = "
        SELECT id
        FROM users
        WHERE username='.$_POST['username']}'
        AND password='".md5($_GET['password'])."'";

It (MD5) can also be done directly in the query as a MySQL function.


Justin

--- End Message ---
--- Begin Message ---
Quoting Justin French <[EMAIL PROTECTED]>:

> On Tuesday, August 26, 2003, at 04:04  PM, Chinmoy Barua wrote:
> 
> > Hello everybody,
> >
> > I want to authenticate my user from web with PHP
> > script. The user's passwords are stored in System as
> > MD5 format (in /etc/shadow).
> >
> > Can anybody help me?

See http://www.zend.com/zend/tut/authentication.php

-- 
Burhan
phplist[at]meidomus[dot]com
http://www.meidomus.com

--- End Message ---
--- Begin Message ---
Hello,

I'm using an apache server 1.3.28 on RedHat GNU/Linux 6.2 with php
4.3.1. Before, I was using apache 1.3.14 with php 4.0.6. Since I have
upgraded, I have problems with session_start. I have tried to set
register_globals either to on or to off but it has no effect on this
problem.

Example :

Warning: session_start() [function.session-start]: read failed: Value
too large for defined data type (75) in
/var/www/htdocs/site/ssl/accueil/connexion.php on line 28

How can I solve this problem?
Thanks in advance.

--- End Message ---

Reply via email to