How to execute custom loop before loop content?

Try using the genesis_before_content hook.

add_action('genesis_before_content', 'gt_custom_loop');
function gt_custom_loop() {

    // this gets executed after the page content, how to make it execute before?

}

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