JsTemplate/Link.js
authorAlan Knowles <alan@akbkhome.com>
Fri, 16 Jul 2010 07:06:06 +0000 (15:06 +0800)
committerAlan Knowles <alan@akbkhome.com>
Fri, 16 Jul 2010 07:06:06 +0000 (15:06 +0800)
JsTemplate/Link.js

index 87f3cf6..5be54d1 100644 (file)
@@ -204,7 +204,18 @@ Link = XObject.define(
 
             if (!this.text) this.text = filePath;
             return "<a href=\""+outFilePath+"\""+target+">"+this.text+"</a>";
+        },
+        
+          /** very basic link... */
+        _makeFileLink : function(filePath) {
+            var target = (this.targetName)? " target=\""+this.targetName+"\"" : "";
+                
+            var outFilePath =  Link.base + filePath;
+
+            if (!this.text) this.text = filePath;
+            return "<a href=\""+outFilePath+"\""+target+">"+this.text+"</a>";
         }
+        
 });