ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. xmlNodeSetValue

Function

xmlNodeSetValue

Server and clientXMLModified from MTA:SA

Sets the text inside a node (replaces the previous one).

Syntax

bool xmlNodeSetValue(xmlnode theXMLNode, string value)

Arguments

theXMLNodexmlnode
The node.
valuestring
The new text.

Differences from MTA:SA

  • These MTA:SA arguments are not here: boolean setCDATA = false

In MTA:SA

xmlNodeSetValue(xmlnode node, string value, boolean setCDATA = false)

Returns

true on success.

Example

local root = xmlCreateFile("motd.xml", "motd")
xmlNodeSetValue(root, "Nowy event w sobote!")
xmlSaveFile(root)
xmlUnloadFile(root)

See also