Questions tagged [jquery]

A JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development.

Filter by
Sorted by
Tagged with
2
votes
1answer
42 views

Iterate through multiple elements with different IDs in jQuery

I'm very new to jQuery and I managed to make this code work but I'm pretty sure that it could be made in a more efficient way. For example, it should be a way to send the id as a parameter instead of ...
5
votes
1answer
59 views

Children's Mini Game Handy-Eye Coordination

This is a game for children 3years+ to learn Hand-Eye Coordination with Mouse Movement. Goal is to catch all dinosaurs in the jungle, get the egg reward and then repeat the game. I tried to add sounds ...
4
votes
1answer
80 views

Javascript to show folder and files by calling Web Api

I have this Javascript which call the web api to see the available folder and then the available files. Any comment or code review on my code? ...
2
votes
0answers
33 views

HTML Mark up for multiple Fridge Checks and jQuery to show specific Fridges

I am creating a report. Where a user can select a Fridge and submit their temperature values and comments. (Node JS will handle this). I'd like to see if I can improve anywhere with my HTML Mark Up ...
1
vote
1answer
35 views

Confirmation Model with jQuery

I have a link aimed to '/FridgeTemperatureRoute' and a checkbox. Purpose of the checkbox is to show the user whether the check has been done or not. ...
1
vote
1answer
25 views

Iterate through multiple elements based on their id in jQuery

Haven't worked too much with jQuery and I had to get the values from different elements (they have the ids 0, 1 and 2) in order to compute the sum of them and update a field with that value. The code ...
3
votes
2answers
56 views

How can I simplify these checkbox onClicks?

I know there is a way to simplify these checkbox onClick functions. I'm just not sure how to make it happen. Upon checking the checkAllProfiles checkbox, all of the profileCheckboxes are checked: <...
3
votes
0answers
41 views

Optimisation potential when using deferred/promises and looping

I am fairly inexperienced when it comes to jQuery/JavaScript, so although the following code works, I am just looking to understand if my use of looping, deferred/promises etc could be optimised at ...
3
votes
0answers
35 views

Validating a file input whose value is reset to empty string (“”) after selection

My form comprises of a mandatory file input. The form is validated according to the jQuery validate plugin. The file input has attribute required so that the ...
4
votes
0answers
63 views

Created a paperfold like effect

I am trying to recreate a neat effect that I saw posted on Stack Overflow as a GIF . I am trying to recreate this with CSS and JavaScript and I have created a similar effect with a button press. I ...
3
votes
1answer
65 views

Node JS Express - Temperature records

Goal: I have thought of a project to create and came up with this goal of: "To record temperatures for different Fridges or Freezers." Current situation I have a working method to get data ...
1
vote
0answers
22 views

User Friendly Comment and Answer System for SharePoint Site

I am seeking help in improving my question and answer system I developed for my office SharePoint site. The question and answer system features two-columns and in the each columns is a table. I have a ...
2
votes
2answers
49 views

How can I simplify this JQuery validation process?

How can I simplify this functioning JQuery validation process: ...
2
votes
1answer
53 views

What is the best way to use serverside validation in PHP PDO?

I have a form on my page. I am using jQuery validation for client-side and PHP for server-side validation. I am using PDO. I don't have any issues with client-side and server-side validation. My form ...
3
votes
0answers
59 views

Dynamic dependent dropdown in jquery

I'm trying to create a dependent dynamic dropdown in jQuery, in which the number of dropdowns is not fixed. Let's say we've four provinces, each has cities, and each city has sections. Each section ...
3
votes
1answer
45 views

jQuery dropdown using each

Can someone please review the code and suggest any improvements / changes? Note that this method works but wanted to see if there is a better way for self learning purpose JavaScript/jQuery. Example ...
1
vote
0answers
7 views

Making Select2 pillbox control more accessible compliant and want feedback (bring your screen reader)

I am looking for feedback on screen reader improvements for the code/example below. The Select2 pillbox control needs to be more accessible. They have an open issues on this subject Select2 Issue ...
1
vote
1answer
37 views

Incrementing and decrementing 3 seperate input values by 1 using Javascript

I have written the following Javascript code which increments and decrements 3 separate inputs by 1: ...
2
votes
1answer
120 views

Javascript - Extract data from html table

I want to extract the headers data and column data (not row data) from an HTML table using JavaScript. Is this a good approach of doing it? And how can I simplify this using jQuery? ...
2
votes
1answer
26 views

How can I clean up (DRY) this verbose jQuery code?

I had posted this on StackOverflow — someone pointed me here. My code is working, but it's incredibly verbose and I know that it can be made more compact. I just don't know how :-) I'm building an ...
2
votes
0answers
20 views

Combine multiple jQuery click events and functions

I have a page with multiple menus. Once I hit a certain window width, I use CSS and jQuery to turn them into accordions. I also check the screen size when resizing so the accordions don't stay hidden ...
1
vote
1answer
51 views

Implement jquery like functions addClass, removeClass and delay in Javascript

