Update index.php

make data dir if not exists.