Plone 4中是否有一些注销挂钩?(Is there some logout hook in Plone 4?)
我有一个基于Plone-4.3的站点,可以访问另一个站点:当有人登录到我的站点时,他可以点击特殊的超链接并进入那个站点,而无需在那里输入密码基于ReST接口的某种简单的SSO)。
现在,我需要从其他站点注销用户,无论何时他从我自己的站点注销,例如发送一个特殊的请求,这当然不是这个问题的主题(可能它仍然需要实施,因为会话过期曾经足够好。)
我将如何实现这一点,具体如下: 我将在哪里挂钩次要注销代码? 有没有某种注销挂钩,或者我应该修改一些
logout.[c]py
view? 我无法在此处的“ 事件类型”部分找到没有提及的事件和类别。I have a Plone-4.3-based site which provides access to another site as well: Whenever someone logs in to my site, (s)he can click on special hyperlinks and proceed to that other site without the need to enter a password there (some kind of simple SSO, based on a ReST interface).
Now I have the need to logout the user from that other site whenever (s)he logs out from my own site, e.g. by sending a special request which is of course not the topic of this question (perhaps it still needs to be implemented, because session expiration used to be good enough.)
How would I accomplish this, to be precise: Where would I hook in that secondary logout code? Is there some kind of logout hook, or should I modify some
logout.[c]py
view? I couldn't find no event nor category mentioned in the Event types section here.
原文:https://stackoverflow.com/questions/43852342
最满意答案
问题在于rw应该被定义为Object,而不是Range。
Problem was that rw was supposed to be defined as Object, instead of Range.
相关问答
更多-
对于纯文本,您可以这样做 .Body = "blah blah hello world" & vbCrLf & .Body 如果你想保留格式,你需要将你的字符串插入到replyall.HTMLBody属性中(你不能只连接两个HTML字符串)。 For the plain text, you can do .Body = "blah blah hello world" & vbCrLf & .Body If you want to preserve formatting, you will need to ...
-
问题在于rw应该被定义为Object,而不是Range。 Problem was that rw was supposed to be defined as Object, instead of Range.
-
由于逻辑连接“时间”,不可能同时评估这两个条件,让我解释一下。 cat1是一个范围(需要确定什么是第一个)因为cat1可能定义也可能没定义,你无法评估它的<>“”。 cat1 <>“”它需要评估范围是什么。 我知道“人类”思想可能同时存在,但总结如下: A)变量需要首先解决为范围... B)如果<>“”,则进行评估, 我不明白为什么你需要再次评估if <>"" - 如果它没有找到它就没有什么价值 - 为什么不留下声明If Not (cat1 Is Nothing) Then ? It is not poss ...
-
您可以在Outlook中的文件夹树中的任何位置创建日历文件夹。 使用DefaultItemType属性在Outlook中查找日历文件夹,它从OlItemType枚举返回一个常量,指示文件夹中包含的默认Outlook项类型。 如果是日历,您应该获取olAppointmentItem值。 您也可以使用Namespace类的GetDefaultFolder方法获取一个Folder对象,该对象表示当前配置文件所请求类型的默认文件夹; 例如,获取当前登录用户的默认日历文件夹。 Sub ChangeCurrentFol ...
-
您将需要添加Microsoft Excel 14.0数据对象库。 转到工具 - >参考。 您还需要先打开工作簿,然后才能从中运行宏。 这应该工作: Dim ExApp As Excel.Application Dim ExWbk As Workbook Set ExApp = New Excel.Application Set ExWbk = ExApp.Workbooks.Open("C:\Folder\Folder\File.xls") ExApp.Visible = True ExWbk ...
-
VBA从Outlook切换到Excel到IE并返回到Excel(VBA Hand-off from Outlook to Excel to IE and back to Excel)[2023-08-13]
Sub TestJH() Dim Element As Object ' HTMLButtonElement Dim btnInput As Object ' MSHTML.HTMLInputElement Dim ElementCol As Object ' MSHTML.IHTMLElementCollection Dim Link As Object ' MSHTML.HTMLAnchorElement Dim strCountBody As String Dim lStartPos As Long ... -
这是你可以做的事情: With MyItem 'Refer to and fill in variable items in template .Body = Replace(.Body, "<< clientname >>", Worksheets("Clients").Range(1, 2)) End With 或者,如果您的邮件是HTML: With MyItem 'Refer to and fill in variable items in template .HT ...
-
以下代码用于在Registry(SaveMySettings)中存储信息并检索此信息(RetrieveMySettings)。 该程序在此注册表项中保存两个kevaluesys,“Item 1”和“Item 2”:HKEY_CURRENT_USER \ Software \ VB和VBA Program Settings \ My Program \ Sub Program Option Explicit Const Reg_AppName As String = "My Program" Const R ...
-
您应该能够编写与Outlook交互的Excel VBA脚本。 有关此问题的详细指南,请参见http://www.dicks-clicks.com/excel/olAutomating.htm 。 具体来说, http://www.dicks-clicks.com/excel/olCalendar.htm#Creating_an_Appointment提到了如何创建日历项目。 请注意,大多数示例都适用于Outlook / Excel 2000,我想大多数应该仍然适用于较新版本,但某些对象可能会重命名。 Out ...
-
首先, RangeToHTML 。 该脚本将其称为一种方法 ,但事实并非如此。 这是MVP Ron de Bruin的流行功能 。 巧合的是,这些链接指向您发布的脚本的确切来源,然后才能修改这些少数几行。 使用Range.SpecialCells 。 此方法在范围内运行并仅返回符合给定条件的单元格。 就你而言,你似乎只对可见的文本单元感兴趣。 重要的是,它在Range上运行,而不是HTML文本。 为了完整起见,我会在下面发布一个工作版本的脚本。 我肯定会建议忽略它,并重温Ron Bruin的优秀原创。 Su ...