replace img src - Jquery

replace img src

Snippet Code


  
Rate this page :
  [ 0 votes]

to replace the image path or img src using jquery use this snippet,

$('img').attr('src', 'test.jpg'); //you can use the id of the <img> like, $('#imag').attr('src', 'test.jpg');

Tags


Ask Questions

Ask Question