PDA

View Full Version : How do I set paths to images, css and data



sydnic
1 Apr 2010, 7:28 AM
I am working on a project that has the following URLs

Data = http://192.168.0.25:14000/Dev/ProgramName
CSS = http://192.168.0.25:14000/Styles/index.css
Images = http://192.168.0.25:14000/Images/imageName

When setting up forms in the designer, I can't load data stores, I can't get classes to work, nor can I load any images (eg. company logo) into any Ext Component.

Any help would be greatly appreciated.

Many Thanks
Syd Nicholson

aconran
1 Apr 2010, 11:42 AM
Syd,

To load data into the designer from an external resource, you should do the following. Change the URL Prefix in Edit -> Preferences. This will allow you to use relative URLs within your url configuration when setting up your stores.

We could make it so that any configuration within the component config named "url" used the Url Prefix. This would allow us to load images for an image component very easily.

There is currently no way to load in external css into the designer. See this thread for more details.
http://www.extjs.com/forum/showthread.php?t=95170

sydnic
2 Apr 2010, 1:56 AM
Thanks Aaron,

However these settings don't work.

I have set the URL prefix to http://1923.168.0.25:14000/

In the store I have configured

root:'rows'
totalProperty:'totalrows'
url:'ifUsrJ?opt=1'

In a browser window the URL http://192.3168.0.25:14000/ifUsrJ?opt=1 returns JSON in the format

{totalrows:88,success:true,rows:[
{"ULUSERID":"*PUBLIC",
"ULDESC":"Public access - all users",
"ULSECOFR":"0",
"ULGROUP":""},
{"ULUSERID":"ADMIN",
"ULDESC":"Dr. Syd Nicholson",
"ULSECOFR":"1",
"ULGROUP":"QSECOFR"}
.........
]}

This data loads OK into a ExtJS store if it is run in a browser, but in the designer I get the message "Unable to load data using the supplied configuration"

The message is returned immediately. The designer does not connect to the web-service. There is no transaction recorded by the server.

Am I missing something? What is wrong?

sydnic
2 Apr 2010, 1:58 AM
Sorry - in previous reply there are mistakes in the URLs. These are typing errors.

The IP address should read 192.168.0.25

aconran
2 Apr 2010, 10:57 AM
Everything above looks good.

We are working on making the Store loading process a lot easier. For example if you could see if a request was made, to what url and what the response was. This process of debugging what's wrong with the configuration would be simplified.

killfill
3 Apr 2010, 11:29 AM
It would be greate feature, to make the store configure itself via 'metaData' too...

Thanks!

sydnic
3 Apr 2010, 3:00 PM
I have recently aquired a valid license for the Designer, and now the Stores are working.

Perhaps there is a "feature" in the designer that requires a license before the stores will work.

Regards
Syd Nicholson

aconran
3 Apr 2010, 5:42 PM
Perhaps there is a "feature" in the designer that requires a license before the stores will work.


No, the designer in its trial state is exactly the same as the designer in its fully activated license state.

pete.krull
27 May 2010, 7:33 PM
I'm using Ext Designer, xds-1.0.1.0c on a Mac w/ Snow Leopard and running into the same problem. When I attempt to load a store from my local site, I immediately get an error saying "Unable to load data using the supplied configuration" yet the same store works when it's deployed. In addition, when using Designer, I see no attempt to connect to my server in the server logs. I also tried using http://www.extjs.com/forum/topics-remote.php for the store url and immediately get the same error though I can see the returned data when using this url in Firefox. Is there a configuration setting somewhere that I need to change? My apologies if I've posted to the wrong thread.
Thanks,
Pete Krull

jarrednicholls
27 May 2010, 11:38 PM
Hi Pete,

Would you be able to attach your .xds file for a quick scan? You can email it to me if you don't want to post on the forums: jarred at extjs.com

We're going to build an auto-store configuration feature, so stores will try to be intelligent and automatically configure themselves based on returned data. That'll definitely be a big help, no doubt.

pete.krull
30 May 2010, 5:25 PM
Jarred,
Thanks for the response. After further experimentation, I found that the store would load correctly if I put the entire url in the url attribute. If I used a relative url and defined a prefix in the Designer preferences, it wouldn't work. The strange thing is that the error dialog would show the correct url and when I clicked on the link, valid data would be returned. I tried a few variations when defining the prefix but none of them worked.
Pete