goCode
goCode

Reputation: 257

Antisamy-tinymce removing <img> tag

I am passing a image which is having html below :-

<p>tag img src="http://some image url link" alt="N2QWv.png (512&times;512)" /></p>

and my tag is getting removed though I have not provided it in remove tag.

I don't want my tag to be removed. Please any one who can help with this

Upvotes: 1

Views: 1009

Answers (1)

goCode
goCode

Reputation: 257

Give below in your policy file :-

<tag name="img" action="validate">
    <attribute name="src" /> 
    <attribute name="style" />
    <attribute name="title" />
    <attribute name="alt" />
</tag>

<attribute name="alt" description="The 'alt' attribute provides alternative text to users when its visual representation is not available">
    <regexp-list>
        <regexp name="paragraph" />
    </regexp-list>
</attribute>

In global attribute tag add this :-

<attribute name="src" />

Upvotes: 1

Related Questions