Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
74 views

I have an xmldoc with an SVG element that I am trying to pre-process and clean up to do some things. The actual file has several thousand elements, and I want to remove the ones I do not want in the ...
lukehawk's user avatar
  • 1,523
1 vote
2 answers
266 views

I am trying to extract bus prices between 2 cities in Ontario, Canada. I am using Selenium/Python to do this: The website is here and it has default cities and dates. Here is my Python code: from ...
brooklin7's user avatar
3 votes
2 answers
89 views

I am trying to get an element, and element's fontSize property and update the size with keypresses. I press the up'ArrowUp' and down 'ArrowDown' but nothing happens, the fontSize property does not ...
Buzzanags's user avatar
0 votes
0 answers
81 views

I am trying to create an automation tool for scraping a site. As part of that, I am making a Python script that utilizes the Remote Debugging protocol through this library: https://github.com/jpramosi/...
Noob Doob's user avatar
  • 1,967
1 vote
1 answer
78 views

This ist the HTML of a public website: <div class="flex flex-col md:flex-row mb-[1.0rem]"> <div class="align-text-top pr-1 md:pr-7 w-41">NUMBER:</div> <div class="...
Jasco's user avatar
  • 253
0 votes
0 answers
183 views

I am trying to use nodeJs with puppeteer to scrape for YouTube video information from the search results. Unfortunately, for some reason, the scrape doesn't load the elements via the document query ...
keshawn Sharper's user avatar
0 votes
0 answers
50 views

I'm injecting a script which is supposed to click on an element as soon as it appears on the browser page. It is able to find the element, however .click() doesn't actually click it, despite ...
user28878583's user avatar
0 votes
1 answer
61 views

I have a popup login box on my site, I use <a class="logincontent">Login</a> which then calls up this function: document.querySelector('a.logincontent').onclick = () => { ...
Ben Edwards's user avatar
1 vote
1 answer
229 views

On this public website, depending on the selected federal state, 30 properties are listed on the right-hand side. If this federal state offers more than 30 properties, then another 30 are listed on ...
Jasco's user avatar
  • 253
0 votes
1 answer
1k views

Basically, I'm following this exercise https://www.youtube.com/watch?v=EerdGm-ehJQ&t=50183s 14n, part 2. My page looks like this:I'm focusing on the input bar with the '3' inside it When I press '...
Myterion's user avatar
0 votes
2 answers
167 views

My website uses this in the frame.html head so it appears globally: <!--START: infopages--> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.1/jquery.min.js"></...
Stuff Things's user avatar
-1 votes
1 answer
85 views

I have onClick function but I cannot access to its children elements from the event <div className="sortingBy" onClick={openSoring}> <div className="checkBox" ></div&...
Ali Alipour's user avatar
3 votes
2 answers
143 views

querySelector can return any subtype of Element. On a webpage this would almost certainly be either HTMLElement or SVGElement. The two are not compatible, and yet TypeScript seems happy for me to ...
Aayla Secura's user avatar
3 votes
3 answers
72 views

This is a problem I was having: I am trying to access the button inside of the div and make each of them log its own text content on click. But all of them display all of the text content. And it has ...
Sara Freitas's user avatar
0 votes
1 answer
234 views

Let's say I have an element and I want to select the next matching sibling. Normally, in css I'd be able to write <some selector for this element> ~ <selector for sibling>, but the sibling ...
Aayla Secura's user avatar
0 votes
1 answer
169 views

In JavaScript I need to detect if YouTube ad is currently playing, my code is not working for me. This is a single page personal project no need to use YouTube Data API. function ...
DL Studio's user avatar
  • 4,865
2 votes
0 answers
147 views

I'm new to vue.js and I've encountered a problem that I can't fix. In my SelectField.vue component I have written the following method: getModalBodyElement() { return document.querySelector('....
michael.brilz's user avatar
1 vote
1 answer
80 views

My code is working well in Chrome but not in Firefox. When I search path element using querySelector with attribute Firefox gives an error that path is not found. defs.appendChild(svgGradient); const ...
Muhammad Amir's user avatar
0 votes
1 answer
87 views

I need to extract the 'href' from the html code of this website that is public and without any login: (To access the page via xmlhttp, it needs a REFERER, that is posted as REFSTRING) Public Website ...
Jasco's user avatar
  • 253
0 votes
2 answers
85 views

I want to select all the inputs in a form except those within a specific element. Consider the following sample HTML: <form id="myForm"> <input /> <input /> &...
Salih Kavaf's user avatar
  • 1,175
1 vote
4 answers
133 views

Let's say that instead of looking at the ID, I want to select all a.href elements that contain (a piece of) this example: if document.url is "www.youtube.com". var youtubeID = document....
Mediamash's user avatar
0 votes
0 answers
49 views

Assume you're not able to access an Element type, only a Node type. (I have this constraint because I'm using inject(ElementRef) in Angular, but there are other cases where it might happen) A Node ...
Tovar's user avatar
  • 475
0 votes
0 answers
25 views

const text5 = document.querySelector('#p3'); text5.textContent = "Hello World"; div#Can span#Orig { display: show; } div#Can:hover span#Orig { display: none; } div#Can span#p3 { display: none;...
Andy's user avatar
  • 1
-1 votes
2 answers
73 views

html is basically boiler plate <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="...
user34539's user avatar
2 votes
0 answers
53 views

I am trying to create an flask app that uses Jinja templating. I have a navbar that contains links with the class name 'nav-link'. They are in base.html. I dynamically create index.html. Later I try ...
Code Master's user avatar
0 votes
1 answer
83 views

