XmlLoadFile: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(updated) |
||
Line 11: | Line 11: | ||
===Required Arguments=== | ===Required Arguments=== | ||
*'''filename:''' The path to the file you wish to load. This | *'''filename:''' The path to the file you wish to load. This is a path relative to the '''server installation directory'''. | ||
</section> | </section> | ||
<section name="Client" class="client" show="true"> | <section name="Client" class="client" show="true"> | ||
Line 19: | Line 19: | ||
===Required Arguments=== | ===Required Arguments=== | ||
*'''filename:''' The path to the file you wish to load. This | *'''filename:''' The path to the file you wish to load. This is a path relative to the '''"mods\deathmatch" folder found in your MTA San Andreas installation directory.'''. | ||
</section> | </section> | ||
Revision as of 22:50, 7 September 2007
This function provides an alternative way to load XML files to getResourceConfig. This function loads an XML file and returns the node by specifying a specific file path, while getResourceConfig allows for loading an XML file from a resource.
Syntax
Click to collapse [-]
Serverxmlnode xmlLoadFile ( string filename )
Required Arguments
- filename: The path to the file you wish to load. This is a path relative to the server installation directory.
Click to collapse [-]
Clientxmlnode xmlLoadFile ( string filename )
Required Arguments
- filename: The path to the file you wish to load. This is a path relative to the "mods\deathmatch" folder found in your MTA San Andreas installation directory..
Returns
Returns the root xmlnode object of an xml file if successful, or false otherwise.
Example
This example loads an XML file called test.xml.
node = xmlLoadFile ( "test.xml" )
See Also
- xmlCopyFile
- xmlCreateChild
- xmlCreateFile
- xmlDestroyNode
- xmlFindChild
- xmlLoadFile
- xmlLoadString
- xmlNodeGetAttribute
- xmlNodeGetAttributes
- xmlNodeGetChildren
- xmlNodeGetName
- xmlNodeGetParent
- xmlNodeGetValue
- xmlNodeSetAttribute
- xmlNodeSetName
- xmlNodeSetValue
- xmlSaveFile
- xmlUnloadFile