357 Lotus blogs updated hourly. Who will post next? Home | Downloads | Events | Pods | Blogs | Search | myPL | About 
 
Latest 7 Posts
SoftLayer + IBM: One Year Update
Wed, Jul 2nd 2014 247
Streaming files to IE8? You may want this.
Fri, Jun 20th 2014 206
Let me tell you some things about the Irish...
Thu, Jun 12th 2014 215
A Few Pics from Ireland
Wed, Jun 11th 2014 144
Our Grand Ireland Itinerary: Nights 8-11
Tue, Jun 10th 2014 117
Our Grand Ireland Itinerary: Nights 12-14
Tue, Jun 10th 2014 137
Our Grand Ireland Itinerary
Mon, Jun 9th 2014 141
Top 10
Lotusphere: It just gets curiouser and curiouser - The Bad
Mon, Feb 3rd 2014 527
Lotusphere: It just gets curiouser and curiouser - The Good
Mon, Feb 3rd 2014 515
Using CKEditor 4: Part1 - Preface + Setup
Mon, Mar 10th 2014 438
Using CKEditor 4: Part 5 - iPad Demonstration
Thu, Mar 13th 2014 424
Using CKEditor 4: Part 4 - Designing for Read/Edit Modes and Using Validation
Wed, Mar 12th 2014 423
Using CKEditor 4: Part 6 - Caveats: Jumping Editors, More on Validation, Going iPad "Only," and 32K Limits
Fri, Mar 14th 2014 423
Add Custom HTML Templates to Your CKEditor
Wed, Oct 16th 2013 394
Setting Up The IBM HTTP Server with Domino 9
Wed, May 29th 2013 370
Yes! I am at Connect 2014 in Orlando!
Sat, Jan 25th 2014 364
More security. That's what I'M talkin' about!
Mon, Mar 31st 2014 325


Be careful with empty CKEditor rich text fields
   


The CKEditor is very handy in XPages since it saves the content as MIME which can be processed as such in other places in your application. However you should be aware of how it operates so you can code around its behavior.

In 8.5.3 the CKEditor for rich text controls has been updated.

1. If you never enter any information into the field, then the field is a text field even if the document has been saved.

2. If you enter a single space and save the document, then the field is a MIME object and remains so even if you remove the content and re-save the document.

SOLUTION:

Use something similar to the code below to discover if the field is actually MIME or just plain empty text:


if(doc.getFirstItem("aRichTextField").getType()==Item.MIME_PART){
x=doc.getMIMEEntity("aRichTextField").getContentAsText();
}else{
x="";
}


NOTE: I have already upgraded everything to 8.5.3 so I cannot accurately verify but I believe this was not the case in 8.5.2 because after upgrading some existing/working suddenly stopped working and this was the cause.

If anyone knows differently about 8.5.2, please let me know.

---------------------
http://xpagetips.blogspot.com/2011/10/be-careful-with-empty-ckeditor-rich.html
Oct 28, 2011
86 hits



Recent Blog Posts
247


SoftLayer + IBM: One Year Update
Wed, Jul 2nd 2014 3:11p   Russell Maher
About a year ago I posted a couple of times regarding IBM's acquisition of SoftLayer. Received email this morning heralding the one year anniversary of the acquisition and I thought I would take a few moments to give my take as a SoftLayer customer. I was very concerned a year ago when I heard the SoftLayer announcement because, while I sincerely believe the financials of IBM's acquisition of Lotus Software back in 1995 are right in line with IBM's business track record (which is to say the [read] Keywords: ibm lotus application email
206


Streaming files to IE8? You may want this.
Fri, Jun 20th 2014 9:11a   Russell Maher
An easy XPages tip for a lazy Friday... Got SSL? Streaming files using an XAgent? You're gonna' get an error unless you do something like this: if(context.getUserAgent().isIE(8, 8)==false){ response.setHeader("Cache-Control", "no-cache"); } Apparently IE8 don't like no caching when streaming files over SSL. [read] Keywords: xpages
215


Let me tell you some things about the Irish...
Thu, Jun 12th 2014 6:12a   Russell Maher
To tie off my Ireland Itinerary series of posts I wanted to close with some thoughts on the Irish people and country. I have a curiosity about people that I do not often have the chance to indulge generally because I am too busy and many people find my inquisitive intensity to be unnerving but when I have the chance, the time and the opportunity I really try to learn as much about others as possible and am often rewarded with some valuable perspectives. What I found in Ireland is that the peop [read] Keywords:
144


