wp trim function not working

the_content echoes post content. It does not return a string that you can manipulate. You need get_the_content() Swap those functions and it should work.

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