<!--#include virtual="/NR/System/WBC/Internals/WBCFuncPages/Cross-Browser/QuickJump/EntryProgrammingConstants.inc"-->
<!--#include virtual="/NR/System/WBC/Internals/WBCFuncPages/Cross-Browser/PageOperation/EditMode/EntryProgrammingConstants.inc"-->

<!-- #include virtual="/NR/System/WBC/Internals/Integration/InternalHooks/URLGenerationHooks/EditSiteOpsHooks.inc" -->
<!-- #include virtual="/NR/System/WBC/Customizable/Hooks/URLGenerationHooks/EditSiteOpsHooks.inc" -->

<%
' ********************************************************************
' Copyright (C) 2001 Microsoft Corporation. All rights reserved.
'
'	IMPORTANT.  Please read the legal.txt file, located in the
'	"<CMS Install Directory>\Server\httpexec\WBC\Internals"
'	directory, governing the use of this internal file."
' ********************************************************************

Dim m_bAreEditSiteOpsVisible
m_bAreEditSiteOpsVisible = (AutoSession.IsModeUnpublished) And _
						(Request.QueryString(IDS_QPARAM_WBCPURPOSE) = IDS_WBCPURPOSE_BASIC)

' -----------------------------------------------------------------------------
'
'	[Public] Checks if we are in the WBC Edit Site Mode
'
' -----------------------------------------------------------------------------
Function AreEditSiteOpsVisible()
	AreEditSiteOpsVisible = m_bAreEditSiteOpsVisible
End Function

' -----------------------------------------------------------------------------
'
'	[Public] Returns if link should be available
'
' -----------------------------------------------------------------------------
Function IsConnectedPagesJumpLinkVisible()
	IsConnectedPagesJumpLinkVisible = False

	Dim pCurrentObject
	Set pCurrentObject = GetCurrentObject()
	If (pCurrentObject.IsPosting) Then
		IsConnectedPagesJumpLinkVisible = ( pCurrentObject.IsConnected )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns if link should be available
'
' -----------------------------------------------------------------------------
Function IsMoveLinkVisible()
	IsMoveLinkVisible = False

	Dim pCurrentObject
	Set pCurrentObject = GetCurrentObject()
	If (pCurrentObject.IsPosting) Then
		IsMoveLinkVisible = ( pCurrentObject.CanMove )
	End If

End Function

' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to the "Go to Connected Page" link
'
' -----------------------------------------------------------------------------
Function GetConnectedPostingQuickJumpURL()

	GetConnectedPostingQuickJumpURL = "#"

	If IsWBCVisible And IsConnectedPagesJumpLinkVisible Then

		GetConnectedPostingQuickJumpURL = IDS_FRAMEWORK_VIRTUAL_PATH  & IDS_QUICKJUMP_PATH & _
										"/ConnectedPagesQuickJump/ConnectedPagesQuickJumpDlg.asp?" & _
										IDS_QPARAM_NRMODE & "=" & IDS_NRMODE_UNPUBLISHED & "&" & _
										IDS_QSTR_QUICKJUMP_CONNECTEDPAGE & "=" & AutoSession.ThisPosting.Guid

		' -- call Internal Hook
		Call OnInternalCustomizeConnectedPostingQuickJumpURL( AutoSession.ThisPosting, GetConnectedPostingQuickJumpURL )

		' -- call External Customizable Hook
		Call OnCustomizeConnectedPostingQuickJumpURL( AutoSession.ThisPosting, GetConnectedPostingQuickJumpURL )
	End If

End Function

' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to edit the current posting
'
' -----------------------------------------------------------------------------
Function GetAuthoringURL(pPosting)
	GetAuthoringURL = "#"

	If IsWBCVisible Then
		GetAuthoringURL = GetWBCAuthoringURL(pPosting)
	End If

End Function

' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to delete the current posting
'
' -----------------------------------------------------------------------------
Function GetDeleteURL()

	GetDeleteURL = "#"

	If IsWBCVisible Then
		GetDeleteURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGELIFECYCLE_PATH & "/PageLifeCycleOp.asp?" & _
						AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
						IDS_QPARAM_WBCACTION & "=" & IDS_ACTION_DELETE

		' -- call Internal Hook
		Call OnInternalCustomizeDeleteURL( AutoSession.ThisPosting, GetDeleteURL )

		' -- call External Customizable Hook
		Call OnCustomizeDeleteURL( AutoSession.ThisPosting, GetDeleteURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Supported for backward compatibility with Version 3.x
'
' -----------------------------------------------------------------------------
Function GetPropertiesURL()
	GetPropertiesURL = GetPostingPropertiesURL()
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to edit properties the current posting
'
' -----------------------------------------------------------------------------
Function GetPostingPropertiesURL()
	GetPostingPropertiesURL = "#"

	If IsWBCVisible Then
		GetPostingPropertiesURL = IDS_FRAMEWORK_VIRTUAL_PATH & "/Internals/WBCFuncPages/Cross-Browser/PropertiesDialog/Posting/PostingPropertiesShow.asp?" & _
							AutoSession.ThisPosting.QueryString

		' -- call Internal Hook
		Call OnInternalCustomizePostingPropertiesURL( AutoSession.ThisPosting, GetPostingPropertiesURL )

		' -- call External Customizable Hook
		Call OnCustomizePostingPropertiesURL( AutoSession.ThisPosting, GetPostingPropertiesURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to edit properties the current channel
'
' -----------------------------------------------------------------------------
Function GetChannelPropertiesURL()
	GetChannelPropertiesURL = "#"

	If IsWBCVisible Then
		GetChannelPropertiesURL = IDS_FRAMEWORK_VIRTUAL_PATH & "/Internals/WBCFuncPages/Cross-Browser/PropertiesDialog/Channel/ChannelPropertiesShow.asp?" & _
							AutoSession.ThisChannel.QueryString

		' -- call Internal Hook
		Call OnInternalCustomizeChannelPropertiesURL( AutoSession.ThisChannel, GetChannelPropertiesURL )

		' -- call External Customizable Hook
		Call OnCustomizeChannelPropertiesURL( AutoSession.ThisChannel, GetChannelPropertiesURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to submit the current posting
'
' -----------------------------------------------------------------------------
Function GetSubmitURL()
	GetSubmitURL = "#"

	If IsWBCVisible Then
		GetSubmitURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGELIFECYCLE_PATH & "/PageLifeCycleOp.asp?" & _
						AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
						IDS_QPARAM_WBCACTION & "=" & IDS_ACTION_SUBMIT

		' -- call Internal Hook
		Call OnInternalCustomizeSubmitURL( AutoSession.ThisPosting, GetSubmitURL )

		' -- call External Customizable Hook
		Call OnCustomizeSubmitURL( AutoSession.ThisPosting, GetSubmitURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to approve the current posting
'
' -----------------------------------------------------------------------------
Function GetApproveURL()
	GetApproveURL = "#"

	If IsWBCVisible Then
		GetApproveURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGELIFECYCLE_PATH & "/PageLifeCycleOp.asp?" & _
						AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
						IDS_QPARAM_WBCACTION & "=" & IDS_ACTION_APPROVE

		' -- call Internal Hook
		Call OnInternalCustomizeApproveURL( AutoSession.ThisPosting, GetApproveURL )

		' -- call External Customizable Hook
		Call OnCustomizeApproveURL( AutoSession.ThisPosting, GetApproveURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to decline the current posting
'
' -----------------------------------------------------------------------------
Function GetDeclineURL()
	GetDeclineURL = "#"

	If IsWBCVisible Then
		GetDeclineURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGELIFECYCLE_PATH & "/PageLifeCycleOp.asp?" & _
						AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
						IDS_QPARAM_WBCACTION & "=" & IDS_ACTION_DECLINE

		' -- call Internal Hook
		Call OnInternalCustomizeDeclineURL( AutoSession.ThisPosting, GetDeclineURL )

		' -- call External Customizable Hook
		Call OnCustomizeDeclineURL( AutoSession.ThisPosting, GetDeclineURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to the revision history of the current posting
'
' -----------------------------------------------------------------------------
Function GetPageRevisionReportURL()
	GetPageRevisionReportURL = "#"

	If IsWBCVisible Then
		GetPageRevisionReportURL = IDS_FRAMEWORK_VIRTUAL_PATH & "/Internals/WBCFuncPages/Cross-Browser/RevisionBrowser/Page/RevisionHistory/PageRevisionDlg.asp?" & _
							AutoSession.ThisPosting.QueryString

		' -- call Internal Hook
		Call OnInternalCustomizePageRevisionReportURL( AutoSession.ThisPosting, GetPageRevisionReportURL )

		' -- call External Customizable Hook
		Call OnCustomizePageRevisionReportURL( AutoSession.ThisPosting, GetPageRevisionReportURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to the "View Revisions By Date" of the current posting
'
' -----------------------------------------------------------------------------
Function GetPageRevisionByDateURL()
	GetPageRevisionByDateURL = "#"

	If IsWBCVisible Then
		GetPageRevisionByDateURL = IDS_FRAMEWORK_VIRTUAL_PATH & "/Internals/WBCFuncPages/Cross-Browser/RevisionBrowser/Page/RevisionPreview/PageRevisionPreviewByDateDlg.asp?" & _
							AutoSession.ThisPosting.QueryString

		' -- call Internal Hook
		Call OnInternalCustomizePageRevisionByDateURL( AutoSession.ThisPosting, GetPageRevisionByDateURL )

		' -- call External Customizable Hook
		Call OnCustomizePageRevisionByDateURL( AutoSession.ThisPosting, GetPageRevisionByDateURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to decline the current posting
'
' -----------------------------------------------------------------------------
Function GetPostingCopyURL()
	GetPostingCopyURL = "#"

	If IsWBCVisible Then
		GetPostingCopyURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGECOPY_PATH & "/PageCopyDlg.asp?" & _
							AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
							IDS_QSTR_PAGEOPERATIONEDIT_SOURCEPAGE & "=" & AutoSession.ThisPosting.Guid

		' -- call Internal Hook
		Call OnInternalCustomizePostingCopyURL( AutoSession.ThisPosting, GetPostingCopyURL )

		' -- call External Customizable Hook
		Call OnCustomizePostingCopyURL( AutoSession.ThisPosting, GetPostingCopyURL )
	End If
End Function


' -----------------------------------------------------------------------------
'
'	[Public] Returns the link to decline the current posting
'
' -----------------------------------------------------------------------------
Function GetPostingMoveURL()
	GetPostingMoveURL = "#"

	If IsWBCVisible And IsMoveLinkVisible Then
		GetPostingMoveURL = IDS_FRAMEWORK_VIRTUAL_PATH & IDS_PAGEOPERATIONEDIT_PAGEMOVE_PATH & "/PageMoveDlg.asp?" & _
							AutoSession.ThisPosting.QueryStringModeUpdate & "&" & _
							IDS_QSTR_PAGEOPERATIONEDIT_SOURCEPAGE & "=" & AutoSession.ThisPosting.Guid

		' -- call Internal Hook
		Call OnInternalCustomizePostingMoveURL( AutoSession.ThisPosting, GetPostingMoveURL )

		' -- call External Customizable Hook
		Call OnCustomizePostingMoveURL( AutoSession.ThisPosting, GetPostingMoveURL )
	End If
End Function
%>
