Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
cbee56f2
Commit
cbee56f2
authored
May 08, 2010
by
Tres Seaver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Handle resource files with .htm extention properly as page template resources.
LP #411837
parent
fb32c3e9
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
27 additions
and
0 deletions
+27
-0
doc/CHANGES.rst
doc/CHANGES.rst
+3
-0
src/Products/Five/browser/resource.py
src/Products/Five/browser/resource.py
+1
-0
src/Products/Five/browser/tests/resource_ftest.txt
src/Products/Five/browser/tests/resource_ftest.txt
+15
-0
src/Products/Five/browser/tests/resource_subdir/resource.htm
src/Products/Five/browser/tests/resource_subdir/resource.htm
+8
-0
No files found.
doc/CHANGES.rst
View file @
cbee56f2
...
@@ -36,6 +36,9 @@ Features Added
...
@@ -36,6 +36,9 @@ Features Added
Bugs Fixed
Bugs Fixed
++++++++++
++++++++++
- LP #411837: Handle resource files with ``.htm`` extention properly,
as page template resources.
- LP #435728: Fix indentation of OFSP/help/sequence.py docstring.
- LP #435728: Fix indentation of OFSP/help/sequence.py docstring.
- LP #574286: Ensure that mailhosts which share a queue directory do not
- LP #574286: Ensure that mailhosts which share a queue directory do not
...
...
src/Products/Five/browser/resource.py
View file @
cbee56f2
...
@@ -132,6 +132,7 @@ class DirectoryResource(Resource, directoryresource.DirectoryResource):
...
@@ -132,6 +132,7 @@ class DirectoryResource(Resource, directoryresource.DirectoryResource):
'pt'
:
PageTemplateResourceFactory
,
'pt'
:
PageTemplateResourceFactory
,
'zpt'
:
PageTemplateResourceFactory
,
'zpt'
:
PageTemplateResourceFactory
,
'html'
:
PageTemplateResourceFactory
,
'html'
:
PageTemplateResourceFactory
,
'htm'
:
PageTemplateResourceFactory
,
}
}
default_factory
=
FileResourceFactory
default_factory
=
FileResourceFactory
...
...
src/Products/Five/browser/tests/resource_ftest.txt
View file @
cbee56f2
...
@@ -92,6 +92,21 @@ Page templates aren't guaranteed to render, so exclude them from the test:
...
@@ -92,6 +92,21 @@ Page templates aren't guaranteed to render, so exclude them from the test:
... response = self.publish(base_url % r, basic='manager:r00t')
... response = self.publish(base_url % r, basic='manager:r00t')
... self.assertEquals(200, response.getStatus())
... self.assertEquals(200, response.getStatus())
>>> print http(r'''
... GET /test_folder_1_/testoid/++resource++fivetest_resources/resource_subdir/resource.htm HTTP/1.1
... Authorization: Basic manager:r00t
... ''')
HTTP/1.1 200 OK
...
<html>
<head>
</head>
<body>
This .html should not have a base tag automatically
added to the header.
</body>
</html>
<BLANKLINE>
We also can traverse into sub-directories:
We also can traverse into sub-directories:
...
...
src/Products/Five/browser/tests/resource_subdir/resource.htm
0 → 100644
View file @
cbee56f2
<html>
<head>
</head>
<body>
This .html should not have a base tag automatically
added to the header.
</body>
</html>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment