Actually I want a pre-validation that when a user uploads a wrong file extension rather than a pdf file in WordPress gravity form than before submitting the form it should show the error that the file is wrong it should be PDF.
I use ajax="true" in gravity form shortcode its also a good option because the page is not refreshed in ajax=" true" but I want a pre-validation that when a user uploads a wrong file extension rather than a pdf file in WordPress gravity form than before submitting the form it should show the error that the file is wrong it should be PDF.
[gravityform id=5 title=false description=false ajax=true tabindex=49]
I already try this code but I want a pre-validation that when a user uploads a wrong file extension it shows error before submission