mgd_create_page_element

(Midgard 1.4.2 'Bifrost')

mgd_create_page_element -- Create a page element

Description

int mgd_create_page_element (int page, string name, string value, bool inherit)

Minimum version: Midgard 1.0

Creates a new page element with the provide parameters.

Returns the id of the created record if successful. Returns FALSE on failure.


<?php
 $page    = 17;
 $name    = "head-title";
 $value   = "<title>Just an example<title>";
 $inherit = 0;
 mgd_create_page_element( $page, $name, $value, $inherit);
 $err = mgd_errno();
 if( $err ) {
   echo "Could not create page element.<br>";
   echo "reason: " . mgd_errstr( $err );
 } else {
   echo "page element created.";
 }
?>