A Few Pics from Ireland
Wed, Jun 11th 2014 6:12a   Russell Maher
Some of my favorite pics from our Ireland trip... They run anybody during elections! At Newgrange Giant's Causeway Sheeps At Harvey's Point they added this small fireplace room in 2004. It is so awesome! Kylemore Abbey Cows on the road Cows in a field. Banded Galloways Dinner at Hayfield Manor Where the Mahers are from Rock of Cashel Actually drank some whiskey...well Ginger Ale with some whiskey This is really good! Too much to drink? Fishing pole and an an MG [read] Keywords: application blogger google
117


Our Grand Ireland Itinerary: Nights 8-11
Tue, Jun 10th 2014 2:15p   Russell Maher
This is the second part in a series of posts about our trip to Ireland. Day 1 Itinerary Day 3 Itinerary Nights 8-11 Our first seven nights took us from Dublin to Trim to Northern Ireland to Donegal and then toward Galway. Nights 8-11 took us to the Dingle Peninsula, through part of the Ring of Kerry then over to Cork. Dingle The Dingle Peninsula is stunning. The road out on the peninsula offers some of the most stunning coastline you'll ever encounter. Really something to see. Sadly [read] Keywords:
137


Our Grand Ireland Itinerary: Nights 12-14
Tue, Jun 10th 2014 2:15p   Russell Maher
This is the third post in a series of posts about our Ireland itinerary. Day 1 Itinerary Day 2 Itinerary Nights 12-14 Our last drive took us from Cork, where we stayed at the lovely Hayfield Manor, to Dublin via Blarney Castle, where we both kissed the Blarney Stone, to Tipperary (the ancestral location ft the Mahers), to the Rock of Cashel, the lovely town of Kilkenny and then to Dublin where we dropped off the rental car after checking in to fabulous Westbury Hotel. Blarney Castle [read] Keywords: wiki
141


Our Grand Ireland Itinerary
Mon, Jun 9th 2014 9:10p   Russell Maher
Now I've been to Ireland. Karen and I spent two weeks there and got back last Saturday. Karen's travels plus my travels plus our travels adds up to a fairly impressive list of places (for Americans anyway) but, shockingly, neither of us had ever been to Ireland and so, for the first time, we travelled to a place where neither of us had ever been before. By the end of the trip, it is fair to say that, although we plan on returning to Ireland in the future, if we never make it back, we've gi [read] Keywords: wiki




325


More security. That's what I'M talkin' about!
Mon, Mar 31st 2014 11:11p   Russell Maher
Just deployed a Citrix Netscaler Platinum into our SoftLayer infrastructure. While we are quite confident in Domino and XPages security, a recent application vulnerability scan highlighted a couple of areas where Domino comes up a little short. For example, not being able to set the SessionID cookie as Secure (SSL only) could be a bit of an issue under the right circumstances. I have been evaluating the Netscaler for a few weeks and pretty much it's a web application administrator control fr [read] Keywords: domino xpages application citrix network security
423


Using CKEditor 4: Part 6 - Caveats: Jumping Editors, More on Validation, Going iPad "Only," and 32K Limits
Fri, Mar 14th 2014 6:14a   Russell Maher
This is Part 6 (final part) of a series of videos that illustrate our solution to implementing CKEditor 4 in our XPages application. You can find links to all of the videos in Part 1. In the last video I showed how this technique looks on an actual iPad..In this video I discuss some things to be aware of when working with the CKEditor, either CKEditor 4 or the currently installed XPages version (3.6.6.2). CKEditors jump! Validation usually in play in XPage apps will probably require a more e [read] Keywords: script library xpages application blogger google
160


Some Cultural Thoughts II (3 movies)
Thu, Mar 13th 2014 11:13p   Russell Maher
As I wrote in an earlier post, we've been viewing our way through the Oscar-nominated movies and we've just completed three more this week. Captain Phillips Fantastic movie! Watch it. Interesting fact...my oldest daughter was dating a fellow at the time who was serving on one of the U.S. Navy ships involved in the rescue. Gripping story plus Tom Hanks plus perfect movie-long crescendo of tension that ends in a rather incredible way even when you know how the story ends. Gravity Techni [read] Keywords:




Created and Maintained by Yancy Lent - About - Blog Submission - Suggestions - Change Log - Blog Widget - Advertising - Mobile Edition