I have the following html: <body> <span class="comment"> EXAMPLES: <p><i>Example 1</i> - <a href="https://example.com/1">...
sudoExclamationExclamation's user avatar
1 vote
1 answer
405 views

I have been going round and round on this. I can't seem to get the button to open the chat widget on my website. It works fine in the codepen I have. <button class="chat-button">Live ...
lostInTheTetons's user avatar
0 votes
0 answers
72 views

I have a div element by id "test", and here is my javascript code: const test = document.querySelector("#test"); console.log(test); Then I open the console of Edge, but the result ...
suyangzuo's user avatar
  • 103
1 vote
0 answers
534 views

Hey I'm a new coder and I'm using freecode camp to learn js. I'm currently on the calorie counter exercise and I'm duplicating the code in VsCode. I just added an addEntry button to the js using a ...
Babatunji Afolayan's user avatar
0 votes
0 answers
36 views

Good morning, I'm doing a school practice named pokemon ultimate battle experience the game consists of 10 cards (5 for the player, 5 for the PC), when you click in a card, it goes in the middle, the ...
SamuehFDEZ's user avatar
1 vote
1 answer
151 views

I am developing a calculator as a part of the frontEndMasters course but I cannot get the numbers to work, number seven only works. I would like to know if there is any workaround for this since I ...
Agus's user avatar
  • 13
0 votes
1 answer
59 views

How do I select the textfield element "member-name"? function revealPaywall (){ const paywall = document.getElementById('paywall') const name = localStorage.getItem("value"); //...
HectorACampo NYC's user avatar
0 votes
0 answers
16 views

I wrote a rock, paper, scissor game and set the score in local storage using getItem and setItem .I wrote a paragraph with class=jsscore and tried to display the HTML content inside the script with a ...
Manasa's user avatar
  • 11
0 votes
2 answers
370 views

I want to find and replace some of the *innerHTML *with regex. I want to do this across a document acting on everything except anchor elements. I thought I could do this with queryselectorAll, by ...
Jezza's user avatar
  • 3
-1 votes
1 answer
330 views

What could cause queryselector to not find an element in such a scenario function load_home(){ //this function has a lot of fetch calls and creates a lot of divs } document.addEventListener("...
daultimateboss's user avatar
0 votes
1 answer
599 views

I have different groups of items. When the user selects a group, the list of items updates and I then want to add a class to all the items in the selected group. I'm trying to use useEffect to render ...
dawphin777's user avatar
0 votes
0 answers
43 views

Basically, I have this piece of code: if (this.variantId || theme.config.mqlSmall) { this.addEventListener('click', this.onHoverHandler.bind(this)); this.querySelector('a')....
ivangarcia82's user avatar
0 votes
1 answer
309 views

For example, we have this XML: <?xml version="1.0" encoding="UTF-8"?> <xml xmlns:media="http://search.yahoo.com/mrss/"> <media:content></media:...
Ulysses Zhan's user avatar
0 votes
1 answer
1k views

I am trying to add a class to an element inside of the shadow root for 3 slides within a carousel. Here is my code: let modalFlexDisplay = document.querySelector("#ipm-ad-modal-div") ...
Ripley E's user avatar
0 votes
0 answers
74 views

I want to get the questions and answers from People Also Ask section of google using javascript (but inside a vb.net cefsharp browser using executequery). The section needs to be clicked to be ...
xhammer's user avatar
  • 145
0 votes
1 answer
87 views

I have an element with a className containing an @ symbol. Such as <div class="modify@s"> I can easily style this via a css selctor such as .modify\@s But I can't use this selector to ...
Type-Style's user avatar
  • 1,879
0 votes
3 answers
2k views

I need to execute a function on an element that may or may not exist in the DOM, using a querySelector (not querySelectorAll, because there will be at most one such element). The most elegant solution ...
Tom's user avatar
  • 2,064
0 votes
1 answer
36 views

I have a question about adding/removing in HTML. I have a list, with, say, 3 li. to add one more li I can use either(coach's ) : const myList = document.querySelector("ul"); const myItem = ...
Ira's user avatar
  • 11
0 votes
2 answers
87 views

Given HTML: <div class="element" data-name="cat"> <div class="element" data-name="bird"> <div class="element" data-name="dog"&...
Anna FLYTE's user avatar
0 votes
0 answers
66 views

(Sorry for my English, it's not my native language) I created a function that widens a wrapper containing a visible small element and display an invisible element (map). If I click on another wrapper, ...
user22661023's user avatar
-1 votes
1 answer
44 views

I need to create a function for changing the CSS Style like the below: (because I use this several times in my code) document.querySelector('.number').style.width = '30rem'; document.querySelector('....
A safari's user avatar
0 votes
0 answers
37 views

I got a page that contains many a tags. I need to select those who has "/[a-z]/" pattern in their href prop. I wrote something like this: document.querySelectorAll("a[href='/a-z+/']&...
Behzad Safamanesh's user avatar
0 votes
2 answers
285 views

I have a local testing environment, where I want to temporary override querySelector. I know that monkeypatching is bad practice, but in this case this code will only be used locally on developer side....
romand's user avatar
  • 29
1 vote
1 answer
596 views

I don't get the difference between using querySelector() and, let's say, getElementById(). I understand that querySelector retrieves an element by using any selector, which makes it more versatile. ...
gorrangi's user avatar
6 votes
1 answer
88 views

I'm confused why $1 is firstBB, The querySelector('.aa .bb') call should execute under #root element. const $1 = document.querySelector('#root').querySelector('.aa .bb'); const $2 = document....
White Wang's user avatar

1
2 3 4 5
10