Commit Graph

205 Commits

Author SHA1 Message Date
Sam Minnee
e5afa25522 MINOR: Use Deprecation class to indicate deprecated methods in core. 2011-10-29 17:34:31 +13:00
Simon Welsh
82da8a0718 Only set the create_table_options value when enabling FulltextSearch 2011-10-29 15:24:06 +13:00
Simon Welsh
ca074eb7ba Changes default MySQL storage engine to InnoDB. File requires MyISAM for FulltextSearch. 2011-10-29 13:34:45 +13:00
Hamish Friedlander
0a3e0f15de MINOR: Replace references to FieldSet (now deprecated) with references to FieldList 2011-10-28 15:58:55 +13:00
Ingo Schommer
da0ac49d5f API CHANGE Rewriting underscores to dashes in files uploaded through Upload->load(), Folder->addUploadToFolder() or Image->loadUploadedImage(). Transliterating non-ASCII characters automatically (turn off via FileNameFilter::$default_use_transliterator=false)
ENHANCEMENT New FileNameFilter class for a more customisable way to influence filename filtering in Upload->load(), Folder->addUploadToFolder() or Image->loadUploadedImage()
2011-10-07 14:12:46 +02:00
Ingo Schommer
afeccbc9cb ENHANCEMENT Added File::get_class_for_file_extension() instead of hardcoding it in Folder->constructChild(). Allows for custom classes in files uploaded through core functionality like the Upload and FileField logic. 2011-10-07 14:12:45 +02:00
Will Rossiter
1732a17114 Merged new-orm into datagrid 2011-09-26 16:47:54 +13:00
Ingo Schommer
6564fafa21 MINOR Removed unused parameter from File->Link() and File->RelativeLink() 2011-09-23 08:39:43 +02:00
Ingo Schommer
ce8e72cf0e MINOR Removing executable flag from all files (thanks miiihi) 2011-09-18 22:04:02 +02:00
Will Rossiter
f0933e32de Merge pull request #59 from mobiusnz/master
BUGFIX: Files with uppercase extensions were not being assigned an appCategory()
2011-09-15 18:15:51 -07:00
Ingo Schommer
31b477ee0c ENHANCEMENT Added File.ShowInSearch flag to mirror the existing SiteTree.ShowInSearch flag - e.g. useful to limit visibility of user-uploaded files. Enforced in MySQLDatabase->searchEngine(). Tested in cms with SearchEngineTest. 2011-09-15 16:00:54 +02:00
Al
af81f44337 [BUGFIX] Files with uppercase extensions were not being assigned an appCategory() 2011-09-14 16:28:37 +12:00
ajshort
1f6f7f0862 API CHANGE: Deprecated CompositeField->FieldSet() in favour of CompositeField->FieldList().
MINOR: Replaced usage of FieldSet with FieldList.
MINOR: Renamed FieldSetTest to FieldListTest.
2011-05-11 17:51:54 +10:00
ajshort
3fbb29a6c5 FEATURE: Added PaginatedList, which wraps around a data list or set to provide pagination functionality. This replaces the pagination functionality baked into DataObjectSet.
API CHANGE: Removed pagination related methods from DataObjectSet and implemented them on PaginatedList.
API CHANGE: Removed DataObjectSet::parseQueryLimit(), this is now implemented as PaginatedList::setPaginationFromQuery().
API CHANGE: Deprecated DataObjectSet::TotalItems in favour of Count().
ENHANCEMENT: Added FirstLink and LastLink to PaginatedList.
MINOR: Updated documentation, and added a how-to on paginating items.
2011-05-01 15:26:29 +12:00
Julian Seidenberg
5efdc60029 API-CHANGE: Renaming a folder did not update the folder's filename on the disk. This is now fixed. There is now a one-to-one mapping between a folder and its "Title" label. Files still can have a Title that is different from the Filename (fixes #6088, thanks Pike) 2011-03-30 18:16:16 +13:00
Ingo Schommer
d93025d668 MINOR Moved File->BackLinkTracking feature from 'sapphire' to 'cms' 2011-03-29 18:07:57 +13:00
Sam Minnee
1e0c4ae8d1 Merge branch '2.4'
Conflicts:
	cache/Cache.php
	cli/CliController.php
	core/Convert.php
	core/Core.php
	core/ManifestBuilder.php
	core/Object.php
	core/SSViewer.php
	core/control/ContentController.php
	core/control/ContentNegotiator.php
	core/control/FormResponse.php
	core/control/RequestHandler.php
	core/control/SilverStripeNavigatorItem.php
	core/i18n.php
	core/i18nTextCollector.php
	core/model/DataObjectSet.php
	core/model/Hierarchy.php
	core/model/Image.php
	core/model/MySQLDatabase.php
	core/model/SiteConfig.php
	core/model/SiteTree.php
	core/model/Translatable.php
	core/model/VirtualPage.php
	dev/Debug.php
	dev/SapphireTest.php
	dev/TestRunner.php
	dev/YamlFixture.php
	dev/install/MySQLDatabaseConfigurationHelper.php
	docs/en/installation/from-source.md
	docs/en/topics/themes.md
	docs/en/tutorials/4-site-search.md
	email/Mailer.php
	filesystem/File.php
	filesystem/Folder.php
	forms/ComplexTableField.php
	forms/CurrencyField.php
	forms/DateField.php
	forms/FieldSet.php
	forms/FileField.php
	forms/FileIFrameField.php
	forms/HtmlEditorConfig.php
	forms/HtmlEditorField.php
	forms/SelectionGroup.php
	forms/SimpleImageField.php
	forms/TabSet.php
	forms/TableField.php
	forms/TableListField.php
	forms/TreeDropdownField.php
	forms/TreeMultiselectField.php
	integration/Geoip.php
	javascript/SelectionGroup.js
	javascript/TreeSelectorField.js
	javascript/UpdateURL.js
	javascript/core/jquery.ondemand.js
	javascript/tiny_mce_improvements.js
	javascript/tree/tree.js
	lang/en_US.php
	search/ContentControllerSearchExtension.php
	security/Group.php
	security/Member.php
	security/PermissionCheckboxSetField.php
	security/PermissionRole.php
	security/Security.php
	static-main.php
	templates/RelationComplexTableField.ss
	templates/TableListField.ss
	tests/ConvertTest.php
	tests/DataObjectSetTest.php
	tests/DataObjectTest.php
	tests/DataObjectTest.yml
	tests/RequestHandlingTest.php
	tests/SSViewerTest.php
	tests/SiteTreePermissionsTest.php
	tests/SiteTreeTest.php
	tests/TransactionTest.php
	tests/api/RestfulServiceTest.php
	tests/control/DirectorTest.php
	tests/control/ModelAsControllerTest.php
	tests/fieldtypes/WidgetAreaEditorTest.php
	tests/forms/CurrencyFieldTest.php
	tests/forms/FormTest.php
	tests/model/DatabaseTest.php
	tests/model/ImageTest.php
	tests/search/ContentControllerSearchExtensionTest.php
	tests/security/MemberAuthenticatorTest.php
	thirdparty/.gitignore
	thirdparty/behaviour/behaviour.js
	thirdparty/firebug-lite/firebug.js
	thirdparty/firebug-lite/firebugx.js
	thirdparty/jquery-form/jquery.form.js
	thirdparty/jquery-livequery/jquery.livequery.js
	thirdparty/jquery-livequery/test/jquery.js
	thirdparty/jquery-livequery/test/test.html
	thirdparty/jquery-livequery/test/test2.html
	thirdparty/jquery-metadata/META.json
	thirdparty/jquery-metadata/README
	thirdparty/jquery-metadata/jquery.metadata.js
	thirdparty/jquery-metadata/test/index.html
	thirdparty/jquery-metadata/test/jquery.js
	thirdparty/jquery-metadata/test/test.js
	thirdparty/jquery-metadata/test/testrunner.js
	thirdparty/jquery-metadata/test/testsuite.css
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_flat_75_ffffff_40x100.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_glass_65_ffffff_1x400.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_glass_75_dadada_1x400.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-icons_222222_256x240.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-icons_2e83ff_256x240.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-icons_454545_256x240.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-icons_888888_256x240.png
	thirdparty/jquery-ui-themes/smoothness/images/ui-icons_cd0a0a_256x240.png
	thirdparty/jquery-ui/i18n/jquery-ui-i18n.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ar.js
	thirdparty/jquery-ui/i18n/ui.datepicker-bg.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ca.js
	thirdparty/jquery-ui/i18n/ui.datepicker-cs.js
	thirdparty/jquery-ui/i18n/ui.datepicker-da.js
	thirdparty/jquery-ui/i18n/ui.datepicker-de.js
	thirdparty/jquery-ui/i18n/ui.datepicker-el.js
	thirdparty/jquery-ui/i18n/ui.datepicker-eo.js
	thirdparty/jquery-ui/i18n/ui.datepicker-es.js
	thirdparty/jquery-ui/i18n/ui.datepicker-fa.js
	thirdparty/jquery-ui/i18n/ui.datepicker-fi.js
	thirdparty/jquery-ui/i18n/ui.datepicker-fr.js
	thirdparty/jquery-ui/i18n/ui.datepicker-he.js
	thirdparty/jquery-ui/i18n/ui.datepicker-hr.js
	thirdparty/jquery-ui/i18n/ui.datepicker-hu.js
	thirdparty/jquery-ui/i18n/ui.datepicker-hy.js
	thirdparty/jquery-ui/i18n/ui.datepicker-id.js
	thirdparty/jquery-ui/i18n/ui.datepicker-is.js
	thirdparty/jquery-ui/i18n/ui.datepicker-it.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ja.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ko.js
	thirdparty/jquery-ui/i18n/ui.datepicker-lt.js
	thirdparty/jquery-ui/i18n/ui.datepicker-lv.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ms.js
	thirdparty/jquery-ui/i18n/ui.datepicker-nl.js
	thirdparty/jquery-ui/i18n/ui.datepicker-no.js
	thirdparty/jquery-ui/i18n/ui.datepicker-pl.js
	thirdparty/jquery-ui/i18n/ui.datepicker-pt-BR.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ro.js
	thirdparty/jquery-ui/i18n/ui.datepicker-ru.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sk.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sl.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sq.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sr-SR.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sr.js
	thirdparty/jquery-ui/i18n/ui.datepicker-sv.js
	thirdparty/jquery-ui/i18n/ui.datepicker-th.js
	thirdparty/jquery-ui/i18n/ui.datepicker-tr.js
	thirdparty/jquery-ui/i18n/ui.datepicker-uk.js
	thirdparty/jquery-ui/i18n/ui.datepicker-zh-CN.js
	thirdparty/jquery-ui/i18n/ui.datepicker-zh-TW.js
	thirdparty/jquery/jquery.js
	thirdparty/jsmin/.piston.yml
	thirdparty/jsmin/jsmin.php
	thirdparty/prototype/prototype.js
	thirdparty/scriptaculous/dragdrop.js
	thirdparty/simplepie/.piston.yml
	thirdparty/spyc/.piston.yml
	thirdparty/spyc/README
	thirdparty/spyc/php4/spyc.php4
	thirdparty/spyc/php4/test.php4
	thirdparty/spyc/spyc.php
	thirdparty/spyc/spyc.yaml
	thirdparty/tinymce-advcode/dialog.html
	thirdparty/tinymce-advcode/editor_plugin_src.js
	thirdparty/tinymce-advcode/js/dialog.js
	thirdparty/tinymce/langs/en.js
	thirdparty/tinymce/plugins/advhr/langs/en_dlg.js
	thirdparty/tinymce/plugins/advhr/rule.htm
	thirdparty/tinymce/plugins/advimage/image.htm
	thirdparty/tinymce/plugins/advimage/langs/en_dlg.js
	thirdparty/tinymce/plugins/advlink/langs/en_dlg.js
	thirdparty/tinymce/plugins/advlink/link.htm
	thirdparty/tinymce/plugins/emotions/emotions.htm
	thirdparty/tinymce/plugins/emotions/langs/en_dlg.js
	thirdparty/tinymce/plugins/example/dialog.htm
	thirdparty/tinymce/plugins/fullpage/fullpage.htm
	thirdparty/tinymce/plugins/fullpage/langs/en_dlg.js
	thirdparty/tinymce/plugins/fullscreen/fullscreen.htm
	thirdparty/tinymce/plugins/inlinepopups/template.htm
	thirdparty/tinymce/plugins/media/langs/en_dlg.js
	thirdparty/tinymce/plugins/media/media.htm
	thirdparty/tinymce/plugins/paste/js/pasteword.js
	thirdparty/tinymce/plugins/paste/langs/en_dlg.js
	thirdparty/tinymce/plugins/paste/pastetext.htm
	thirdparty/tinymce/plugins/paste/pasteword.htm
	thirdparty/tinymce/plugins/searchreplace/langs/en_dlg.js
	thirdparty/tinymce/plugins/searchreplace/searchreplace.htm
	thirdparty/tinymce/plugins/spellchecker/editor_plugin.js
	thirdparty/tinymce/plugins/spellchecker/editor_plugin_src.js
	thirdparty/tinymce/plugins/style/langs/en_dlg.js
	thirdparty/tinymce/plugins/style/props.htm
	thirdparty/tinymce/plugins/table/cell.htm
	thirdparty/tinymce/plugins/table/langs/en_dlg.js
	thirdparty/tinymce/plugins/table/merge_cells.htm
	thirdparty/tinymce/plugins/table/row.htm
	thirdparty/tinymce/plugins/table/table.htm
	thirdparty/tinymce/plugins/template/langs/en_dlg.js
	thirdparty/tinymce/plugins/template/template.htm
	thirdparty/tinymce/plugins/xhtmlxtras/abbr.htm
	thirdparty/tinymce/plugins/xhtmlxtras/acronym.htm
	thirdparty/tinymce/plugins/xhtmlxtras/attributes.htm
	thirdparty/tinymce/plugins/xhtmlxtras/cite.htm
	thirdparty/tinymce/plugins/xhtmlxtras/del.htm
	thirdparty/tinymce/plugins/xhtmlxtras/ins.htm
	thirdparty/tinymce/plugins/xhtmlxtras/langs/en_dlg.js
	thirdparty/tinymce/themes/advanced/about.htm
	thirdparty/tinymce/themes/advanced/anchor.htm
	thirdparty/tinymce/themes/advanced/charmap.htm
	thirdparty/tinymce/themes/advanced/color_picker.htm
	thirdparty/tinymce/themes/advanced/image.htm
	thirdparty/tinymce/themes/advanced/langs/en.js
	thirdparty/tinymce/themes/advanced/langs/en_dlg.js
	thirdparty/tinymce/themes/advanced/link.htm
	thirdparty/tinymce/themes/advanced/source_editor.htm
	thirdparty/tinymce/themes/simple/langs/en.js
	thirdparty/tinymce/tiny_mce.js
	thirdparty/tinymce/tiny_mce_src.js
	widgets/Widget.php
