axl main logo
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Modules Pages
char * axl_node_content_translate_defaults ( char *  content,
int *  content_size 

Replaces all entity references to its corresponding values.

This function only implements translation for default recognized entities (&, <, >, ' and ").

contentThe string content having escaped XML declarations such &gt; or &lt; which should be translated into its corresponding utf-8 symbol (for example > and <).
content_sizeA non-optional reference to an integer variable which will hold the new size of the string returned. You can pass a variable initialized to 0 or -1 to let the function to calculate the initial string length (by using strlen).

Because the substitution pattern applied on this operation makes not necessary to allocate memory, the function return the same string received, but with all values replaced. If you want to avoid this behaviour, use axl_strdup before calling to this function.

Returns the string modified or NULL if it fails.

References axl_return_val_if_fail.

Referenced by axl_node_get_attribute_value_trans(), and axl_node_get_content_trans().