Discuss Help:Datatype "Text"

From semantic-mediawiki.org

Contents

Thread titleRepliesLast modified
set_internal, type text and templates/ref012:51, 14 August 2015
Searching for text properties006:27, 21 November 2012
How to safely escape transcluded templates stored as text/code values in semantic properties000:22, 21 November 2012

set_internal, type text and templates/ref

Hi. I'm using set_internal and one property stores text. All is good for plain text, but when text includes <ref>, templates, etc, the property value is blank (not stored). How can I escape these values?

12:51, 14 August 2015

Searching for text properties

The price for this additional freedom is that it is not possible to use specific values of Type:Text in semantic queries

Perhaps, you could enable simple (equality only) queries for properties of the type Text by storing hashes of the texts and comparing them with hashes of query conditions.

06:27, 21 November 2012

How to safely escape transcluded templates stored as text/code values in semantic properties

As noted in thread subject, I'd like to do the following: {{#set:Has text={{{Some_template_name_as_incoming_parameter|}}}}}, where 'Has text' is of the text and/ or code special type. However, this throws a 'Has improper value for' "error" for certain assignments (presumably resulting from invalid characters within the target template). Is there a best practice for escaping template content at time of value assignment to avoid such errors?

Thanks!

17:48, 20 November 2012