Fixed the input validation check. When adding a custom template to a site's page, if the user does not enter a value for 'order' field, it caused the program to throw a NumberFormatException.
recommit for Mar20, Apr05, Apr13 due to loss