Assume $ is not the browser. Now have to implement $, it will take a string, which is a query, it will use the querySelector to select the element. (Reference: https://developer.mozilla.org/en-US/docs/...
0
votes
1answer
36 views

Custom Library (pseudo-jQuery)

Well, I'm not going to use it everywhere, as jQuery exists, but still was interested in experience of creating own library. Here are first steps: ...
1
vote
2answers
131 views

jQuery form.find radio class

In my application we have four inputs radio controls and on the load the value is checked to true. When the user select another radio and then save the form I want to get the new value. I am using the ...
2
votes
1answer
82 views

jquery update hidden and a tags

First off, not the greatest with jQuery but know enough to get by. I created this mock up that is base on my application and wanted to see if there is a better way to update hidden values and a tags. ...
3
votes
1answer
47 views

eCommerce Mock App

This is a follow-up question to eCommerce Mockup App in JS. How do I implement the 'observe' pattern for the cart to regenerate html? So that, it will keep refresh its own. And any review on my coding ...
0
votes
0answers
14 views

Is it possible to optimise jQuery tag:contains() selector?

I am trying to extract all the elements from a webpage which contains given set of words. E.g. Given I have an array of random words ...
1
vote
0answers
15 views

Config based Hide Show Rules Processor in JavaScript

I am working on a library which does DOM hide and show based on other DOM elements. I have written a basic structure for the library. The below is the code to handle DOM elements hiding when a ...
1
vote
0answers
30 views

Toggle submenu state on click, keydown and touch with a11y support

This code should toggle the state (open/closed) of a submenu when the associated top-level trigger is clicked. The menu should toggle for mouse clicks, keyboard events and touch events - since ...
1
vote
1answer
55 views

Simplifying input filtering in tables with multiple selectors using jQuery

Code explained I wrote a few identical functions for each table to filter them based on the user input typed in the input fields using jQuery. After filtering it counts the rows that are left visible....
2
votes
1answer
30 views

JQuery Class and Display Toggling

I know there is a better way to do the following but I havent had any luck trying to clean it up. This is for a table of messages where the user can click a row, ...
1
vote
1answer
55 views

Toggle CSS class on vote

I have this jQuery handled buttons. But I think I overdid it with the if else statements. I am wondering if the code can be more efficient in some way than what I ...
0
votes
0answers
29 views

Jquery tooltip with callback hover more tooltips displays delayed content

I have an html table with multiple rows and columns. ...
2
votes
1answer
66 views

Javacript/jQuery animation makes text appear/disappear as if typed

On Eric Amodio's website and JS.ORG, there is a Javascript animation which makes text appear/disappear as if it is being typed. I tried to replicate something similar but far more basic on JSFiddle. ...
1
vote
1answer
28 views

shopify get jquery code more readable, usable

Hi so like in my question, i wrote some part of code for shopify to get recent orders for past 30 day and i wondering if it is really readable, or maybe i schould change something? I mean maybe ...
1
vote
0answers
40 views

App that Builds a list of “targets” for a Text-Based RPG using the games' API

all! I am developing a web "app" with JavaScript and jQuery with the help of a couple of other libraries for ease of use. Its purpose is to collect user ID's and to build a list of "attackable" ...
3
votes
1answer
69 views

Sidebar with slide-out feature

I made a sidebar that has a slide-out feature. When you click on it, it shows more items. I made it with JS and HTML but I think the code can be done more efficiently. How can I clean the code up? <...
3
votes
0answers
39 views

Displaying sections from pre-checked options

First off, not the greatest with jQuery but know enough to get by. I have a custom script for our WordPress site that ties in with a main plugin we use. I have a JSFiddle that gives the gist of what ...
3
votes
1answer
74 views

Javascript Slider that controls TinySlider - feels inefficient [closed]

I feel like the main point of inefficiency is how I create "notches" and must loop through all of the created notches every time the value for the slider is changed. ...
2
votes
1answer
54 views

JavaScript list sorting by date and type. better code?

I'm a junior developer. And I want to learn the good way to code. The code I will show you is working, but I feel like its all messy and longer that it should be. It is simply a .js, a .html and some ...
3
votes
0answers
32 views

Prettified GridView: is this JS code concise?

I been writing code for my company for years and there is never any constructive criticism for what I do. I am the only developer here and I would appreciate your opinion on this web page I made. It ...
4
votes
0answers
463 views

Bootstrap 4 Menu Collapse on Scroll

I am trying to code a menu that: Is horizontal on lg+ displays at the top of the page Shows a hamburger menu when the user scrolls from the top Will display as the collapsed format when the ...
1
vote
0answers
24 views

Display Correct Div based on Radio Button Checked

We are using a plugin for our WordPress website. I'm trying to add some custom code to it and finally got it working however it is ultra janky. The HTML is a simplified version of the actual site's ...
1
vote
0answers
23 views

Check if Radio Button is Checked and if Value Matches [closed]

Wracking my brain trying to figure this out. I'm not the greatest with Jquery but know enough to kinda get by. Right now I am trying to develop something that will check if a radio button in a group ...
1
vote
1answer
167 views

Generating a table of contents with collapsible subsections, PhP or JQuery?

The code below generates tables of contents with collapsible subsections from HTML headers. I have done it for a WordPress website, so I can use either PHP or JQuery/JavaScript. I have used PHP to ...
0
votes
0answers
27 views

Little Multilanguage site with modifiable words in a table.( Code improvement )

I have written a code for my little little website to make it multilanguage. It is a simple "developer" page where you can select from four different languages. Hungarian, English, Deutch and Roman. ...
2
votes
2answers
46 views

Find size for elements to fit in certain width

This is a follow-up on Change size of elements until parent reaches certain height The goal of the function is to find a size for the elements inside a parent, so they all fit in a single row. I ...
1
vote
0answers
2k views

How to open an input file programmatically (javascript) in a reliably way? [closed]

How to open an input file programmatically (javascript) in a reliably way? The most modern versions of internet browsers prevent the opening of input files programmatically (javascript) under certain ...
0
votes
0answers
16 views

Embedding BBCode tags in each other using checkboxes

So a few days ago ago I had this idea to let the user easily merge BBCode tags, like with checkboxes, as it is done in the code below. For a while I was thinking how I could make it work, then I came ...
0
votes
1answer
29 views

Jquery Selector optimization for multiple clicks

I have multiple inputs that each one has an increment and decrement button The buttons will be pressed multiple times so i am looking to optimize my selector: So should i keep the first one (which ...

1
2 3 4 5
48