View Full Version : Ext is undefined
franc3
6 Apr 2007, 3:14 AM
Hello,
I'm a newbie and just trying ext for the first time.
In the head of my page, I have the following code to include Ext library :
<script type="text/javascript" src="http://192.168.0.1/sail-regatta/javascript/ext/ext-yui-adapter.js" ></script>
Then, when I try to call the Ext object on another script on the same page, I have an error : 'Ext' is undefined
Is there something else to do before calling Ext object ?
Thanks
sonic64
6 Apr 2007, 3:17 AM
Make sure you include all the necessary files from the ext library. Also make sure you're using the latest version of ext.
brian.moeskau
6 Apr 2007, 3:57 AM
<script type="text/javascript" src="yui-utilities.js"></script>
<script type="text/javascript" src="ext-yui-adapter.js"></script>
<script type="text/javascript" src="ext-all-debug.js"></script>
<link rel="stylesheet" type="text/css" href="ext-all.css">
That will get you everything and is the best way to go when starting out. Later once you're familiar with how things work you can consider cutting it down to specific components/stylesheets.
franc3
6 Apr 2007, 4:32 AM
@Sonic64 : I downloaded Ext this morning, so it's the latest version.
@brian.moeskau :
Here is my updated header include code :
<script type="text/javascript" src="http://192.168.0.1/sail-regatta/javascript/ext/yui-utilities.js" ></script>
<script type="text/javascript" src="http://192.168.0.1/sail-regatta/javascript/ext/ext-yui-adapter.js" ></script>
<script type="text/javascript" src="http://192.168.0.1/sail-regatta/javascript/ext/ext-all-debug.js" ></script>
and the code in my page :
<script type="text/javascript">
Ext.onReady(function() {
alert("Congratulations! You have Ext configured correctly!");
});
</script>
And there's always the same error : Ext is undefined
brian.moeskau
6 Apr 2007, 5:04 AM
If you're getting that error, your includes are not working. If you type each url like 'http://192.168.0.1/sail-regatta/javascript/ext/yui-utilities.js' directly into the browser does the file come up correctly?
franc3
6 Apr 2007, 5:05 AM
I just find the problem
It was just a problem with ntfs access on my iis server.....
All works fine now
Thanks for your help and sorry for that... :">
Powered by vBulletin® Version 4.1.5 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.