in the web root
just run the command in ssh
Code:
$grep -rni 'javascr\|script' | less
or $grep -rni 'javascr\|script' > FILE SAVED. TXT
Then you can read through the scripts for any unexpected code -- you may find a corrupt file. that should grep the script tags
Wordpress on shared servers is always precarious.
save the images and delete the wordpress saving the database used. reinstall a clean wordpress maybe the database is still good.
without shell access ... You can try some online scans but I would not waste a lot of time on a trashed wordpress.