Welcome to Code Forum!

Join a community that supports you and your coding journey from day one. We strive to be a friendly, supportive community that empowers everyone to be better developers. By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

javascript

  1. M

    Node.JS Code Assistance

    I'm currently working on a project where I need to implement a table filter using checkboxes, and I'm facing some challenges. I've managed to set up the basic functionality, but I'm struggling with a couple of specific requirements. I'm reaching out to the community for some guidance and...
  2. S

    JavaScript Get the value of html element within the 'dd itemprop'

    I am trying to get the value of the notarisation_url value within the 'dd itemprop' I tried this javascript code, but its not working. It retruns undefined. const els = [document.getElementsById('wrap')]; props = els.filter(x => !!x.getAttribute('notarisation_url')); console.log(props) I...
  3. developpersoft

    JavaScript How to understand js code for plugins?

    Hi There, I have problem to understand javascript code in plugins I don't know how this works all the elements symbolized without using document.getElementById to add an HTML Elements or change it But in plugins I only find The code Like this : var ap = Object.defineProperty; var lp =...
  4. J

    JavaScript Uncaught ReferenceError: displayText is not defined at HTMLAreaElement.<anonymous>

    Here's an error that has been plaguing me every time I try to add a function from within an onclick. It happens for seemingly no reason. Here is the code: export class Clickables { constructor(game) { this.game = game; this.doOnce = false; this.textDisplaying =...
  5. J

    JavaScript Click on instance of image to trigger event

    Hello I'm trying to make a Point & Click adventure game so I have multiple boxes derived from a PNG image file like so: When the player clicks on a particular box, a particular event should happen. Being a PNG the image can later be made transparent. In any case, here is the code I have so...
  6. S

    Web animations | A few questions?

    Hi, I need help for a project, where states are to be mapped graphically, see the picture in the attachment. It is about the fact that when states and variables in javascript change, this should be displayed graphically. Until now I have done it so that there is a picture for all possible...
  7. vishal

    JavaScript How can we detect when user is going back using browser navigation back arrow button or history.back()?

    I want to perform an action when user navigates from one page to another but i don't want to perform anything when user clicks on back arrow or basically goes to previous screen using browsers history. Navigation is being done normally like using anchor tags or window.location.href. I have tried...
  8. D

    PHP Simple powerful PHP library for data sanitization

    Hello, I've created a highly efficient and robust PHP library designed specifically for data sanitization. It combines simplicity with remarkable power, ensuring swift processing. This library empowers you to effortlessly sanitize diverse data types, eliminating the need for extensive manual...
  9. RealImmortal2004

    How do I add a working window(print) function to just an html table that has data from a json file?

    I've tried googling how to do this but I can't find any useful results. The code below is what I want to print. I want it to be able to print whatever is in the table and I want to be able to print certain things based on filtering. How can I print the table without having to create a linked...
  10. edwardsmarkf

    JavaScript a couple of js debounce questions

    hello all - having studied these two excellent examples: https://dillionmegida.com/p/debouncing-in-javascript/ https://www.freecodecamp.org/news/javascript-debounce-example/ surprisingly neither of them included how to pass the event information to the debounced script. here is what i...
  11. A

    JavaScript Attempting to deliver an hls stream using express, works in browser but wont play in HLS player

    I am trying to make an express server that takes rtsp(am using ffmpeg) converted to hls/m3u8 and streams it upon request(so it can later be viewed on a client).I am still learning and am not too familiar, so any and all help is appreciated - if you have any resources that could help me in this...
  12. edwardsmarkf

    JavaScript using "import from" dynamically

    hello - i have used the following syntax a number of times with much success: let script = document.createElement('script') ; script.src = '/js/myJavaScript.js' ; script.type = 'text/javascript' ...
  13. Y

    JavaScript Find The Length Of A String

    Hi, I've just started to learn JavaScript, being a beginner. In order to qualify myself for the proper boot camp, I must do a kind of online course first and pass some challenges. I've got a bit stack in a very simple situation. My problem is: Create a new variable called stringLength. Use...
  14. J

    JavaScript How to select area value from geojson using javascript

    I'm trying to right a javascript function that selects a polygon based on area value. The criterea is to select largest value if the heighest area value of a feature collection plygons is <= 20. Else, if the smalest area value a feature collection plygons is > 20, to select the smallest value...
  15. jaredcb

    JavaScript Getting the sum of equal array elements, and creating a new array

    I'm scratching my head over this one. Not sure if I'm asking this question wrong, but I'm trying to reach out where I can hopefully find someone who knows what I can try. I tried asking this on another forum, and they didn't like that I didn't have any example of failed code yet, so they...
  16. Q

    Can Anyone Help With Repairing The Bug In This Code?

    I have set myself the task of trying to effectively diagnose a Bug in this piece of code, which has been written in JavaScript. the problem. How does a coder who has just started to learn coding, use 'variable watching', 'compiler warnings' and a 'unit test' for this objective? Here is the piece...
  17. P

    JavaScript How to push onto browser history

    I am trying to push a URL onto a browser history to "prevent" the back button from going back to the previous page. Currently if the user clicks the back button, they simply go back to the Feedback page with the Submit button in a disabled state, which, while it prevents the user from flooding...
  18. C

    Saving dropdown options to server

    So far, I have the following code: <!DOCTYPE html> <html> <head> <title>Company HR</title> <style> h1 { font-family: verdana; text-align: center; font-size: 50px; } table, th, td, select { border: 1px solid black...
  19. speedychapo

    JavaScript Javascript code works more than once

    Hello everyone, I will try to explain briefly but not sure I can do that or not. When I click on the edit button, a modal page appears on the screen. Inside this modal, there is is_index_sample_edit button. Clicking the X symbol(not refresh the page) in the upper right corner closes the edit...
  20. A

    JavaScript Call several times a javascript on the same page

    hey guy I'm working a MCQ and would like to have random number to be display for my question and my answers. basicaly, I have 12 names assign to 12 numbers and I have to choose in 5 answers which one is the correct one. First question is working because, it is the fisrt time it is called but...
Back
Top Bottom