Hi,
This looks like a bug. You should be able to load CSS from an external URL in the same way as you do scripts. I have created a Trouble ticket for this request. For now, please use the workaround which is to copy the CSS files to the Mashlet directory.
thanks,
Kishore
Thanks Kishore.
Can you also help me with what I should put for the property tag when including ext plugins? From what I understand this is supposed to be the last function in the file so presto knows when the file is done loading.
"resources" : {
"libs" : {
"presto_ext" : false
},
"js" : [
{"script":"http://www.url.com/ext-3.0.0/adapter/ext/ext-base-debug.js"},
{"script":"http://www.url.com/ext-3.0.0/adapter/ext/ext-all-debug.js"},
{"script":"Ext.ux.grid.Search.js", "property":"????"},
{"script":"main.js", "property":"myMashlet"},
],
"css" : ["http://www.url.com/ext-3.0.0/resources/css/ext-all.css"]
}
The grid search code can be seen here: http://extjs.com/forum/showthread.php?t=70558
Also do you see any issues with going to ext 3.0 in this way?
Typically, the answer is either the last global function (unlikely in Ext) or the last class constructor in the file. Or it could be a class constructor that you know your code is dependent on. I don't have any direct experience, so I'm not sure if that answer helps or not.
Sara, technical writer/jackbe
Here is a mashlet snippet code that loads Ext3.0 from the CDN: CacheFly, its pretty fast and reliable.
(The only drawback is that as Kishore mentioned, the css property has a bug and though you can not load the ext-all.css from the url: http://extjs.cachefly.net/ext-3.0.0/resources/css/ext-all.css, so you need to visit this link, get the code and save it on your local folder)
"Ext3": {
"type": "Ext3",
"version": "1.0",
"properties": {},
"hideTitlebar": true,
"resources": {
"css": ["ext-all.css"],
"js": [
{"script": "http://extjs.cachefly.net/ext-3.0.0/adapter/ext/ext-base.js","property":"Ext"},
{"script": "http://extjs.cachefly.net/ext-3.0.0/ext-all.js","property":"Ext"},
{"script": "Ext3.js", "property":"Ext3"}
]
}
},






Greetings,
We want to upgrade our mashlets to use extjs 3.0 instead of the bundled 2.1 In order to do this I set my mashlet to presto_ext: false in mashlet.json. Then in the js and css sections I am including the paths to the ext-base, ext-all, and ext-all.css files. The JS files load perfectly, however the css file will not load. Here is my code.
"resources" : {
"libs" : {
"presto_ext" : false
},
"js" : [
{"script":"http://www.url.com/ext-3.0.0/adapter/ext/ext-base-debug.js"},
{"script":"http://www.url.com/ext-3.0.0/adapter/ext/ext-all-debug.js"},
{"script":"main.js", "property":"myMashlet"},
],
"css" : ["http://www.url.com/ext-3.0.0/resources/css/ext-all.css"]
}
If I move the ext-all.css into my mashlet folder it will load, but I don't want a separate local copy because then I have to change all the image paths. You can set an absolute path for the js files, can you not do this for the css files?