If I save the html:

<a href="tel:1-800-222-3334"> (800) ABC - DEFG </a>

in the PublishingPageContent field it gets filtered down to:

<a> (800) ABC - DEFG </a>

How can I prevent this and other filtering of the PublishingPageContent field when updating the field programmatically (in c# on the server side).


Insert a Content Editor Web Part into the Page Content area and use the content area in that for the phone number. This is obviously not ideal as it messes up spacing a bit but it should work.

This is how Microsoft built the field. Waldek explain's how to create your own field here to get rid of those restrictions.


Their is no way to stop this pre filtering on save of the PublishingPageContent field.

My solution was to add another field to the Pages list and use that as an alternative to the PublishingPageContent field.

This alternative field was still being filtered until I set the RichText value to false:

fieldMultiLineText.RichText = false;
fieldMultiLineText.RichTextMode = SPRichTextMode.FullHtml;

At this point there is actually nothing in the publishing site type that I am able to use.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.