Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
embedded html in TinyMCE with Livesite
ijh
Hi
We are using a standard content component with tinymce
Within tinymce we want to embed HTML like follows:
include virtual="/shared/includes/news/latest_news.html"
NOTE:
I have the standard Less then sign and ! and the two dashed around the above include statement. It just doesn't allow it in the editor here.
This saves fine but when we preview or look at the page using
livesite runtime it does not render the include
ie: The #include is not processed
Any ideas?
Find more posts tagged with
Comments
vpatel
I do not believe the way you are doing your SSIs are supported with SP / LS. You include it via file include if you are using LS Runtime. If you are generating static HTMLs then SSIs may work.
Migrateduser
FYI...we had to end up writing a java class in order to preview the include. Example:
package com.hcsc.livesite.external;
import org.dom4j.Document;
import org.dom4j.Element;
import com.interwoven.livesite.dom4j.Dom4jUtils;
import com.interwoven.livesite.file.FileDal;
import com.interwoven.livesite.runtime.RequestContext;
public class Include {
public Document getInclude(RequestContext context) {
Document doc = Dom4jUtils.newDocument();
String content = "";
Element incl = doc.addElement("include");
String include_file = context.getParameterString("Include");
if (context.isPreview()) {
try {
FileDal filehandler = context.getFileDal();
content = filehandler.read(filehandler.getRoot() + "/" + include_file);
} catch (Exception e) {
content = "No File Loaded";
}
} else {
content = "";
}
incl.addCDATA(content);
return doc;
}