<FONT face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size=2><DIV>Hi all,</DIV><DIV> </DIV><DIV>I did not use OpenCms for 2 years and I think I forgot sthg...</DIV><DIV>In a context where I have multiple site,</DIV><DIV> </DIV><DIV>I would like to use the Direct Edit feature on a page (xmlpage) called index.html </DIV><DIV> </DIV><DIV>I coded a micro-template just to test and unfortunatly, even if I am logged / offline and in the right siteRoot ... I never get the Direct Edit button.</DIV><DIV> </DIV><DIV>Is somebody can help me ? </DIV><DIV> </DIV><DIV> </DIV><DIV>here is the code of the template (.. basic ..) </DIV><DIV> </DIV><DIV> </DIV><P><%@ page import="java.util.*,org.opencms.file.*,org.opencms.jsp.*" buffer="none" session="false"%><BR><%<BR> // create a JSP action element<BR> CmsJspActionElement cms = new CmsJspActionElement(pageContext, request, response);</P><P> // get own uri<BR> String uri = cms.getRequestContext().getUri();<BR>%><BR><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "<A href="http://www.w3.org/TR/html4/strict.dtd" target=blank>http://www.w3.org/TR/html4/strict.dtd</A>"><BR><html><BR><head><BR><title>Demo page with 1 element</title><BR></head><BR><body><BR><h2>Demo</h2><BR><p><!-- Editable body <BR>element --> <%</P><P> CmsObject cmsObject = cms.getCmsObject();<BR> cmsObject.loginUser("Admin", "admin");<BR> CmsProject cmsproject = cmsObject.readProject("Offline");<BR> cmsObject.getRequestContext().setCurrentProject(cmsproject);<BR> cmsObject.getRequestContext().setSiteRoot("/sites/default/");<BR> // include editable element from the URI<BR> cms.include(uri, "body", true);</P><P><BR>%> <!-- /Editable body element --></p><BR></body><BR></html></P><DIV> </DIV><DIV> </DIV><DIV><BR><DIV>Olivier <BR></DIV></DIV></FONT><font face="sans-serif"><html>
<head>
<meta http-equiv="content-type">
</head>
<body>
<font size="1" face="Default Sans Serif">
Ce message est à l'attention exclusive des destinataires désignés. Il peut contenir des informations confidentielles. Si vous n'êtes pas destinataire du message, merci d'en avertir immédiatement l'expéditeur et de détruire ce message. Le contenu de ce message ne pourrait engager la responsabilité de Steria que s'il a été émis par une personne dûment habilitée agissant dans le strict cadre de ses fonctions et à des fins non étrangères à ses attributions. Bien que les meilleurs efforts soient faits pour maintenir cette transmission exempte de tout virus, l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne saurait être engagée pour tout dommage résultant d'un virus transmis.
<br />
This message is intended exclusively for the designated addressee. It may contain confidential material. If you are not the correct addressee, please notify the sender immediately and destroy the message. The content of this message will engage the responsibility of Steria only if it has been sent by an authorized person acting in the strict scope of his functions and for purposes that are related to his competence. Although reasonable efforts have been made to keep this transmission free from viruses, the sender will not be liable for damages caused by a transmitted virus.
</font>
</body>
</html></font>