Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been working through a few tutorial/starter map samples on the OpenGeo and GeoExt websites and have come upon a problem I cannot solve. I'm trying to load a list of layers from my GeoServer into a GridPanel using No matter what I try, I cannot get anything to show in the GridPanel. I thought I had cross domain issues at first, but the problem persists even when the webpage and the GeoServer data are on the same server.

Here's a link to my very barren looking web map:

Here's the JavaScript that's supposed to access the wms and load the layer list:

    Ext.onReady(function() {
var grid = new Ext.grid.GridPanel({
    title: "Available WMS Layers",
    region: "north",
    height: 150,
    viewConfig: {forceFit: true},
    store: new{
        url: "",
        autoLoad: true
        columns: [
            {header: "Name", dataIndex: "name", sortable: true},
            {header: "Title", dataIndex: "title", sortable: true},
            {header: "Abstract", dataIndex: "abstract"}

Any help with this, or just ideas of where to look next would be greatly appreciated.

share|improve this question
I get a 404 not found from… – geographika Mar 18 '11 at 17:08
The full URL to the wms would be:… – Don Meltz Mar 18 '11 at 17:23… isn't returning a capabilities file - which is what your page is asking for. – iant Mar 18 '11 at 17:38
iant - see my comment above – Don Meltz Mar 18 '11 at 17:40
up vote 2 down vote accepted

Different port numbers are considered as different domains - even if the rest of the URL is the same. So if your main site is running on:

You would need a proxy to access:

So the proxy FAQ below applies in your case:

Why can't you run both your web application and Geoserver on the same port?


You can also get around the same domain policy using YQL -

share|improve this answer
I'm running GeoServer and IIS 7.5. Neither will let me set their port to the others port. – Don Meltz Mar 18 '11 at 18:45
@don You'll need a proxy, host the web site with GeoServer (on Apache), or you could try a URL rewrite approach -… – geographika Mar 18 '11 at 18:51
Thanks geographika - I'm struggling with understanding how proxies work and how to set them up, and with the URL rewrite option. I'm thinking it might be easier to just move everything on to Apache. – Don Meltz Mar 18 '11 at 22:50
Unless you are using .NET in your web application, moving to Apache would be easier. If you need a proxy have a look at - I think this should work with ports – geographika Mar 18 '11 at 23:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.