Recent Submissions

Alphabetical listing of images in a folder, using folder path

This is an alternative to the old, deprecated "#photoGallery" macro

Select Field for Frontend REST Forms

The following snippet allows you to add a Select field to a Frontend Form that works with Content REST API. 

  • There are...

WYSIWYG Field for Frontend REST Forms

The following snippet allows you to add a WYSIWYG field to a Frontend Form that works with Content REST API. 

  • The $!{wysiwygField}...

dotCMS-inspector version 2.x

This is a simple tool to gather information about a running dotcms instance. This only works with dotcms 2.x releases

Usage: Must be run as root...

dotCMS-Inspector version 3.x

This is a simple tool to gather information about a running dotcms instance. This only works with dotcms 3.0 plus.

Usage: Must be run as root...

Ace Editor Custom Field

The Ace text editor is an online code editor written in JavaScript. It matches the features and performance of native editors.

This code example...

Bash Installation Script for dotCMS

This bash script will automatically download and install dotCMS. It was made to work, and tested on CentOS 7. This is not intended to be used on production...

TinyMCE for 2.5.7 and 3.X

This is the plugin for a 2.5.7 or 3.x instance to extended the WYSIWYG.

Multi-lingual Navigation

Here is an example of how to do multi-lingual navigation using the navtool. You need to have your language keys set up and then make each page title...

Check if key/value field has content

This should be thought of as the equivalent of $UtilMethods.isSet. Unfortunately, that method always returns true for key/value pairs. So we need to...

Combine multiple structure sources into the same content pull

We have multiple news outlets on campus that ended up being created in different structures. When we wanted to syndicate these news sources onto one...

Pull a dropdown list (select) of other content into a custom field

Use this code in a custom field, to pull a list of other content into a select field. This code uses the jQuery Javascript library in a way that shouldn't...

How to Display Content Type's Fields

On this example we will show how to use Velocity to display the values for each type of field on a content type.

We created a new structure and...

Set Language by Site or Folder

dotCMS supports a robust set of multi-lingual features that can be used anywhere on sites served by dotcms by passing a url parameter -

com.dotmarketing...

One liner for generating OSGi fragment export

When developing an OSGI plugin, you often (always) need to generate an OSGi "fragment" which takes the place of manually having to change the osgi-exports...

Show different WYSIWYG options based on Role

It is easy to show different WYSIWYG options based on a users role.  All you need to do is to write a plugin that overrides the file:

/dotCMS/html/portlet/ext/contentlet/field/tiny...

Internationalized URL Title code

The default url-title.vtl is ASCII-only:  any characters that are not letters of the English alphabet (or a digit or a hyphen) are discarded. ...

Upgrade to the latest Tomcat 6

The Dotcms 2.x distro is running a bit behind the latest apache tomcat 6 version and while Dotcms does not think that will cause any specific problem...

Log Configuration Portlet

The Logging Portlet allows a CMS Administrator in dotCMS to dynamically set logging levels of classes and packages at runtime that are known to the ...