Forum Moderators: open
It is also a good idea to put your scripts in a .js file and refer to them
<script language="JavaScript" src="filename.js">
</script>
As opposed to filling your page with lots of fat bloaty code.
The noscript tag is also quite useful, and of course essential for people with non javascript enabled browsers.
Not a direct answer to your JavaScript issue, but having a static html link to a Site Map could be an alternative for having certain section(s) of your desire to be crawled.
As for Site Map link on the Home page, it's a level 1 status, so in theory, a spider will follow the link and perhaps, will contuinue on with the crawling process for the links in the Site Map.
MHO HTH:)
Not sure if i follow your question re: "part of the page"
The spider will not index this
<a href="javascript:;" onClick="openaWindow('details.php?custid=2','pop','scrollbars=yes,width=600,height=380')" >
As all it will see will be this - javascript:;
Whereas if your noscript tag contained this
<noscript>
<a href="details.phpcustid=2" >
</noscript>
Then it will see the file and spider it.