get_intermediate_image_sizes() returning different values depending on is_admin()

The problem was that I read the image sizes inside the “init” hook at which point the additional sizes are not loaded yet by WordPress. I used a “later” hook now and it works.

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