Is it possible to load recaptcha script only in url with fragment identifier (#)?

Is it possible to load recaptcha script only in url with fragment identifier (#)?

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)