2011-02-14 18:47:53 +13:00
Carlos Barberis
014087f0f7 ENHANCEMENT: Changed canEdit and canCreate extend to extendedCan
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@115416 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:20:06 +13:00
Sam Minnee
cf0bf20e26 BUGFIX: Don't include web.config in the assets tracked in the File table.
MINOR: Add documentation to File::$allowed_extensions explaining that there are config files to edit in assets/

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@112961 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:58 +13:00
Ingo Schommer
b33d4e2856 BUGFIX Changing File->Filename property from arbitrary limitation on VARCHAR (255 characters) to TEXT (65k characters) to ensure the framework can handle deeply nested filesystem trees (fixes #6015, thanks muzdowski)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@111494 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:53 +13:00
Ingo Schommer
47fd9be0e0 BUGFIX Moving folder after executing Folder::findOrMake will not set the Filenames properly. Invoking updateFilesystem() in File->onAfterWrite() instead of onBeforeWrite(), and avoid caching in FIle->getRelativePath() (fixes #5994 and #5937, thanks muzdowski)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@111493 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:53 +13:00
Sean Harvey
58ce293347 BUGFIX Count() call on a non-object in File::BackLinkTrackingCount()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@109079 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:45 +13:00
Sean Harvey
d85e75fbe6 BUGFIX Fixed File::getAbsoluteURL() absolute generation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@109063 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:45 +13:00
Sean Harvey
cbd2bfb976 BUGFIX File::getAbsoluteURL() should return a URL, not a filesystem path
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@109062 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:45 +13:00
Ingo Schommer
b23c650c8a BUGFIX Case insensitive extension checks in File::validate() (fixes #5781, thanks simon_w)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107539 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:37 +13:00
Ingo Schommer
60cfa9e9e8 MINOR Better presentation of extension error message in File and UploadValidator
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107274 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:34 +13:00
Ingo Schommer
c82f0335f0 API CHANGE Don't reflect changes in File and Folder property setters on filesystem before write() is called, to ensure that validate() applies in all cases. This fixes a problem where File->setName() would circumvent restrictions in File::$allowed_extensions (fixes #5693)
API CHANGE Removed File->resetFilename(), use File->updateFilesystem() to update the filesystem, and File->getRelativePath() to just update the "Filename" property without any filesystem changes (emulating the old $renamePhysicalFile method argument in resetFilename())
API CHANGE Removed File->autosetFilename(), please set the "Filename" property via File->getRelativePath()
MINOR Added unit tests to FileTest and FolderTest (some of them copied from FileTest, to test Folder behaviour separately)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107273 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:34 +13:00
Ingo Schommer
2a5a00ced4 MINOR Using File::get_file_extension() instead of substr() magic in File->setName()
MINOR Using exceptions instead of user_error() in File->setName()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107269 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:34 +13:00
Ingo Schommer
a00dc63124 API CHANGE Deprecated File->getLinkedURL()
MINOR Avoiding duplication by using existing getFullPath() in File->getAbsoluteURL()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107268 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:34 +13:00
Ingo Schommer
3781ecc784 MINOR Made File::get_file_extension() more readable, and added unit test
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107267 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:34 +13:00
Ingo Schommer
80ce0b5f4f MINOR Removed File->setField(), doesn't have any overloaded functionality
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107266 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:33 +13:00
Ingo Schommer
7e65d3c5af MINOR Documentation in File and Folder class
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107265 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:33 +13:00
Ingo Schommer
aefecf2965 MINOR Documentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@106804 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:32 +13:00
Ingo Schommer
0742a38732 MINOR Using ASSETS_DIR and THEMES_DIR constant in Image, ManifestBuilder, Requirements, File (fixes #5619)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@105282 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:27 +13:00
Sam Minnee
b28b0939f2 BUGFIX: Removed references to php5 binary in Makefile
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@104666 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:22 +13:00
Will Rossiter
2a8dd78059 MINOR: added illustrator formats to the allowed extensions.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@104636 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:22 +13:00
Geoff Munn
d21e7b0623 BUGFIX: default sort column now quoted
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@103182 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:13 +13:00
Tom Rix
be41f12a4f MINOR TreeTitle really should return title, not name.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101882 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:09 +13:00
Ingo Schommer
1e9aeaef3e BUGFIX Fixed Folder writing by overloading validate() (was inheriting File->validate() which does extension checks)
BUGFIX Fixed Folder::findOrMake() not to create "new-folder" through File->setName() if using a trailing slash in the path (which causes an empty name). Added FolderTest to verify this.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101266 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:04 +13:00
Sam Minnee
3aad86d9be API CHANGE: Added SiteTree::VirtualPages() and SiteTree::DependentPages() accessors.
BUGFIX: Improved reliabilty of broken link tracking.
ENHANCEMENT: Added 'Dependent pages' tab to CMS, to show virtuals, redirectors, and backlinks that point to this page.
BUGFIX: Don't mark a page as changed on stage if the only thing that has changed is broken link metadata

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101127 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:02 +13:00
Ingo Schommer
2f516d4311 MINOR Documentation relating to r101106
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101107 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:01 +13:00
Sean Harvey
81afa6d67e BUGFIX Allow files with no extensions by setting File::$allowed_extensions with an empty string
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101051 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:00 +13:00
Sam Minnee
5fc298cf1e API CHANGE: Made MySQL fulltext search optional, activated with MySQLFulltextSearchable::enable()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101044 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:00 +13:00
Sean Harvey
55eda363f4 MINOR Added more allowed extensions to File::$allowed_extensions
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@100740 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:51 +13:00
Sean Harvey
74d5761a3c API CHANGE Removed deprecated File::loadUploaded(), please use Upload directly instead!
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@100495 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:46 +13:00
Ingo Schommer
d616f9b8bb MINOR Localized File->uploadMetadataFields()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@99111 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:37 +13:00
Ingo Schommer
d404a53569 FEATURE set file metadata on upload. (from r97780)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@99106 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:37 +13:00
Andreas Piening
7de75919ac MINOR: fixed setName()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@98282 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:25 +13:00
Normann Lou
0f810b9a3f BUGFIX: missing comma
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97937 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:18 +13:00
Normann Lou
edaf66d242 MINOR: add flv (flash file) to File::$allowed_extensions
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97936 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:18 +13:00
Normann Lou
398f21a678 BUGFIX: can't upload swf file in admin/assets (open ticket #4999)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97935 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:18 +13:00
Andrew Short
8361a41c16 MINOR: Don't include files and folders starting with an underscore in the asset system.
MINOR: Automatically rename files and folders beginning with an underscore.

From: Andrew Short <andrewjshort@gmail.com> (from r97400)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97435 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:12 +13:00
Sean Harvey
e77964a5b9 API CHANGE #3600 Inconsistency in File::getURL() which returns an absolute URL, when it should be relative - please use getAbsoluteURL() instead for old behaviour
API CHANGE #3600 Image no longer has an explicit getURL() method, instead it inherits getURL() from File which returns a relative URL


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96988 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:08 +13:00
Sam Minnee
67f827cb5a BUGFIX: Apply file extension restrictions to extensions properly. (from r93531)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96761 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:07 +13:00
Sam Minnee
da2f90d187 BUGFIX: Changed default config to restrict file-upload types to ADMINs, since it's protecting against security holes. (from r93327)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96759 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:06 +13:00
Sam Minnee
3c88905299 BUGFIX: Add a default list of allowed extensions so that the CMS works reasonably out of the box.
BUGFIX: Allow files that don't have an extension (most notably folders)
BUGFIX: Ensure that file URL rewriting works if you rename a page twice without publishing.
BUGFIX: Ensure that the page doesn't go green after URLs are rewritten
ENHANCEMENT: Recognise HTTP_X_FORWARDED_HOST header and use that in place of HTTP_HOST (from r93148)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96752 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:06 +13:00
Sam Minnee
5930458997 MINOR moved allowed_extensions and friends to the model layer (from r92046)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96743 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:05 +13:00
Sam Minnee
b4dc73e002 MINOR moved File validation to the model (from r92044)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96742 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:05 +13:00
Ingo Schommer
1c34d8f1b4 API CHANGE Deprecated TreeTitle(), use getTreeTitle() (in SiteTree, File, Group)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@115119 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-12-16 05:16:06 +00:00
Sam Minnee
6cec0a083e BUGFIX: Don't include web.config in the assets tracked in the File table.
MINOR: Add documentation to File::$allowed_extensions explaining that there are config files to edit in assets/ (from r112961)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@114496 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-12-05 00:05:05 +00:00
Sam Minnee
4e0450b590 BUGFIX Changing File->Filename property from arbitrary limitation on VARCHAR (255 characters) to TEXT (65k characters) to ensure the framework can handle deeply nested filesystem trees (fixes #6015, thanks muzdowski) (from r111494)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112909 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-19 04:05:29 +00:00
Sam Minnee
b2624e0012 BUGFIX Moving folder after executing Folder::findOrMake will not set the Filenames properly. Invoking updateFilesystem() in File->onAfterWrite() instead of onBeforeWrite(), and avoid caching in FIle->getRelativePath() (fixes #5994 and #5937, thanks muzdowski) (from r111493)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112908 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-19 04:00:57 +00:00
Sam Minnee
e6976a8458 BUGFIX Count() call on a non-object in File::BackLinkTrackingCount() (from r109079)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112773 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-19 00:53:21 +00:00
Sam Minnee
f99e6059b1 BUGFIX Fixed File::getAbsoluteURL() absolute generation (from r109063)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112771 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-19 00:52:36 +00:00
Sam Minnee
46f1994da4 BUGFIX File::getAbsoluteURL() should return a URL, not a filesystem path (from r109062)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112770 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-19 00:52:21 +00:00
Ingo Schommer
1c54a6dc77 BUGFIX Case insensitive extension checks in File::validate() (fixes #5781, thanks simon_w) (from r107539)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112604 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:53:54 +00:00
Ingo Schommer
35b41709c2 MINOR Better presentation of extension error message in File and UploadValidator (from r107274)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112565 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:21:04 +00:00
Ingo Schommer
5d5bb2618a API CHANGE Don't reflect changes in File and Folder property setters on filesystem before write() is called, to ensure that validate() applies in all cases. This fixes a problem where File->setName() would circumvent restrictions in File::$allowed_extensions (fixes #5693)
API CHANGE Removed File->resetFilename(), use File->updateFilesystem() to update the filesystem, and File->getRelativePath() to just update the "Filename" property without any filesystem changes (emulating the old $renamePhysicalFile method argument in resetFilename())
API CHANGE Removed File->autosetFilename(), please set the "Filename" property via File->getRelativePath()
MINOR Added unit tests to FileTest and FolderTest (some of them copied from FileTest, to test Folder behaviour separately) (from r107273)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112563 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:20:47 +00:00
Ingo Schommer
4d0502822f MINOR Using File::get_file_extension() instead of substr() magic in File->setName()
MINOR Using exceptions instead of user_error() in File->setName() (from r107269)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112557 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:15:38 +00:00
Ingo Schommer
3581a8d5f8 API CHANGE Deprecated File->getLinkedURL()
MINOR Avoiding duplication by using existing getFullPath() in File->getAbsoluteURL() (from r107268)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112556 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:15:26 +00:00
Ingo Schommer
96d1625102 MINOR Made File::get_file_extension() more readable, and added unit test (from r107267)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112555 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:14:59 +00:00
Ingo Schommer
6cf5372bf4 MINOR Removed File->setField(), doesn't have any overloaded functionality (from r107266)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112554 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:13:57 +00:00
Ingo Schommer
2d127753ed MINOR Documentation in File and Folder class (from r107265)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112553 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:12:39 +00:00
Ingo Schommer
122549ca60 MINOR Documentation (from r106804)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112538 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 03:04:27 +00:00
Ingo Schommer
2943c75156 MINOR Using ASSETS_DIR and THEMES_DIR constant in Image, ManifestBuilder, Requirements, File (fixes #5619) (from r105282)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112493 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 02:37:41 +00:00
Ingo Schommer
1724b1fa5a BUGFIX: Removed references to php5 binary in Makefile (from r104666)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112360 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 00:32:26 +00:00
Ingo Schommer
54c7e9b2cb MINOR: added illustrator formats to the allowed extensions. (from r104636)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112359 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-15 00:31:56 +00:00
Sam Minnee
5fd242a25b MINOR TreeTitle really should return title, not name. (from r101882)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112047 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-13 01:17:06 +00:00
Sam Minnee
767bfedd30 BUGFIX Fixed Folder writing by overloading validate() (was inheriting File->validate() which does extension checks)
BUGFIX Fixed Folder::findOrMake() not to create "new-folder" through File->setName() if using a trailing slash in the path (which causes an empty name). Added FolderTest to verify this. (from r101266)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@111984 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-12 23:02:10 +00:00
Sam Minnee
d19bf168b0 API CHANGE: Added SiteTree::VirtualPages() and SiteTree::DependentPages() accessors.
BUGFIX: Improved reliabilty of broken link tracking.
ENHANCEMENT: Added 'Dependent pages' tab to CMS, to show virtuals, redirectors, and backlinks that point to this page.
BUGFIX: Don't mark a page as changed on stage if the only thing that has changed is broken link metadata (from r101127)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@111594 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-04 04:52:46 +00:00
Sam Minnee
9cec4a007e MINOR Documentation relating to r101106 (from r101107)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@111588 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-04 04:47:19 +00:00
Sam Minnee
40091e6c4e BUGFIX Allow files with no extensions by setting File::$allowed_extensions with an empty string (from r101051)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@111573 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-04 04:42:25 +00:00
Sam Minnee
ce173efce3 API CHANGE: Made MySQL fulltext search optional, activated with MySQLFulltextSearchable::enable() (from r101044)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@111569 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-10-04 04:32:48 +00:00
Ingo Schommer
132a5ebaab MINOR Added more allowed extensions to File::$allowed_extensions (from r100740)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@105633 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-05-25 04:26:31 +00:00
Ingo Schommer
1e5944c690 API CHANGE Removed deprecated File::loadUploaded(), please use Upload directly instead! (from r100495)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@105580 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-05-25 03:58:39 +00:00
Ingo Schommer
e99d56df3f MINOR Localized File->uploadMetadataFields() (from r99111)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102852 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-14 04:10:42 +00:00
Ingo Schommer
195e341c88 FEATURE set file metadata on upload. (from r97780) (from r99106)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102849 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-14 04:09:09 +00:00
Ingo Schommer
2978728265 MINOR: fixed setName() (from r98282)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102640 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-13 03:19:28 +00:00
Ingo Schommer
99df0fbbeb BUGFIX: missing comma (from r97937)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102559 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-13 01:45:40 +00:00
Ingo Schommer
1a13d9e5f5 MINOR: add flv (flash file) to File::$allowed_extensions (from r97936)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102558 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-13 01:45:28 +00:00
Ingo Schommer
07cc1f10fa BUGFIX: can't upload swf file in admin/assets (open ticket #4999) (from r97935)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102557 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-13 01:45:16 +00:00
Ingo Schommer
474a6a9931 API CHANGE #3600 Inconsistency in File::getURL() which returns an absolute URL, when it should be relative - please use getAbsoluteURL() instead for old behaviour
API CHANGE #3600 Image no longer has an explicit getURL() method, instead it inherits getURL() from File which returns a relative URL (from r96988)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102415 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 03:29:56 +00:00
Ingo Schommer
f8163a99eb BUGFIX: Apply file extension restrictions to extensions properly. (from r93531) (from r96761)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102392 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 03:14:52 +00:00
Ingo Schommer
ca29cc367c BUGFIX: Changed default config to restrict file-upload types to ADMINs, since it's protecting against security holes. (from r93327) (from r96759)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102390 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 03:13:41 +00:00
Ingo Schommer
46db9796a5 BUGFIX: Add a default list of allowed extensions so that the CMS works reasonably out of the box.
BUGFIX: Allow files that don't have an extension (most notably folders)
BUGFIX: Ensure that file URL rewriting works if you rename a page twice without publishing.
BUGFIX: Ensure that the page doesn't go green after URLs are rewritten
ENHANCEMENT: Recognise HTTP_X_FORWARDED_HOST header and use that in place of HTTP_HOST (from r93148) (from r96752)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102381 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:42:51 +00:00
Ingo Schommer
2ac34ccff0 MINOR moved allowed_extensions and friends to the model layer (from r92046) (from r96743)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102369 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:35:12 +00:00
Ingo Schommer
1bb7bfa71f MINOR moved File validation to the model (from r92044) (from r96742)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102368 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:34:38 +00:00
Geoff Munn
fda7836aca BUG FIX: Default sort columns now quoted properly
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@98232 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-02-04 19:45:14 +00:00
Andrew Short
712cc578d9 MINOR: Don't include files and folders starting with an underscore in the asset system.
MINOR: Automatically rename files and folders beginning with an underscore.

From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@97400 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-01-21 22:59:19 +00:00
Ingo Schommer
8b11599917 BUGFIX Ensuring ParentID is numeric in File->setParentID()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@92562 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-21 02:33:30 +00:00