asp.net mvc - How to avoid the text from the action link -


@ajax.actionlink("&nbsp","delete", "financialintermediary",                   new { id = item.financialintermediaryid },                   new ajaxoptions { httpmethod = "get",                                     onsuccess = "deletesuccessfi",                                     confirm = "are sure perform deletion." },                  new { @class="classname" })   

css file is

.classname  {     background-image:url('../../images/delete.png');  } 

i used above code setting background image delete.

by doing can't avoid text.it comes enter image description here

i want image on place.please help

instead of using   use space:

@ajax.actionlink(" ","delete", "financialintermediary", new { id = item.financialintermediaryid }, new ajaxoptions { httpmethod = "get", onsuccess = "deletesuccessfi", confirm = "are sure perform deletion." },new { @class="classname" })   

you'd need make space element background-image can shown:

.classname         {             background-image:url('../../images/delete.png');             display: inline-block;             width: 20px; /* adjust necessary */             height: 10px;/* adjust necessary */          } 

Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -