Web Developer Notes - Page 8
Countdown Timer in JavaScript
Last updated: 02.04.2026
Views: 415
Countdown timers are commonly used on websites that promote products, services, or special offers. You can often see them on landing pages or in online stores, where they are used to highlight limited-time deals and create a sense of urgency. By showing how much time is left until a specific event or deadline, such timers can help increase user engagement and encourage faster decision-making.
I...
How to Upload Files to a Server Using PHP
Last updated: 21.02.2026
Views: 358
Uploading files to a website is a common task. Consider uploading files to a PHP server using the POST method. This will require a form with the "file" field type and an enctype attribute with a multipart/form-data value. We will not use AJAX in this example, but will do a regular HTML form submission.
HTML
[html]
<form method="POST" enctype="multipart/form-data">
&l...
Swipe Events on Touch Devices in JavaScript
Last updated: 21.02.2026
Views: 258
Every day sensory devices are being introduced into our lives. These devices have specific events, unlike the desktop. One of these events is the swipe. Especially often have to deal with it when developing a mobile version of the site.
Swipe events on touch devices allow developers to detect gestures like swiping left, right, up, or down, commonly used for navigation or interaction. These even...
How to Get Max Value in JavaScript Array
Last updated: 21.02.2026
Views: 287
A short note about finding the maximum value in a JavaScript array with numeric values. The Array object in JS does not have its own max method.
To find the maximum value in a JavaScript array, you can use several methods. Here are the most common and efficient approaches:
1. Using Math.max() with the spread operator
The Math.max() function returns the largest number from a set of numbers...
Drop down menu (jQuery)
Last updated: 10.10.2025
Views: 410
Drop down menu can be done without JavaScript, only with the help of CSS. With :hover. But the JavaScript menu has its advantages. The most important thing is the delay in the disappearance of the drop-down elements.
Let's consider a simple menu with one nesting level. We will write the code using jQuery. Although jQuery is not the most modern tool, this library continues to be used in many pr...