Widget Editing

From Hexten

Jump to: navigation, search

As Bez points out the Google Maps Widget could use a better editing UI.

I can certainly see how to make it easier to add a marker to the map. You'd have a dock full of different marker types and be able to drag them onto - and around - the map. There could be a pop up edit box associated with the currently selected marker for you to type the marker text into.

The problem is how to integrate that into MediaWiki's editing conventions. I don't want to hide the widget's markup somewhere outside the page markup and I don't want to lose the ability to edit the whole page - including widgets - in an external editor.

My current thinking is that in the same way MediWiki places edit links above each section we could have an edit link above each widget that opens it in GUI editing mode. Then you'd do all your dragging and dropping and it'd update the markup in an invisible iframe (or similar). You'd still be able to edit the widget markup directly by opening the whole page in edit mode.

Would that be intuitive? I'm slightly uneasy about having two different editing modes.

--AndyArmstrong 12:19, 14 May 2007 (BST)

I'm absolutely unfamiliar with Wiki editing in general (as may become patently obvious if I louse up this simple post in a minute) but there must be some PHP page which accepts the edited content via an HTTP-post. Surely all you'd need to do would be to add some script to the marker widget to scrape the existing content (if it's not readily accessible from the unedited page, you could request the 'edit' page via script and extract the contents of the text boxes) and then post it back up with the marker markup injected at the correct location.

So,

  • drag marker glyph onto map
  • edit box pops up, user adds fields (would be nice if there were basic/advanced tabs so this could be done without knowing Wiki formatting details)
  • on clicking 'ok,' the script does the get-modify-post editing behind the scenes (ie Ajax-styley, no need for the browser to be redirected)

(multiple edits later) I am clearly going to have to read something about editing this damn stuff :)

Yes, kinda. But really that kind of mechanism has to play nicely with just being able to edit the page - including the widget - in 'text' mode. So yes to piling a GUI on top - but no to anything that breaks normal wiki editing semantics. --AndyArmstrong 13:44, 14 May 2007 (BST)
Wouldn't it just work in parallel? 'Power users' could hit the normal 'edit' button and numpties like me could do the draggy-droppy-dialoggy thang. --Bez 16:48, 14 May 2007 (BST)
Oh sure - it's just a question of working out how to integrate that into MediaWiki using the interfaces that are available and in such a way that no wikiness is lost. As usual just talking about it has crystalised loads of ideas - for which thanks :) --AndyArmstrong 17:03, 14 May 2007 (BST)

[edit] Look and Feel

And can I bring up the point about the "?" button here? Can you use "Add..."? - or an icon of a marker with a shiny star 'new' glyph on it? Or something? "?" looks like "help" at best and "some random unknown action" at worst :)

Yeah, rubbish innit. I cropped one pixel too many from its shadow too. To the extent that people are able to use it I suspect it's because they go "WTF do I do here? I know - I'll click on the help button to find out" - then they click on the ? and, er, that's it --AndyArmstrong 13:44, 14 May 2007 (BST)

[edit] Map settings

Hi Andy. Got the wiki widgets working but I was wondering if there was anyway to force the googlemap to be shown with the satellite image rather than the map upon accessing the page with the map on? Tom 14:29, 25 June 2007 (BST)

I reckon I could add that pretty easily. Bit of catching up to do before I get to it though :) --AndyArmstrong 15:39, 25 June 2007 (BST)
I can imagine. I'm having a look at that other google map extension too. Wanting to be able to put .kmz/.kml route files on too but not got far looking into that yet.
The Google Maps Extension does allow routes to be put on the map. Haven't delved in to find out if it will use a file to create it or not yet. Found an italian site using it for the same purpose. xcrides italy

[edit] Installation

two questions

1.) I wonder whether I have to add or to replace the api-settings within the init.php. The installation-guide says edit which is not too precise.

It's not precise because you can do either :) You should be able either to leave the default settings there and add your own - or completely replace them.

2.) My special problem is:

Your key is:
ABQIAAAARB...
This key is good for all URLs in this directory:
http://localhost:8080/mediawiki/
  • I tried several configurations within init.php like
    'http://localhost:8080/mediawiki'           => array(
//  'localhost:8080/mediawiki'           => array(
//  'localhost/mediawiki'           => array(
//  'mediawiki'           => array(     //
//  'http://localhost:8080/mediawiki/'           => array(
//  'localhost:8080/mediawiki/'           => array(
//  'localhost/mediawiki/'           => array(
//  'mediawiki/'           => array(

Nothing works?


Any Ideas?

I suspect it's not handling the port number properly. I'll investigate. Thanks for pointing it out.
Personal tools
Mongers