Getting _writepage writing to the proper directory