我想将“rel = nofollow”添加到所有“a”标签。
tinymce.init({
selector: 'textarea',
extended_valid_elements: 'img[!src|alt],a[!href|target|width|height|title|rel=nofollow]',
valid_elements : 'p,br,a,strong,span[style],em,ul,ol,li',
});
使用上面包含的代码,我得到了您正在寻找的行为,将 arel="nofollow"
添加到<a>
标签中。这是一个 Tiny Fiddle 演示:
http: //fiddle.tinymce.com/Wthaab
你在那个小提琴中得到不同的结果吗?