[opencms-dev] How to modifying HTML files
Claus Priisholm
cpr at codedroids.com
Sun Jul 31 07:37:40 CEST 2005
HTML files only end up in the "real" file system if they are marked for
static export (and OpenCms is set up to do static export - check the
...webapps/opencms/WEB-INF/config/opencms-importexport.xml file). Per
default exported files ends up in ..webapps/opencms/export
JSP files always get mirrored to the real file system since that is
where Tomcat (or other servlet containers) expects to find them.
Accordingly they get exported to specfic locations that Tomcat knows about.
Rederic Cedeno wrote:
> Hello guys actually I have explored already the OpenCms specifically
> using the HTML editor and one problem that i have encountered that there
> is no font-TAG in HTML codes sometimes if you want to set the font it is
> disabled.
>
> And by using OpenCms you cant find the HTML codes from the local drive.
> why the JSP could be created?
>
> and the documentations "on how to" is not totaly similar to the
> Interface or IDE in the OpenCms V5 Ex. by creating new project it has
> been documented... using "Administrator" but using OpenCms V6 its
> "Legacy Administrator".
>
> is there any documentations regarding where the files located or saying
> the file would not be created on the local drive only the JSP codes?
>
> */opencms-dev-request at opencms.org/* wrote:
>
> Send opencms-dev mailing list submissions to
> opencms-dev at opencms.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.opencms.org/mailman/listinfo/opencms-dev
> or, via email, send a message with subject or body 'help' to
> opencms-dev-request at opencms.org
>
> You can reach the person managing the list at
> opencms-dev-owner at opencms.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of opencms-dev digest..."
>
>
> Today's Topics:
>
> 1. Re: opencms-dev Digest, Vol 51, Issue 6 (lgauthier at opnworks.com)
> 2. Customise search ERROR [OpenCMS 6.0 ] (David)
> 3. Customise search ERROR [OpenCMS 6.0] (resend) (David)
> 4. Re: adding a font (Siegfried Puchbauer)
> 5. RE: adding a font (Jonathan Woods)
> 6. Re: Customise search ERROR [OpenCMS 6.0] (resend) (Andras Balogh)
> 7. Strange behaviour importing contents (Ramos)
> 8. Re: Customise search ERROR [OpenCMS 6.0] (resend) (David)
> 9. Re: Design for accessibility, HTML Strict and CSS
> (Sebastian Himberger)
> 10. Re: adding a font (Siegfried Puchbauer)
> 11. Re: Design for accessibility, HTML Strict and CSS
> (Alessandro Magnolo)
> 12. Re: Adding a link to a page (Alessandro Magnolo)
> 13. Re: image in opencms (Alessandro Magnolo)
> 14. Re: Adding a link to a page (Alessandro Magnolo)
> 15. Re: image in opencms (Alessandro Magnolo)
> 16. Problem creating objects (Andre Luciano Domingues)
> 17. RE: Customise search ERROR [OpenCMS 6.0] (resend)
> (Alexander Kandzior)
> 18. Re: Problem creating objects (Corsin Camichel)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: 29 Jul 2005 10:04:47 -0000
> From: lgauthier at opnworks.com
> Subject: [opencms-dev] Re: opencms-dev Digest, Vol 51, Issue 6
> To: opencms-dev at opencms.org
> Message-ID: <20050729100447.66500.qmail at london.clusterspan.net>
> Content-Type: text/plain; charset=utf-8
>
> Je suis absent jusqu'au 5 aout 2005. Pour toute urgence contacter:
> direction at opnworks.com
>
> Merci,
>
> Laurent Gauthier
>
> I am absent until August 5, 2005. For any emergency, contact
> management at opnworks.com.
>
> Thank you,
>
> Laurent Gauthier
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 29 Jul 2005 11:30:27 +0100
> From: David
> Subject: [opencms-dev] Customise search ERROR [OpenCMS 6.0 ]
> To: The OpenCms mailing list
> Message-ID:
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
> I am trying to customise the search behaviour in OpenCMS such that
> to allow
> an application to dynamically create a new index source and search
> index
> from an arbitrary set of files in VFS and perform a search on those
> files.
> The code that I am using is given below. When I run this from a JSP
> page it
> returned with an error saying *No analyzer found for language "null"*
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opencms.org/pipermail/opencms-dev/attachments/20050729/f4a0649e/attachment-0001.html
>
> ------------------------------
>
> Message: 3
> Date: Fri, 29 Jul 2005 11:43:50 +0100
> From: David
> Subject: [opencms-dev] Customise search ERROR [OpenCMS 6.0] (resend)
> To: The OpenCms mailing list
> Message-ID:
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
> I am trying to customise the search behaviour in OpenCMS such that
> to allow
> an application to dynamically create a new index source and search
> index
> from an arbitrary set of files in VFS and perform a search on those
> files.
> The code that I am using is given below. When I run this from a JSP
> page it
> returned with an error saying *No analyzer found for language
> "null". *The
> trace log for this error is given at the bottom which points to method
> getAnalyzer() in CmsSearchManager. So I checked the source code of this
> method and it looks perfectly normal given that I already set the
> locale for
> my CmsSearchIndex object to 'en'. I even test printing out the analyzer
> class name (see code) using getAnalyzers() method of the
> CmsSearchManager to
> make sure that analyzer for 'en' locale exists.
> So the analyzer is there and the locale has been set for the
> CmsSearchIndex
> object, why does it still complain about the analyzer being not
> found and
> weird enough in the error message it seems not able to detect the
> locale
> ("null" value)? Has anyone experienced this before and perhaps could
> provide
> some insights? Thanks very much for your prompt response.
> Rgds,
> David.
> // Define the document set from files
> ArrayList docPaths = new ArrayList();
> docPaths.add("/sites/mysite/file1.doc");
> docPaths.add("/sites/mysite/file2.pdf");
> docPaths.add("/sites/mysite/file3.txt");
> String query = "hello*";
> // Define index source
> CmsSearchIndexSource indexSource = new CmsSearchIndexSource();
> indexSource.setName("tempIndexSource");
> indexSource.setIndexerClassName("org.opencms.search.CmsVfsIndexer");
> indexSource.addDocumentType("xmlpage");
> indexSource.addDocumentType("xmlcontent");
> indexSource.addDocumentType("page");
> indexSource.addDocumentType("text");
> indexSource.addDocumentType("pdf");
> indexSource.addDocumentType("rtf");
> indexSource.addDocumentType("html");
> indexSource.addDocumentType("msword");
> indexSource.addDocumentType("msexcel");
> indexSource.addDocumentType("mspowerpoint");
> indexSource.addDocumentType("image");
> indexSource.addDocumentType("generic");
>
> // Add documents to index source
> for (Iterator pointerIt = docPaths.iterator(); pointerIt.hasNext();) {
> String pointer = (String) pointerIt.next();
> // create a document object from this pointer
> indexSource.addResourceName(pointer);
> }
>
> // Instantiate an index from the index source
> CmsSearchIndex index = new CmsSearchIndex();
> index.setName("tempIndex");
> index.addSourceName(indexSource.getName());
> index.setLocale("en");
> index.setRebuildMode(CmsSearchIndex.AUTO_REBUILD);
> index.initialize();
>
> // Test to make sure analyzer for locale 'en' exists
> CmsSearchManager searchMgr = OpenCms.getSearchManager();
> CmsSearchAnalyzer analyzer = (CmsSearchAnalyzer) searchMgr.getAnalyzers
> ().get("en");
> out.println("Analyzer for locale 'en' is "+analyzer.getClassName());
>
> // Update the index (build it)
> searchMgr.addAnalyzer(analyzer);
> searchMgr.addSearchIndexSource(indexSource);
> searchMgr.addSearchIndex(index);
> searchMgr.updateIndex(index.getName());
>
> // Code to search using this indexer...
>
> <<< ERROR TRACE MESSAGE >>>>
>
> org.opencms.search.CmsIndexException: No analyzer found for language
> "null".
> at
> org.opencms.search.CmsSearchManager.getAnalyzer(CmsSearchManager.java:692)
> at
> org.opencms.search.CmsSearchIndex.getIndexWriter(CmsSearchIndex.java:328)
> at
> org.opencms.search.CmsSearchManager.updateIndex(CmsSearchManager.java:600)
> at
> org.opencms.search.CmsSearchManager.updateIndex(CmsSearchManager.java:557)
> at
> org.opencms.search.CmsSearchManager.updateIndex(CmsSearchManager.java:544)
> at .....
>
> ...... (omitted)
>
> <<>>>
>
>
> --
> Rgds,
> David
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opencms.org/pipermail/opencms-dev/attachments/20050729/727fed65/attachment-0001.html
>
> ------------------------------
>
> Message: 4
> Date: Fri, 29 Jul 2005 12:44:49 +0200
> From: Siegfried Puchbauer
> Subject: Re: [opencms-dev] adding a font
> To: The OpenCms mailing list
> Message-ID: <53239a2005072903447977f1a at mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> hi!
>
> fckeditor would be very nice.... can you tell me, when you expect
> that your
> integration will be finished. i used fck in a project without opencms...
> its very stable (much more than htmlarea)
>
> btw. if you need some support in integrating it... i could help :)
>
> 2005/7/18, Sebastian Himberger :
> >
> > Hi,
> >
> > >However it's a little worrying that an important component of
> OpenCms
> > >has an uncertain future. What are the alternatives?
> >
> > we are currently working on a new editor integration (
> www.fckeditor.net
> > ). It's nearly finished and you can expect it to be Open Source when
> > it's ready. Some nice features of fckeditor are XHTML-syntax and
> > CSS-support.
> >
> > best regards
> > Sebastian
> >
> >
> > _______________________________________________
> > This mail is send to you from the opencms-dev mailing list
> > To change your list options, or to unsubscribe from the list,
> please visit
> > http://mail.opencms.org/mailman/listinfo/opencms-dev
> >
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opencms.org/pipermail/opencms-dev/attachments/20050729/7c62dee3/attachment-0001.html
>
> ------------------------------
>
> Message: 5
> Date: Fri, 29 Jul 2005 12:13:00 +0100
> From: "Jonathan Woods"
> Subject: RE: [opencms-dev] adding a font
> To: "'The OpenCms mailing list'"
> Message-ID:
> Content-Type: text/plain; charset="us-ascii"
>
> For your info, plenty of JSP integration work has already been done
> - see
> http://www.fckeditor.net/download/default.html or
> http://sourceforge.net/project/showfiles.php?group_id=75348
> 11.> &package_id=129511.
>
> Jon
>
> _____
>
> From: opencms-dev-bounces at opencms.org
> [mailto:opencms-dev-bounces at opencms.org] On Behalf Of Siegfried
> Puchbauer
> Sent: 29 July 2005 11:45
> To: The OpenCms mailing list
> Subject: Re: [opencms-dev] adding a font
>
>
> hi!
>
> fckeditor would be very nice.... can you tell me, when you expect
> that your
> integration will be finished. i used fck in a project without opencms...
> its very stable (much more than htmlarea)
>
> btw. if you need some support in integrating it... i could help :)
>
>
> 2005/7/18, Sebastian Himberger :
>
> Hi,
>
> >However it's a little worrying that an important component of OpenCms
> >has an uncertain future. What are the alternatives?
>
> we are currently working on a new editor integration ( www.fckeditor.net
> ). It's nearly finished and you can expect it to be Open Source when
> it's ready. Some nice features of fckeditor are XHTML-syntax and
> CSS-support.
>
> best regards
> Sebastian
>
>
> _______________________________________________
> This mail is send to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please
> visit
> http://mail.opencms.org/mailman/listinfo/opencms-dev
>
>
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opencms.org/pipermail/opencms-dev/attachments/20050729/df280c12/attachment.html
>
> ------------------------------
>
> Message: 6
> Date: Fri, 29 Jul 2005 14:25:37 +0300
> From: Andras Balogh
> Subject: Re: [opencms-dev] Customise search ERROR [OpenCMS 6.0]
> (resend)
> To: The OpenCms mailing list
> Message-ID: <42EA1231.1000105 at gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hello David,
>
> Have You considered using another approach? A solution would be to
> use a
> global search each time and filter out
> the results based on the list of files you have at runtime. It would
> require some work since the paging functionality will
> not work but i think it might work better than what you are trying to
> achieve now.
> I have never tested it but i have a feeling creating indexes "on the
> fly" for each site user search it will be an overkill.
>
> Best regards,
> Andras.
>
> David wrote:
>
> > Hi,
> >
> > I am trying to customise the search behaviour in OpenCMS such
> that to
> > allow an application to dynamically create a new index source and
> > search index from an arbitrary set of files in VFS and perform a
> > search on those files. The code that I am using is given below.
> When I
> > run this from a JSP page it returned with an error saying /No
> analyzer
> > found for language "null". /The trace log for this error is given at
> > the bottom which points to method getAnalyzer() in CmsSearchManager.
> > So I checked the source code of this method and it looks perfectly
> > normal given that I already set the locale for my CmsSearchIndex
> > object to 'en'. I even test printing out the analyzer class name
> (see
> > code) using getAnalyzers() method of the CmsSearchManager to make
> sure
> > that analyzer for 'en' locale exists.
> >
> > So the analyzer is there and the locale has been set for the
> > CmsSearchIndex object, why does it still complain about the analyzer
> > being not found and weird enough in the error message it seems not
> > able to detect the locale ("null" value)? Has anyone experienced
> this
> > before and perhaps could provide some insights? Thanks very much for
> > your prompt response.
> >
> > Rgds,
> > David.
> >
>
>
>
> ------------------------------
>
> Message: 7
> Date: Fri, 29 Jul 2005 13:35:08 +0200
> From: Ramos Sa?udo, Fidel
> Subject: [opencms-dev] Strange behaviour importing contents
> To: "OpenCms mailing list \(E-mail\)"
> Message-ID:
> <618FF4C21278E44BB35BD24B86C27796078514EF at CORREO.sadiel.es>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
>
> I'm experiencing an unexpected error when I try to import some
> contents in OpenCMS over Oracle 8.1. I found a solution, but still
> don't know why it happens.
>
> The background: I exported data from an Oracle DB to XML using BIE.
> Then imported the XML to OpenCMS using the XMLdb module. After that
> I manipulate the contents a bit, changing groups and some other
> things. Then I export several folders to ZIP. Everything goes fine.
>
> But, importing some ZIPs produce errors (I'm putting one at the end
> of the mail). After some research I discover that the troublesome
> contents are those with more than 450 characters in one of the
> fields of the original Oracle DB. This field is VARCHAR2(500), but
> the crazy thing is that the PROPERTY_VALUE field of CMS_PROPERTIES
> is also VARCHAR2(500), so why doesn't it fit? Why does a content
> with say 420 characters fit OK and with 450 or more doesn't?
>
> The solution (read hack) given is increasing the PROPERTY_VALUE
> field to 600 (to have a margin). After this every ZIP imports fine.
> Data is text, with Spanish accentuated letters and "ñ", but the
> content is declared as ISO-8859-1 and should be 1-char/1-byte,
> shouldn't it?
>
> Does someone have any idea about this? I've looked at the OpenCMS
> classes showed in the Exception trace, thinking that maybe OpenCMS
> added something to the data prior to importing or inserting at the
> DB, but I found nothing.
>
> Thanks to anyone who can shed some light on this mistery.
>
>
> The error is:
>
> Importando
> /Contenidos_Empleado/Contenido_General/Legislacion/2005/Abril/ContenidoGeneral_3427
> Excepcióncom.opencms.core.CmsException: 4 Sql exception. Detailed error:
> [com.opencms.file.oraclesql.CmsDbAccess] ORA-01401: inserted value
> too large
> for column
> .
> root cause was java.sql.SQLException: ORA-01401: inserted value too
> large for
> column
> at
> com.opencms.file.genericSql.CmsDbAccess.writeProperty(CmsDbAccess.java:12005)
> at
> com.opencms.file.genericSql.CmsDbAccess.writeProperties(CmsDbAccess.java:11937)
> at
> com.opencms.file.genericSql.CmsResourceBroker.writeResource(CmsResourceBroker.java:7641)
> at com.opencms.file.CmsObject.doWriteResource(CmsObject.java:1074)
> at
> com.opencms.file.A_CmsResourceType.importResource(A_CmsResourceType.java:616)
> at com.opencms.file.CmsObject.importResource(CmsObject.java:2142)
> at com.opencms.file.CmsImport.importResource(CmsImport.java:601)
> at com.opencms.file.CmsImport.importAllResources(CmsImport.java:786)
> at com.opencms.file.CmsImport.importResources(CmsImport.java:188)
> at
> com.opencms.file.genericSql.CmsResourceBroker.importResources(CmsResourceBroker.java:4162)
> at com.opencms.file.CmsObject.importResources(CmsObject.java:2169)
> at
> com.opencms.workplace.CmsAdminDatabaseImportThread.run(CmsAdminDatabaseImportThread.java:74)
> >-----------
> >Root cause:
> >java.sql.SQLException: ORA-01401: inserted value too large for column
> > at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
> > at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
> > at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:582)
> > at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1986)
> > at
> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1144)
> > at
> oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2152)
> > at
> oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:2035)
> > at
> oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2876)
> > at
> oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:609)
> > at
> org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:233)
> > at
> com.opencms.file.genericSql.CmsDbAccess.writeProperty(CmsDbAccess.java:12002)
> > at
> com.opencms.file.genericSql.CmsDbAccess.writeProperties(CmsDbAccess.java:11937)
> > at
> com.opencms.file.genericSql.CmsResourceBroker.writeResource(CmsResourceBroker.java:7641)
> > at com.opencms.file.CmsObject.doWriteResource(CmsObject.java:1074)
> > at
> com.opencms.file.A_CmsResourceType.importResource(A_CmsResourceType.java:616)
> > at com.opencms.file.CmsObject.importResource(CmsObject.java:2142)
> > at com.opencms.file.CmsImport.importResource(CmsImport.java:601)
> > at com.opencms.file.CmsImport.importAllResources(CmsImport.java:786)
> > at com.opencms.file.CmsImport.importResources(CmsImport.java:188)
> > at
> com.opencms.file.genericSql.CmsResourceBroker.importResources(CmsResourceBroker.java:4162)
> > at com.opencms.file.CmsObject.importResources(CmsObject.java:2169)
> > at
> com.opencms.workplace.CmsAdminDatabaseImportThread.run(CmsAdminDatabaseImportThread.java:74)
> java.sql.SQLException: ORA-01401: inserted value too large for column
> at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
> at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
> at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:582)
> at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1986)
> at
> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1144)
> at
> oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2152)
> at
> oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:2035)
> at
> oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2876)
> at
> oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:609)
> at
> org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:233)
> at
> com.opencms.file.genericSql.CmsDbAccess.writeProperty(CmsDbAccess.java:12002)
> at
> com.opencms.file.genericSql.CmsDbAccess.writeProperties(CmsDbAccess.java:11937)
> at
> com.opencms.file.genericSql.CmsResourceBroker.writeResource(CmsResourceBroker.java:7641)
> at com.opencms.file.CmsObject.doWriteResource(CmsObject.java:1074)
> at
> com.opencms.file.A_CmsResourceType.importResource(A_CmsResourceType.java:616)
> at com.opencms.file.CmsObject.importResource(CmsObject.java:2142)
> at com.opencms.file.CmsImport.importResource(CmsImport.java:601)
> at com.opencms.file.CmsImport.importAllResources(CmsImport.java:786)
> at com.opencms.file.CmsImport.importResources(CmsImport.java:188)
> at
> com.opencms.file.genericSql.CmsResourceBroker.importResources(CmsResourceBroker.java:4162)
> at com.opencms.file.CmsObject.importResources(CmsObject.java:2169)
> at
> com.opencms.workplace.CmsAdminDatabaseImportThread.run(CmsAdminDatabaseImportThread.java:74)
>
>
>
> Fidel Ramos
>
> ------------------------------
>
> Message: 8
> Date: Fri, 29 Jul 2005 12:41:54 +0100
> From: David
> Subject: Re: [opencms-dev] Customise search ERROR [OpenCMS 6.0]
> (resend)
> To: The OpenCms mailing list
> Message-ID:
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi Andras,
> Thank you for your suggestion which I think will work as an alternative.
> However I would still very interested in finding out why the other
> approach
> does not work. Knowing this will help better understand how the OpenCMS
> Search API works which will come in handy should we need to
> customise it in
> the future for other applications. This type of code is fairly
> straight-forward with the original Lucene API itself. Only because
> OpenCMS
> API hides this interface details from us.
>
> === message truncated ===
>
> ------------------------------------------------------------------------
> Start your day with Yahoo! - make it your home page
> <http://us.rd.yahoo.com/evt=34442/*http://www.yahoo.com/r/hs>
>
>
> ------------------------------------------------------------------------
>
>
>
> _______________________________________________
> This mail is send to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://mail.opencms.org/mailman/listinfo/opencms-dev
--
Claus Priisholm, CodeDroids ApS
cpr (you know what) codedroids.com - http://www.codedroids.com
Javadocs and other OpenCms stuff:
http://www.codedroids.com/community/opencms
More information about the opencms-dev
mailing list