Skip to content
Browse files

Added javascript to make portlet links open in parent window

Also changed text in portlet from "width" to "width in pixels"
  • Loading branch information...
1 parent e3e0eca commit 437ab1c3201ac10b7703dc0552747c32891f191c @espenmn espenmn committed May 11, 2012
View
7 collective/plonetruegallery/browser/views/templates/placelayout.pt
@@ -4,6 +4,13 @@
<div tal:replace="structure provider:plone.htmlhead" />
<tal:replace tal:replace="structure view/displayer/css" />
<tal:replace tal:replace="structure view/displayer/javascript" />
+ <script type="text/javascript">
+
+ $(document).ready(function() {
+ $(".placelayout a").attr("target", "_parent");
+ });
+ </script>
+
</head>
<body class="placelayout">
View
1 collective/plonetruegallery/gallery-portlet.pt
@@ -50,4 +50,5 @@
tal:attributes="src string:${view/gallery/absolute_url}/@@placegalleryview;
width view/data/width;
height python: height and str(height) + 'px' or '';" />
+
</tal:defs>
View
4 collective/plonetruegallery/portlets.py
@@ -39,14 +39,14 @@ class IGalleryPortlet(IPortletDataProvider):
default=True)
width = schema.Int(
- title=_(u"gallery_portlet_width_title", default=u"Width"),
+ title=_(u"gallery_portlet_width_title", default=u"Width in pixels"),
description=_(u"gallery_portlet_width_description",
default=u"The width of the image in the portlet"),
required=True,
default=200)
height = schema.Int(
- title=_(u"gallery_portlet_height_title", default=u"Height"),
+ title=_(u"gallery_portlet_height_title", default=u"Height in pixels"),
description=_(u"gallery_portlet_height_description",
default=u"The height of the image in the portlet."
u"If 0, no height is set."),

0 comments on commit 437ab1c

Please sign in to comment.
Something went wrong with that request. Please try again.