It might not be it, but this stood out...

<?PHP
$filedir = "../userpics";

//check for jpg format
if($fupload_type == "image/pjpeg")
{
//copy picture to new directory
   if(copy($fupload, "$filedir/$CUserName.jpg"))
    {
        //show picture
        // You forgot the closing '>' tag...and you are escaping the '"'
        print ("<img src=\"$filedir/$CUserName.jpg\">");
    }
}
?>

Jason Lotito
www.NewbieNetwork.net
Where those who can, teach;
and those who can, learn.


> -----Original Message-----
> From: Mike Yuen [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, March 14, 2001 9:01 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] URGENT: Can't see picture
>
>
> I'm having a ton of trouble trying to get pictures to display.  At first,
> I thought I had the problem fixed - but that's because the pictures reside
> on my machine. So instead of providing a path to the pictures like:
> c:/phpweb/userpics/ I tried absolute paths like ../userpics and that
> doesn't seem to have worked either.
>
> Here's a snippet of my code and i'm hoping someone can help me out on
> this.
>
> Thanks,
> Mike
>
> <?PHP
> $filedir = "../userpics";
>
> //check for jpg format
> if($fupload_type == "image/pjpeg")
> {
> //copy picture to new directory
>    if(copy($fupload, "$filedir/$CUserName.jpg"))
>     {
>       //show picture
>       print ("<img src=\"$filedir/$CUserName.jpg\");
>     }
> }
> ?>
>
>
>
> --
> 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]

Reply via email to