Mathias Lin | 林马

Healthcare Informatics, Open Source, Entrepreneur, Software Engineer (Java, Android, Mobile), HIMSS member 
Filed under

CMS

 

Open-Source clinic management software in Hong Kong #opensource #healthcare

[From: http://www.isia.org.hk/]
Aug 2009, After two years of development, the TaoYuan Project team formed by ISIA and HKMA are pleased to announce that CMS 3.0 is born! The CMS 3.0 is the first Open-Source clinic management software in Hong Kong. The latest version 3.1 is available now for all registered doctors and clinics to download together with online e-learning and user manual. ISIA members provide various customized CMS service packages bundling hardware, broadband, data migration, training & hotline support.
For details, _http://cms3.isia.org.hk
_

Loading mentions Retweet
Filed under  //   CMS   healthcare   hongkong   opencms   opensource  

Comments [0]

Display RSS Feed in OpenCms Template

Since this is a very common feature for many websites, here's a useful snippet I usually use when displaying RSS feeds in an OpenCms template. For example you want to display an Atom RSS feed from a WordPress blog on your OpenCms based website.

My approach is usually:
The OpenCms schema has a OpenCmsString input field (named BlogRssUrl in my case), which is mapped to the property BlogRssUrl as well.

<xsd:complexType name="OpenCmsMySchema">
  ...
  <xsd:element name="BlogRssUrl" type="OpenCmsString" minOccurs="0" maxOccurs="1" />
  ...
</xsd:complexType>

<mappings>
    <mapping element="BlogRssUrl" mapto="property:BlogRssUrl" />
</mappings>

For fetching the RSS feed, I recommend the ROME Fetcher subproject library at https://rome.dev.java.net/, which only depends on the JDOM parser (jdom.jar). So you will end up deploying three additional jars:

  • jdom.jar
  • rome-1.0RC2.jar (or newer version)
  • rome-fetcher-0.9.jar (or newer version)


Below is the scriplet then for the OpenCms jsp template:

<%@ taglib prefix="cms" uri="http://www.opencms.org/taglib/cms" %>
<%@ page session="false" import="org.opencms.jsp.*,java.util.*,org.opencms.file.*,java.net.URL,com.sun.syndication.feed.synd.*,com.sun.syndication.fetcher.*,com.sun.syndication.fetcher.impl.*" %>
<%  
    CmsJspActionElement cms = new CmsJspActionElement(pageContext, request, response);
    String filename = cms.getRequestContext().getUri();

           // === RSS Feed Fetching ===
    FeedFetcherCache feedInfoCache = HashMapFeedInfoCache.getInstance();
    FeedFetcher feedFetcher = new HttpURLFeedFetcher(feedInfoCache);
    CmsObject cmso = cms.getCmsObject();
    String blogRssUrl = cmso.readProperty(filename, "BlogRssUrl");
    SyndFeed feed = null;
    if (blogRssUrl!=null && !"".equals(blogRssUrl)) feed = feedFetcher.retrieveFeed(new URL(blogRssUrl));
%>

and then display the output on the page:

<% if (feed!=null) { %>
<ul>
<%
// === RSS feed output ===
for (Iterator<SyndEntry> iter= feed.getEntries().iterator(); iter.hasNext();) {
    SyndEntry entry = iter.next();
    %>               
    <li>[a href="<%=entry.getUri()%>"]<%=entry.getTitle()%>[/a]</li>                               
    <%               
}
%>
</ul>
<% } %>

Loading mentions Retweet
Filed under  //   atom   CMS   java   opencms   ROME   rss   tutorial  

Comments [0]

OpenCms Introduction Video

I recorded an OpenCms introduction video last weekend using Movie Maker and CamStudio (both free and easy-to-use tools), but still trying to improve the quality. 


This is my very first video recording and cutting, so please be considerate ;) 
Planning to add more videos step by step later. Hope to encourage others to do the same (on complementary topics).

Loading mentions Retweet
Filed under  //   CMS   opencms   opensource   tutorial  

Comments [0]