word press media image url value show undefine

I am tired lot of hours but image url show undefined please kindly help me

function getimg(button, field)

{
formfield = jQuery(‘#’+field).attr(‘name’);

tb_show(”, ‘media-upload.php?type=image&TB_iframe=true’);

window.send_to_editor = function(html) {
imgurl = jQuery(‘img’,html).attr(‘src’);

jQuery(‘#’+field).val(imgurl);
tb_remove();

}
}

my form text field

Read more here:: word press media image url value show undefine

Leave a Reply

Your email address will not be published. Required fields are marked *