User763094243 posted
Hi all,
I am working on a website in multiple languages and have been using resource files in App_GlobalResources to do this. I have modified the schema as follows to allow html in the values so I can add some formatting to the text -
<xsd:complexType name="text">
<xsd:complexContent mixed="true">
<xsd:restriction base="xsd:anyType">
<xsd:sequence>
<xsd:any processContents="lax" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
<xsd:attribute ref="xml:lang"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
and
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="text" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
Unfortunately as soon as I add any html to the text in the resource file, I can no longer read it, either as an object or string -
String text = Global.SiteResourceManager.GetString(textName, culture);
Anyone know how to do this if it is possible?
Best wishes,
Robert