Permalink
Browse files

BUGFIX Fixing incorrect URL to edit canonical page on VirtualPage

  • Loading branch information...
1 parent 0515555 commit 7ed09917ac3ded499f57bbf1379b6e1fbfd70789 @halkyon halkyon committed May 22, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 code/model/VirtualPage.php
@@ -195,8 +195,8 @@ function getCMSFields() {
$fields->addFieldToTab("Root.Main", $copyContentFromField, "Title");
// Create links back to the original object in the CMS
- if($this->CopyContentFrom()->ID) {
- $linkToContent = "<a class=\"cmsEditlink\" href=\"admin/show/$this->CopyContentFromID\">" .
+ if($this->CopyContentFrom()->exists()) {
+ $linkToContent = "<a class=\"cmsEditlink\" href=\"admin/pages/edit/show/$this->CopyContentFromID\">" .
_t('VirtualPage.EDITCONTENT', 'click here to edit the content') . "</a>";
$fields->addFieldToTab("Root.Main",
$linkToContentLabelField = new LabelField('VirtualPageContentLinkLabel', $linkToContent),

0 comments on commit 7ed0991

Please sign in to comment.