Al Pascual



Geo RSS
Geo Twitter Timeline

Blogs I read

<January 2009>
SunMonTueWedThuFriSat
28293031123
45678910
11121314151617
18192021222324
25262728293031
1234567

GeoRSS Editor alpha version is up and running

GeoRSS is a great way to share geographic information that updates all the time, sending simple geography (points, lines and polygons to a consumer.

GeoRSS is RSS with a collection of points, as flexible as RSS with the advantage of providing location to your information. A great tool that I personally use in a regular basis in my professional and personal life. If I may I would recommend to extend GeoRSS to add attributes for viewers to display. I would like to suggest to add <georss:icon>, <georss:backcolor> and <georss:forecolor>

By adding those attributes, viewers would be able to render the geography in a richer manner as well will provide the user different points legends instead of waiting for the tooltip to know what this point represents. I would like also to even suggest to add labeling on the feature displayed <georss:label> so does not need to open the tool tip to see the title and description. I personally started using the <georss:title> as the label for the geometry.

Last night I spend a few hours creating the first version of the GeoRss editor for you to create your own GeoRSS and publish it immediately.

image

This time I used the ESRI JavaScript API to accomplish the task, as the API comes with objects that can be converted to Json format. Very useful to serialized. Using the esri.geometry object I add all objects into a JavaScript Array and then with a little help from the dojo library I convert it to Json to send to the server:

var JsonString = dojo.toJson(_geometryCollection); 

On the server side using the System.Web.Script.Serialization.JavaScriptSerializer I can create a collection of geometry to convert to GeoRSS.

public static object JSONDeserialize(string json)
    {
        JavaScriptSerializer ser = new JavaScriptSerializer();

        object obj = ser.DeserializeObject(json);

        return obj;
    }

I recommend extensive using of generics to get all the objects from Json.

string sJsonQuery = Request.Params["geometry"].ToString();

                object obj1 = JSONDeserialize(sJsonQuery);
                object[] Items = ((object[])(obj1));
                for (int i = 0; i < Items.Length; i++)
                {
                    System.Collections.Generic.Dictionary<string, object> PreValue = ((System.Collections.Generic.Dictionary<string, object>)(Items[i]));

image

This is just the first cut, a quick proof of concept for me to enjoy after all the kids are in bed and I feel like writing some code instead of watching the Democratic National Convention. There are many things to polish and fix.

· Send the Json containing the geometry to the server using AJAX instead of opening another window to fire the postback.

· Adding too many polygons will cause Json to be corrupted.

· Lines are not implemented yet, but I left the button there

· Allow to change the title and description on the geometry as well as the color and pattern.

· Store it forever into the database instead of using the cache object.

· Show other peoples GeoRSS

· Allow users to start with their GeoRSS to start editing.

To try it you can go here

As always, looking forward to your feedback and comments.

Cheers

Al

Posted from http://weblogs.asp.net/albertpascual

Comments

Mikel said:

The MediaRSS namespace is commonly used to specify an icon (media:icon), but not certain how often GeoRSS clients actually use that convention. Certainly GeoRSS.org should help out by suggesting some of these conventions and tracking usage, or allow people to contribute their usage. For styling GeoRSS generally, it's been discussed. Similarly to how GeoRSS compromises completeness for clarity, I'd suggest some kind of CSS-like model, rather than the heavy SLD specs. Really this needs a push, and I'd like to invite you to join and post on the GeoRSS discussion list, and kickstart this topic again. http://lists.eogeo.org/mailman/listinfo/georss -Mikel
# September 1, 2008 2:18 PM

albert said:

Mikel,

I would love to be part of that discussion, please email me at alpascual at gmail dot com

Cheers

Al

# September 1, 2008 3:44 PM

Recent Links Tagged With "add" - JabberTags said:

Pingback from  Recent Links Tagged With "add" - JabberTags

# September 21, 2008 5:49 PM

Bookmarks about Dictionary said:

Pingback from  Bookmarks about Dictionary

# November 6, 2008 5:30 PM