SF 4.1: Double quotes cannot be used in page description - t

Posted by Community Admin on 04-Aug-2018 15:28

SF 4.1: Double quotes cannot be used in page description - throws 'The server block is not well formed' exception

All Replies

Posted by Community Admin on 20-Apr-2011 00:00

See attached image for exact exception. The exception was traced to the page description having double quotes within the text which apparently breaks Sitefinity 4.1

Stay "tuned-in" to the...

Note that this exception is not related to the one posted in the forums related to maximum length.

If text is changed to single quote everything works fine.
Stay 'tuned-in' to the...

Please resolve asap.

Posted by Community Admin on 20-Apr-2011 00:00

Pavel, I'm pretty sure you'll get this with any asp.net server control. If you want to use double quotes for content then you need to use single quotes for your tag.

The following is a simple example that would cause the exact same problem on a standard asp.net page.

NOT OK:
<asp:Label ID="1" runat="server" Text="Test "my" text" />

OK:
<asp:Label ID="1" runat="server" Text='Test "my" text' />

Notice the change to using single quotes after Text=  Try this and you should be ok.

Cheers,
Phill

Posted by Community Admin on 20-Apr-2011 00:00

The issue is that Sitefinity renders the content for the Meta Description unescaped - the <meta> tag is not created by me either in page or code... In this particular case the Meta Description is a page property that a SF can enter freely in the admin UI and SF4.1 does not handle well the double quotes.

Posted by Community Admin on 20-Apr-2011 00:00

Gotcha, I thought the screen grab was from a Master Page/Template you had created. I now see how this is indeed another SF bug.  So then I guess my response of basic .net programming should be directed to Sitefinity devs and not you ;)

Cheers,
Phill

Posted by Community Admin on 26-Apr-2011 00:00

Hi,

Can you try escaping the quotes - "Stay &quot;tuned-in&quot; to the..". Indeed there is an issue, because we do not escape them and this is something that we have to fix.

Greetings,
Ivan Dimitrov
the Telerik team


Posted by Community Admin on 08-Jun-2012 00:00

I see that also SF 4.4 doesn't escape them. Please let me know if I'm wrong.

Posted by Community Admin on 14-Feb-2013 00:00

This is still an issue in SF 5.0

Posted by Community Admin on 13-May-2013 00:00

Has anyone found a workaround or fix for this?

Posted by Community Admin on 13-May-2013 00:00

There isn't a fix for it but you can remove the special character from the keywords and description fields on a page's properties.  I've included a screenshot of the fields I am talking about.  Here is a PITS support created when I submitted this as an issue.

This thread is closed