Add page control functions
Let filetree and parent_node as global variable