[Zope] ExternalEditor, IE and https

Oliver Bleutgen myzope@gmx.net
Fri, 10 Jan 2003 15:05:58 +0100


Paul Browning wrote:
> 
> Hi. Just to report that I've had a number of people
> confirm the problem - over https IE fails to
> work with ExternalEditor (tested on IE V4, 5 and 6
> so the problem has been there a long time which
> makes me think that the problem lies with IE and
> may not be easily worked around).
> 
> A fix may not be possible but I am interested in
> a workaround. Here's why:
> 
> We are gradually rolling out Zope to a growing number
> of users who have unpredictable desktops. We only
> allow connections over https to the ZMI. The problem
> is a support issue - if an IE user sees the ExternalEditor
> pencil icon then they might reasonably expect to click
> it and have it work.
> 
> Might it be possible to introduce to ExternalEditor
> some sort of browser and/or protocol detection so that only
> non-IE users see the pencil icon?
> 
> Even better, might there be a way of implementing an
> ExternalEditor permission on a per folder or per user
> basis?
> 
> If either/both is technically possible please let me
> know - I _might_ be able to find modest funding for
> such a development.

 From a quick look at the source, ExternalEditor overrides just the 
manage_main method of objectManager to provide this link, with the 
following line of ExternalEditor/manage_main.dtml (and one also has to 
take a look at findResults.dtml in the same folder).

   <dtml-var expr="externalEditLink_(this())">

Where actually this method gets called (from ExternalEdit.py):


def EditLink(self, object):
     """Insert the external editor link to an object if appropriate"""
     base = Acquisition.aq_base(object)
     user = getSecurityManager().getUser()
     editable = (hasattr(base, 'manage_FTPget')
                 or hasattr(base, 'EditableBody')
                 or hasattr(base, 'document_src')
                 or hasattr(base, 'read'))
     if editable and user.has_permission(ExternalEditorPermission, object):
         return ('<a href="%s/externalEdit_/%s" '
                 'title="Edit using external editor">'
                 '<img src="%s/misc_/ExternalEditor/edit_icon" '
                 'align="middle" hspace="2" border="0" alt="External 
Editor" />'
                 '</a>' % (object.aq_parent.absolute_url(),
                           urllib.quote(object.getId()),
                           object.REQUEST.BASEPATH1)
                )
     else:

So it should be no problem to insert any test you like there.

Do I get funding now? ;>>>

cheers,
oliver