Jump to content

Search the Community

Showing results for tags 'uploading pictures'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. I am new to PHP and I am having some problems and I am hoping someone can point me in the right direction. Here is what I need to do: Create a Web Form for uploading pictures for a high school reunion. The form should have text input fields for the person's name and a description of the image, and a file input field for the image. To accompany each file, create a text file that contains the name and description of the image. Create a separate Web Page that displays the pictures with a caption showing the name and description fields. Make sure the folder has read and write for everyone. Here is what I have but it isnt working properly: Process page of the page! an errow here: This is the message I get! Parse error: syntax error, unexpected '\' (T_NS_SEPARATOR) in C:\ITEC315\htdocs\users\ramojumder0\Reinforcement Exercises\Ch. 5\R.E.5-5_FillPictureForm.php on line 28 which deals with the picture! My problem is that it is having a problem uploading a picture and showing it! How do I fix the issue with uploading a picture and then showing it! Input page <form method="POST" action="R.E.5-5_Fillrrr.php"> <p>Name <input type="text" name="name" /></p> <p>Description <input type="text" name="description" /></p> <p>Choose a file to upload: <input type = "file" name = "picture" accept = "image/*" /></p> <p><input type="submit" value="Submit" /></p> </form> <p><a href="R.E.5-5_ShowPictures.php">Show Pictures </a></p> </body> </html> Processing page! <?php if (empty($_POST['name']) || empty($_POST['description'])) echo "<p>You must enter your name and description about your picture. Click your browser's Back button to return to the Picture Input Page!</p>\n"; else { $Name = addslashes($_POST['name']); $Description = addslashes($_POST['description']); $Picture = addslashes($_POST['picture']); $ShowPic = fopen("showpic.txt", "ab"); if (is_writeable("showpic.txt)) { if (fwrite($ShowPic, $Name . "," . $Description . "," . $Picture . "\r\n")) echo "<p>Thank you for filling out the Picture Input Page!</p>\n"; else echo "<p>Cannot add your name to the Picture Input Page!</p>\n"; } else echo "<p>Cannot write to the file.</p>\n"; fclose($ShowPic); } ?><!--End PHP Script-->
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.