How to query details of images in gallery that is attached to a post

Query for image attachments would be something like this (taken from Get The Image plugin/extension) with get_children():

$attachments = get_children( array( 
    'post_parent' => $args['post_id'], 
    'post_status' => 'inherit', 
    'post_type' => 'attachment', 
    'post_mime_type' => 'image', 
    'order' => 'ASC', 
    'orderby' => 'menu_order ID' 
) );

Then you can loop through array and retrieve URLs with wp_get_attachment_image_src() which will get you URL and dimensions.

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