# \[JQuery\] Objects

**URL:** <https://forum.kirupa.com/t/jquery-objects/234880>\
**Category:** web dev\
**Created:** [August 6, 2007, 10:36pm UTC](https://forum.kirupa.com/t/jquery-objects/234880 "2007-08-06T22:36:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Neolumi](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/neolumi/32/1306_2.png) [@Neolumi](https://forum.kirupa.com/u/Neolumi)\
**Post date:** [August 6, 2007, 10:36pm UTC](https://forum.kirupa.com/t/jquery-objects/234880/1 "2007-08-06T22:36:50Z")

</div>

Hi,

I’m trying to retrieve an attribute from an img (src) by using javascript & JQuery via DOM. Ive got the code returning “[object Object]” but am stuck as far as outputting the object/getting the src goes.

```auto

function doSwitch(){
    
    alert($(this+" img"));
    

}

$(document).ready(function() {
    $(".moreimgs li a").attr("onmouseover","doSwitch();");                   
});

```

does anyone have any ideas? 😕 thanks!
