click event using data attribute | Community
Skip to main content
Employee
Jun 14, 2021 1:32 PM UTC
Solved

click event using data attribute

Hi all,

 

<td class="cmp-modal-downloads__col--action" data-asset-share-id="download-archive" data-asset-share-download-id="61a36495-c979-4900-95a4-08d9a2e0f506">

 

<a href="page link" class="ui positive primary right labeled icon button">
Download
<i class="download icon"></i>
</a>
</td>

 

how to do click event using "data-asset-share-id" attribute of download button which is inside table tag so that I can use other values which is inside td tag?

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Varun_Shakya
Varun_ShakyaAccepted solution
New Participant
Jun 14, 2021 1:42 PM UTC

Try this selector

$("[data-asset-share-id='download-archive']") to get the click event on attribute

4 replies

Employee
Jun 14, 2021 1:48 PM UTC

@varun_shakya I have used this selector but still click event isn't happening.

Translate
Varun_Shakya
New Participant
Jun 14, 2021 2:02 PM UTC
Try these selectors
Translate
Varun_Shakya
Varun_ShakyaAccepted solution
New Participant
Jun 14, 2021 1:42 PM UTC

Try this selector

$("[data-asset-share-id='download-archive']") to get the click event on attribute

Translate