= ' . $row['rgt'] , $site['db']['connection']); mysql_query('UPDATE tree SET lft=lft+2 WHERE lft > ' . $row['rgt'] , $site['db']['connection']); mysql_query('INSERT INTO nodes SET name = \'' . $_POST['name'] . '\', type = \'' . $_POST['type'] . '\', description = \'' . $_POST['description'] . '\', bitrate = ' . (int) $_POST['bitrate'] . ', url = \'' . $_POST['url'] . '\', mime_type = \'' . $_POST['mime_type'] . '\', location = \'' . $_POST['location'] . '\', bookmark = \'' . $_POST['bookmark'] . '\'', $site['db']['connection']); mysql_query('INSERT INTO tree (node_id, lft, rgt) VALUES (' . mysql_insert_id() . ', ' . $row['rgt'] . ', ' . $row['rgt'] . ' + 1)' , $site['db']['connection']); echo 'Node added successfully!
back'; } else { echo '
Type
Name
Description
Bitrate
URL
Mime Type
Location
Bookmark
'; } ?>