All Questions
168 questions
2
votes
1
answer
79
views
Reorganice (and style) form's output in HTML using JQuery: how to do it better?
To clarify: The code in "What I achieved" is working. I'm looking for suggestions so I can improve.
I'm quite new with JQuery (and javascript) and I've been learning while styling a forum. ...
0
votes
1
answer
81
views
Show/hide depending on ID and Class
I have written some code that shows a div class, based on what ID is clicked. I'm a beginner, so not sure how to make this code compact, it seems way too long at the moment. Can anyone suggest a ...
4
votes
1
answer
105
views
Four HTML tabs elements, with fade animations, activated by buttons
I am pretty new to Javascript and trying to make a really simple tabs element which is just hiding and showing sections depending on which button is clicked. I know that this is a terrible way of ...
3
votes
2
answers
2k
views
Show/hide for multiple IDs
I'm don't know much about javascript, but and slowly learning through using other people's code. The below code I'm using is quite repetitive, with the only variance being the ID names. I feel like ...
2
votes
1
answer
268
views
clone of HTML tables of data
Need help to refactor this code to look like its done by a pro. Or just put some advice or links to useful stuff.
The idea is to clone a div with two empty tables for two separate arrays of data.
div ...
5
votes
1
answer
141
views
Video player UI in Javascript/JQuery
I am a Javascript/JQuery beginner working on my first ever project. Everything in this program is working as it should and I am happy with its performance. I have pieced it together from a variety of ...
2
votes
1
answer
146
views
Toggling a class in JS
I'm toggling the class of an element with this code but I'm pretty sure it can be written more efficiently.
...
3
votes
2
answers
114
views
Sliding marker on link hover with jQuery
The following code is for a vertical menu, where I needed a marker to slide down next to a link upon hovering over said link. Therefore I needed to change CSS properties of a HTML element (the top-...
1
vote
1
answer
549
views
Loop through data layer and display dynamic content [closed]
The purpose of the pricingTest object is to grab pricing information from the dataLayer on the page and render content blocks accordingly. My goal in posting this is to hopefully receive some feedback ...
2
votes
1
answer
584
views
jQuery accordion to serve as table of contents
I'm putting together a video website for our company, with a working accordion. It works, but it using the same class name for each section creates issues with the expanding and collapsing. I found ...
0
votes
2
answers
96
views
jQuery function to display an alert when submitting blank fields
I am new to jquery and implemented following function in a js file in case of error-
...
2
votes
2
answers
160
views
Manipulating the browser history
I created a table with the ability to edit with popup.
This part of the code, which includes:
the ability to send URL to other users with the subsequent opening of the same state (the popup window is ...
2
votes
2
answers
350
views
Click-through rate calculator using jQuery
I created a calculator for CTR with jQuery. The calculator is working just the way I want, but I'm quite new to jQuery and I wonder if I am using jQuery effectively.
The goal of the code is that if ...
8
votes
2
answers
1k
views
Typing King - a JavaScript typing game
This is what I made today and I'm keen for a review of my code to see what things I can do better or smarter. I don't know if its relevant but it took 2 hours to code.
Is it smart to use OOP for a ...
5
votes
1
answer
329
views
A program to evenly divide pizzas
I wrote a program to evenly divide pizzas.
And I tried to stylize it as a console.
I will be grateful for tips on improving my code.
Here is a sample image of the program after a user has entered ...