There's is a problem in the release versions include method.. try replacing
it with (in the DynAPI.js file):
include : function(src,path) {
if (src.substring(src.length-3)!=".js") src+=".js";
var pckg=src.substring(0,src.indexOf('.'));
var groupname=src.substring(src.indexOf('.')+1);
var realsrc=groupname.substring(groupname.indexOf('.')+1);
groupname=groupname.substring(0,groupname.indexOf('.'));
if (!path) {
var path=DynAPI.librarypath;
if (src.indexOf('.*')>0) {
src=src.substring(0,src.indexOf('.*'));
if (DynAPI.packages[pckg]) group =
DynAPI.packages[pckg].libs[groupname];
if (group) {
for (var i in group)
document.write('<script
language="Javascript"
src="'+path+pckg+'/'+groupname+'/'+group[i]+'"><\/script>');
}
else
alert(DynAPI.toString()+'\n\nError
occured\nThe following package could
not be loaded:\n'+src+'\n\nmake sure you specified the correct path.');
}
else document.write('<script language="Javascript"
src="'+path+pckg+'/'+groupname+'/'+realsrc+'"><\/script>');
}
else document.write('<script language="Javascript"
src="'+path+'/'+src+'"><\/script>');
}
this code is also in the current snapshot release, and should fix include
problems.
Pascal Bestebroer
[EMAIL PROTECTED]
http://www.dynamic-core.net
> -----Oorspronkelijk bericht-----
> Van: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]Namens Cristian Grigoriu
> Verzonden: maandag 15 januari 2001 17:35
> Aan: '[EMAIL PROTECTED]'
> Onderwerp: [Dynapi-Help] DynAPI.include()
>
>
> I'm trying to follow Pascal's tutorial "Using the DynAPI - part 4 :
> Widgets".
> Unfortunately, I'm unable to run the example. I always get: "button" is
> undefined in bothe NS and IE. I suspect 'button.js' is not included. I
> tryed
> moving the file in different locations with no avail. What am I doing
> wrong?
>
> Thanks,
> Grig
>
> _______________________________________________
> Dynapi-Help mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/dynapi-help
>
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help