ENHANCEMENT #2417: Replaced http://www.yoursite.com with the actual base URL

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@62867 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sam Minnee 2008-09-22 22:52:12 +00:00
parent c2b70b7bc5
commit 184352ec05
2 changed files with 14 additions and 4 deletions

View File

@ -53,8 +53,19 @@ class RedirectorPage extends Page {
new TextField("Title", _t('SiteTree.PAGETITLE')),
new TextField("MenuTitle", _t('SiteTree.MENUTITLE')),
new FieldGroup(_t('SiteTree.URL'),
new LabelField("http://www.yoursite.com/"),
new TextField("URLSegment",""),
new LabelField(Director::absoluteBaseURL()),
new UniqueRestrictedTextField("URLSegment",
"URLSegment",
"SiteTree",
_t('SiteTree.VALIDATIONURLSEGMENT1', "Another page is using that URL. URL must be unique for each page"),
"[^A-Za-z0-9-]+",
"-",
_t('SiteTree.VALIDATIONURLSEGMENT2', "URLs can only be made up of letters, digits and hyphens."),
"",
"",
"",
50
),
new LabelField("/")
),
new HeaderField(_t('RedirectorPage.HEADER', "This page will redirect users to another page")),

View File

@ -1115,8 +1115,7 @@ class SiteTree extends DataObject {
),
$tabMeta = new Tab('Meta-data',
new FieldGroup(_t('SiteTree.URL', "URL"),
new LabelField("http://www.yoursite.com/"),
//new TextField("URLSegment",""),
new LabelField(Director::absoluteBaseURL()),
new UniqueRestrictedTextField("URLSegment",
"URLSegment",
"SiteTree",