0
function deleteLogoOrTextbyAjax(rowID, tableName){
    alert(rowID);
    alert(tableName);

    jQuery.ajax({
        type: "POST",
        url: "/cycling/deleteLogoOrTextbyAjax",
        //dataType: 'json',
        data: { rowID: rowID, tableName: tableName },
        success: function (res) {
            $( "div[dbid=rowID]" ).remove();    //here i need help
        }
    });
}

passing rowID, i want to remove the div with the attribute 'dbid' that is equal to the passed value rowID.

$( "div[dbid=rowID]" ).remove();

the above code is not working

arun
  • 4,595
  • 5
  • 19
  • 39

1 Answers1

1

concat with + symbol

$( "div[dbid="+rowID+"]" ).remove();
Sudharsan S
  • 15,336
  • 3
  • 31
  • 49