You must install the plugin Geo Mashup Custom. After that, access the plugin folder and create a js file. If you are using google v3 api create file custom-googlev3.js and then copy paste this code:
GeoMashup.addAction( 'selectedMarker', function( properties, marker, map ) {
var objects = GeoMashup.getMarkerObjects( marker );
if ( objects.length > 0 && GeoMashup.have_parent_access ) {
parent.location.href = properties.home_url + '?p=' + objects[0].object_id;
}
});
Please also read the JavaScript API reference.