1Use jQuery .siblings() to select the matching sibling.
2
3$(this).siblings('.bidbutton');
1<!doctype html>
2<html lang="en">
3<head>
4 <meta charset="utf-8">
5 <title>siblings demo</title>
6 <script src="https://code.jquery.com/jquery-3.4.1.js"></script>
7</head>
8<body>
9
10<div><span>Hello</span></div>
11<p class="selected">Hello Again</p>
12<p>And Again</p>
13
14<script>
15$( "p" ).siblings( ".selected" ).css( "background", "yellow" );
16</script>
17
18</body>
19</html>
20