I have a question about how to update column in the same row using css class selector. below is the example scenario.
Item | Price | Discount <User Input> | Final Price |
---|---|---|---|
Mobile | 500 | 10 | 450 |
Laptop | 1000 | 20 | 800 |
From the above table, discount column has text fields at each row. When user enters the discount percentage, the final price of that row much be updated accordingly.
assume that column Final Price has class attribute(.final-price).
Please let me know the css selector for this scenario so that I can use it in JavaScript?
Thanks in advance.
Sri
I have tried:
I tried using siblings() function from css, however it ended up using number, siblings()[3]. Somehow, I need to make this dynamically (not numbering).