Tie the sending of an ajax request to WordPress hooks

Tie the sending of an ajax request to WordPress hooks

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