2008/05/27

FckGoogleMaps is dead. Long live FCKMaps

It might take still a while to have everything finished, but I've started to code the changes necessary to be able to use not only the Google Maps, but also the MS Virtual Earth is starting to work at the moment, and probably I will add also support for Yahoo Maps.

I'm a little disappointed, specially the quality of Yahoo maps outside USA seems quite poor, Virtual Earth also lacks somehow in the quality of the images, although the Bird's eye view is very good.

Anyway, I'll keep on coding at least the MS version and then I'll see the outcome and if I'm still willing to continue with the Yahoo maps.

2008/05/20

Next version of the GoogleMaps plugin

Lately I've worked to do some improvements in the Google Maps plugin, you can already check the current status in the live demo.

One of the new features is that now the map remembers the type of map that has been selected, and now it's possible to select also the Terrain view. I guess that this isn't anything special, some might even wonder why I didn't add it earlier, but there are so many things to do that I just can't afford them all.

A more interesting change (mainly due to the opportunities that it can offer) is the usage of the Static maps. When you add a map you'll no longer see the white area with the Google logo, instead it will show a preview of the map. I haven't added the markers of polyline to the static map, and that's because I'm not fully satisfied with the current status.

First, it isn't possible to select the type of map, so the user will think that I'm gonna generate a wrong map because they see the map view instead of satellite as they have selected.

And the second problem is that the generated images can't be any larger than 512x512, so if I try to request a preview for a map of 600x400 Google sends an error message. In the end I've checked the dimensions of the map and restricted them in the static preview to those 512x512, so the image will be shown distorted, but at least the user won't see a X.

If those problems are solved (I think that only Google can provide a fix, I don't foresee any workaround), I have some other nice ideas (mainly one: load just a image and then the rest of the JS API on demand), but I don't see any reason to start coding them if people will complain that they won't work correctly.

The last important change for the FCKeditor plugin (besides some bug fixes related to the comments in the markers) is an idea from Enrico Danilo Visciola, allowing to have 2 different API Keys, and even asking to the user in the moment what's the key that they want to use. Based on this change I think that it will be possible to include the plugin inside the Write Area extension and as long as the web where you are using it doesn't filter out javascript you'll be able to include GoogleMaps with a few clicks.

Of course, there are many other things waiting to be done, if you want to sponsor some development just contact me, or if you want to cooperate with some code I will be grateful for your contribution.

2008/05/18

WriteArea 0.7 and GeckoSpellChecker extension

Finally, now that the RC1 for Firefox 3 has been released I've uploaded a new version of WriteArea updated to the current nightly and have requested its approval so it's no longer necessary to be registered in order to install it.

With this release I've updated from the 2.5 series to the new FCKeditor 2.6, meaning that the dialogs are now inline, but when they are used inside chrome they show a Firefox 2 bug, meaning that the content isn't blocked while the dialog is active, but everything works fine in Firefox 3.

Now there's another incentive to install this version of the extension, and it's a plugin that I have mentioned previously: the GeckoSpellChecker that integrates the spelling into the normal context menu.

You can see how it's shown in this screenshot:
Spell suggestions for Youu

but I would really encourage you to install the WriteArea 0.7 and then check it live in the playground.

2008/05/16

ServerPreview plugin for FCKeditor 2.5+

Yes, a little too late, but better late than never.

Finally, here is the updated version of the ServerPreview plugin.

As mentioned in the original release, this is a very simple plugin, and the new version is even simpler. I've removed the need to add a new button and the plugin just replaces the original preview command, so the only thing that you need to make it work is:

  1. Extract the plugin to your plugins folder
  2. Like the rest of plugins, add it to your instance: FCKConfig.Plugins.Add( 'serverPreview' ) ;
  3. Set the url of the page that will receive the data: FCKConfig.ServerPreviewPath

Then you just put all the server code that you want in that page, and read the data that is sent in the 'htmlData' field. You can change the plugin to add more fields if you need to. It could be possible to write a generic code to send all the current fields to the server, but I've never found enough time to write it (it just took me 6 months to write this post)

You can see a demo at the Google maps demo (due to the use of document.write the normal preview fails, so this plugin is really useful for that situation)

I haven't write a specific demo page for this plugin or other detailed installation instructions, so just go to SourceForge and get it.