Uploading images to PHP Server via AJAX
4.4 (28 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
2,434 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Uploading images to PHP Server via AJAX to your Wishlist.

Add to Wishlist

Uploading images to PHP Server via AJAX

Explore how you can use AJAX and HTML forms to upload images to PHP servers
4.4 (28 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
2,434 students enrolled
Created by Laurence Svekis
Last updated 7/2017
Current price: $10 Original price: $200 Discount: 95% off
5 hours left at this price!
30-Day Money-Back Guarantee
  • 1.5 hours on-demand video
  • 5 Articles
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • How to send images to the server
  • Showing previews of images
  • Returning back the path of the new upload
View Curriculum
  • jQuery AJAX
  • Basic PHP knowledge

Explore how to upload images to your server using AJAX and PHP.

Please note this course covers PHP within the scope of saving files, specifically image files on your server.  Knowledge of PHP is a prerequisite  to this course.  AJAX is done via jQuery which is also a prerequisite to this course.  jQuery is only covered within simple AJAX calls and some element html updates.

This course covers a number of methods to store image data onto your server.

Learn how to create a Simple Form with a file input and submit the data to a PHP file.    Use PHP to check for valid images, file sizes and check for errors.

Using AJAX to submit form file contents to the server removes the need for a page reload and lets you make use of the response data and output it into your HTML.   Simple easy clean way to send images to your server.

BASE64 image data to PHP server can be used to create an image and save it to a file location on the server.  This method will ensure you have an image format as its not simply coping the file but actually using the encoded data to create the image file.   This method is useful when the image is also generated on the fly.

  • Source code is included to get you started quickly.
  • Resources and helpful links are also included

Taught by an instructor with over 18 years of real world web development experience, ready to answer any questions you may have.

Join now and start creating your own PHP applications today.

Who is the target audience?
  • Web developers
  • PHP developers
  • Anyone who wants to learn how to upload images
Compare to Other PHP Courses
Curriculum For This Course
20 Lectures
Introduction to image upload via PHP
19 Lectures 01:26:58

System Setup and Resources

Get FILE information from submission

Image validation check in PHP

Check upload size and check for errors

Save file to server PHP

Source File upload to server

Send to separate php file show image

add jQuery and setup form for upload

Create AJAX request to PHP

Preview image as base64 format

Decode base64 image using PHP

Source Code index.html

index.html code review

Source Code uploader.php

uploader.php source code review

source code save.php

code review save.php
Resources and links
1 Lecture 00:02
Course Resources
About the Instructor
Laurence Svekis
4.2 Average rating
14,395 Reviews
315,842 Students
188 Courses
Instructor, 18+yrs Web Experience

I'm here to help you learnachieve your dreams, come join me on this amazing adventure today

Providing Web development courses and digital marketing strategy courses since 2002.

Innovative technology expert with a wide range of real world experience. Providing Smart digital solutions online for both small and enterprise level businesses.

"I have a passion for anything digital technology related, enjoy programming and the challenge of developing successful digital experiences. As an experienced developer, I created my first computer applications in 1990, and my first website in 1998.  I enjoy sharing my knowledge with others and want to help you share in the wonderful opportunities that the internet provides."

"Learning, understanding with a strong passion for education.  The internet has provided us with new opportunities to expand and share knowledge."

Want to learn more about becoming a web developer, do you want to experience the freedom that technology provides for us? Learn how to bring amazing things to life online.  Technology connects us all in many ways.  It opens up doors to those who embrace it and learn how to make those connections real.

"My courses are designed to help you achieve your goals, learn and update skills"

Background : An experienced web application developer, having worked on multiple enterprise level applications, hundreds of websites, business solutions and many unique and innovative web applications.  Web application development areas of expertise include HTML, CSS, JavaScript, JQuery, Bootstrap, PHP and MySQL. Anything to do with web creation and digital experience. Passionate about everything to do with web application development, programming to online marketing with a strong focus on social media and SEO

"Understanding technology provides a means to better connect with users.  It also opens so many doors.   Knowledge is the key to success and I want to help you experience what technology has to offer. I'm passionate about web technologies, and look forward to sharing my knowledge and experience with you!"