Skip to main content

xmloxide_set_attribute

Function xmloxide_set_attribute 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn xmloxide_set_attribute( doc: *mut Document, node: u32, name: *const c_char, value: *const c_char, ) -> i32
Expand description

Sets an attribute on an element node. Returns 1 on success, 0 on failure.

If the attribute already exists, its value is updated.

§Safety

doc must be a valid mutable document pointer. name and value must be valid null-terminated UTF-8 strings.