我这是定义一个带有自定义的file_name超链接 通过函数,点击超链接获取值 function getself(obj) { alert( obj.getAttribute(“file_name”)); } 其他网上说用attr(),我试了很久不行,可能是版本问题