check format input and add regex