Hi there
has anyone got the "Inserting a List of section images with JavaScript" part of the Advanced User Guide to work.
Whenever I put the code on a clean page and preview I get a javascript error ("object expected" I believe)
Here's the code as copied from the AUG. For a start should the language = javascript have quotations around javascript? I've also searched for pItem in the actiniccore.js and actinicextras.js and there seems to be no reference which may be throwing up the object expected error.
<!--@act NETQUOTEVAR:TOPLEVELSECTIONS_RAW -->
<SCRIPT LANGUAGE = JavaScript>
<!--
function ImageList(pItem)
{
var strIDs = '';
{
for (var i = 1; i <= pItem.length; i++)
{
strIDs += '<a href=' + pItem[i].sURL + '><img src="' + pItem[i].sImage + '"
alt="'+ pItem[i].sName + '" width=' + pItem[i].nImageWidth + ' height=' +
pItem[i].nImageHeight + ' border=0></a><br>';
}
}
return strIDs
}
-->
</SCRIPT>
Anyway, any ideas anyone?
Thanks in advance, Garry
has anyone got the "Inserting a List of section images with JavaScript" part of the Advanced User Guide to work.
Whenever I put the code on a clean page and preview I get a javascript error ("object expected" I believe)
Here's the code as copied from the AUG. For a start should the language = javascript have quotations around javascript? I've also searched for pItem in the actiniccore.js and actinicextras.js and there seems to be no reference which may be throwing up the object expected error.
<!--@act NETQUOTEVAR:TOPLEVELSECTIONS_RAW -->
<SCRIPT LANGUAGE = JavaScript>
<!--
function ImageList(pItem)
{
var strIDs = '';
{
for (var i = 1; i <= pItem.length; i++)
{
strIDs += '<a href=' + pItem[i].sURL + '><img src="' + pItem[i].sImage + '"
alt="'+ pItem[i].sName + '" width=' + pItem[i].nImageWidth + ' height=' +
pItem[i].nImageHeight + ' border=0></a><br>';
}
}
return strIDs
}
-->
</SCRIPT>
Anyway, any ideas anyone?
Thanks in advance, Garry
Comment