get image button value onclick

Posted on 2014-07-29
Last Modified: 2014-07-29
Question by:sevensnake77
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 58

Assisted Solution

Gary earned 167 total points
ID: 40227277
Get what value - there is no value
LVL 82

Accepted Solution

leakim971 earned 167 total points
ID: 40227282
$( "[id^=Delete]" ).click(function( event ) {
	 var ctID = $(this).attr("id");
    alert("you clicked " + ctID);

Open in new window

LVL 21

Assisted Solution

by:Randy Poole
Randy Poole earned 166 total points
ID: 40227291
Here is the code:
$( "[id^=Delete]" ).click(function( event ) {
	alert("you clicked " +;

Open in new window

Also make sure to the left on jsfiddle, frameworks and extensions to choose JQuery 2.x or whichever you are using..

Author Closing Comment

ID: 40227380
both were great thanks guys

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How Close unsubmited attempts 10 71
AJAx/JQuery/JSON Error 3 38
Adding Clickable Links to JQuery Data Items 24 54
Leaflet map example works but I want to make a change to it 5 25
Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question