Index: /enpraxis.staticsite/trunk/enpraxis/staticsite/utilities/staticsiteutility.py
===================================================================
--- /enpraxis.staticsite/trunk/enpraxis/staticsite/utilities/staticsiteutility.py	(revision 332)
+++ /enpraxis.staticsite/trunk/enpraxis/staticsite/utilities/staticsiteutility.py	(revision 333)
@@ -131,4 +131,8 @@
             raw = self._httpget(url) 
             self._writeFile(path, raw)
+            aurl = urlparse(url)
+            aurl = urlunparse((aurl[0], aurl[1], aurl[2] + '-view.html', aurl[3], aurl[4], aurl[5]))
+            print 'vvv '+  aurl
+            self.processDocument(url + '/view', portal, dpath, ssprops, alturl=aurl)
 
     def _getDeploymentPath(self, sp):
@@ -170,13 +174,17 @@
         f.close()
     
-    def processDocument(self, url, portal, dpath, ssprops, isFolderish=False):
-        path = self._getObjPath(url, portal.portal_url(), dpath)
+    def processDocument(self, url, portal, dpath, ssprops, isFolderish=False, alturl=None):
+        if alturl:
+            aurl = alturl
+        else:
+            aurl = url
+        path = self._getObjPath(aurl, portal.portal_url(), dpath)
         raw = self._httpget(url)
         soup = BeautifulSoup(raw)
-        self.deployDocumentActions(portal, url, dpath, soup, ssprops)
+        self.deployDocumentActions(portal, aurl, dpath, soup, ssprops)
         if isFolderish:
-            curl = url + '/index.html'
+            curl = aurl + '/index.html'
         else:
-            curl = url
+            curl = aurl
         body = self.runDocumentFilters(portal, curl, soup, ssprops)
         mpath = path
@@ -372,4 +380,5 @@
             results = portal.portal_catalog.searchResults(query={'path':'/'.join(h),}, id=h[-1])
             if results:
+                path = ''
                 if results[0].is_folderish:
                     if view:
@@ -377,13 +386,12 @@
                     else:
                         path = '/'.join(h) + '/index.html'
-                    result = urlunparse((hr[0], hr[1], path, hr[3], hr[4], hr[5]))
-                elif results[0].Type == 'Page':
+                else:
                     if view:
                         path = '/'.join(h) + '-%s.html' %view
                     elif h:
-                        path = '/'.join(h) + '.html'
-                    else:
-                        path = ''
-                    result = urlunparse((hr[0], hr[1], path, hr[3], hr[4], hr[5]))
+                        path = '/'.join(h)
+                        if 'Page' == results[0].Type and '.htm' not in path:
+                            path += '.html'
+                result = urlunparse((hr[0], hr[1], path, hr[3], hr[4], hr[5]))
             elif link == portal.portal_url():
                 # Link points to site root
