Skip to content

Programming Articles

  • HOME
  • Python
  • JavaScript
  • C/C++
  • Java
  • Terms & Conditions and Privacy Policy
  • About US
Main Menu

JQuery

JavaScript / JQuery

How to preview an image before it is uploaded using JavaScript?

You can preview an image before it is uploaded without using AJAX the following way: How to preview an image before it is uploaded? There are a couple ways you …

How to preview an image before it is uploaded using JavaScript? Learn More
JavaScript / JQuery

How to check if a variable is an array in JavaScript?

There are several ways of checking if an variable is an array or not. The best solution is the one you have chosen. This is the fastest method on Chrome, …

How to check if a variable is an array in JavaScript? Learn More
Formatted Codes / JQuery

How to check whether a checkbox is checked using jQuery? [Answered]

Sample query: I need to check the checked property of a checkbox and perform an action based on the checked property using jQuery. For example, if the age checkbox is checked, then I need …

How to check whether a checkbox is checked using jQuery? [Answered] Learn More
Formatted Codes / JavaScript / JQuery

How to include a JavaScript file in another JavaScript file? [Answered]

Query: Is there something in JavaScript similar to @import in CSS that allows you to include a JavaScript file inside another JavaScript file? How to include a JavaScript file in another JavaScript …

How to include a JavaScript file in another JavaScript file? [Answered] Learn More
Formatted Codes / JavaScript / JQuery

How to return the response from an asynchronous call in JavaScript? [Answered]

Sample query: I have a function foo which makes an asynchronous request. How can I return the response/result from foo? I am trying to return the value from the callback, as well as …

How to return the response from an asynchronous call in JavaScript? [Answered] Learn More
Formatted Codes / JQuery

How to check if an element is hidden in jQuery? [Answered]

Query: Is it possible to toggle the visibility of an element, using the functions .hide(), .show() or .toggle()? How would you test if an element is visible or hidden? How do I check if an element is …

How to check if an element is hidden in jQuery? [Answered] Learn More
JavaScript / JQuery

Difference between event.preventDefault() and return false [Answered]

Query explained: When I want to prevent other event handlers from executing after a certain event is fired, I can use one of two techniques. I’ll use jQuery in the …

Difference between event.preventDefault() and return false [Answered] Learn More
CSS / JavaScript / JQuery

How to select CSS pseudo-elements such as ::before and ::after using javascript (or jQuery) [Answered]

Sample query: Is there any way to select/manipulate CSS pseudo-elements such as ::before and ::after (and the old version with one semi-colon) using jQuery? For example, my stylesheet has the following rule: How can …

How to select CSS pseudo-elements such as ::before and ::after using javascript (or jQuery) [Answered] Learn More
Formatted Codes / JQuery

jQuery Ajax File Upload [Answered]

Query explained: Can I use the following jQuery code to perform file upload using POST method of an ajax request ? If it is possible, do I need to fill data part? …

jQuery Ajax File Upload [Answered] Learn More
JQuery / PHP

jQuery Ajax POST example with PHP [Answered]

Query explained: I am trying to send data from a form to a database. Here is the form I am using: The typical approach would be to submit the form, …

jQuery Ajax POST example with PHP [Answered] Learn More
JQuery

What is the difference between .prop() and .attr() in JQuery? [Answered]

Sample query: So jQuery 1.6 has the new function prop(). or in this case, do they do the same thing? And if I do have to switch to using prop(), all the old attr() calls will break if …

What is the difference between .prop() and .attr() in JQuery? [Answered] Learn More
JavaScript / JQuery

How to upload files asynchronously with jQuery? [Answered]

Sample problem: I would like to upload a file asynchronously with jQuery. How to upload files asynchronously with jQuery? Answer #1: With HTML5 you can make file uploads with Ajax and jQuery. …

How to upload files asynchronously with jQuery? [Answered] Learn More

Featured Posts

From UNIX to Linux – History of Linux

21st November 202010th September 2022

Best themes for Ubuntu: Make Ubuntu Beautiful

20th October 202010th September 2022

Strings in Python

12th September 202010th September 2022

Is Python hard to learn? Top best learning resources

18th April 202010th September 2022

Recent posts

  • How to pad a string with zeroes to the left?
  • What is the difference between process and thread?
  • How to generate a random alpha-numeric string in Java?
  • How to auto-resize an image to fit a ‘div’ container?
  • How to get a Docker container’s IP address from the host?
  • How to display a JavaScript object?
Copyright © 2023 Programming Articles.
Powered by WordPress and HitMag.