Change href of element

$('#mycal1 a').attr('href', '#');​

HTML

<div id="mycal1">
<a id="google" href="http://www.google.com">This takes you to Google</a>
<br>
<a id="yandex" href="http://www.yandex.com">This takes you to Yandex</a>
<br>
<a id="mail" href="http://www.mail.ru">This takes you to Mail.ru</a>
</div>

JavaScript

try {
                dojo.ready(function(){
                		alert("dojo.ready");
                    if(dojo.byId("yandex")!=null) {
                    	alert("yandex");
                        /*
                        dojo.connect(dojo.byId("btnPrint"),"onclick",function(){
                            var cardPrintUrl = '$vc.getAppUri()/insurant/card/print?current_org='+id+'&action=print';
                            var interCalcsPrintUrl = '$vc.getAppUri()/insurant/card/inter-calcs-print?current_org='+id+'&action=print';
                            var printUrl = [cardPrintUrl,interCalcsPrintUrl];
                            var loc = printUrl[activeTab];
                            try {
                                var win = window.open(loc, 'printWindow');
                                if(win.window.focus)
                                {
                                    win.window.focus();
                                }
                            } catch (e) {
                                //alert(e);
                            }
                        });
                        */
                    }
                    else
                    {
                    	alert("no yandex");
                    }
                });
            } catch(e){alert("Exception: " + e)}