Ingo Schommer
0242686a7a
Requirements acces to files with query strings ( fixes #7735 )
...
Originally authored by florian.thoma, tests added
by Ingo Schommer. Also removed query params from
file paths before calling mtime() on it.
See https://github.com/silverstripe/sapphire/pull/1023
2013-04-03 16:39:59 +02:00
Ingo Schommer
d969e29d00
API Require ADMIN for ?showtemplate=1
2013-02-12 23:26:04 +01:00
Ingo Schommer
b381e9933d
Include "media" attr for module customCSS() ( fixes #8219 )
2013-02-01 10:23:16 +01:00
Simon Welsh
fc5dd2994c
Add codesniffer that ensures indentation is with tabs.
2012-12-12 00:12:11 +13:00
Sander van Dragt
8f89aa9171
BUG only call filemtime if file exists
...
Added file_exists check before calling filemtime as this results in
'filemtime(): stat failed'
2012-11-21 13:11:53 +13:00
Will Rossiter
dfd3455802
BUG Only include processed requirements at the top level. ( Fixes #7847 )
...
After each sub template was processed Requirements::includeInHTML() is included which appended requirements again.
2012-11-04 17:54:09 +13:00
Sean Harvey
fca9831e66
Remove end php tag from TemplateIteratorProvider
2012-10-10 11:15:55 +13:00
Sam Minnee
1f7fc1f76a
FIX Remove instances of lines longer than 120c
...
The entire framework repo (with the exception of system-generated files) has been amended to respect the 120c line-length limit. This is in preparation for the enforcement of this rule with PHP_CodeSniffer.
2012-09-30 17:18:13 +13:00
Ingo Schommer
e2f073f38a
Method visibility according to coding conventions
2012-09-20 10:46:59 +02:00
Sean Harvey
954eb60983
BUG If combined files can't be written, fallback instantly to uncombined
2012-09-20 14:01:45 +12:00
Fred Condo
3e0782267c
Allow scheme-relative URLs in requirements
...
The Requirements class currently treats only absolute URLs as URLs, and
tries to interpret anything else as a filesystem path. This prevents
using scheme-relative URLs for requirements.
Example:
<% require javascript(//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js) %>
This forces the unfortunate choice of not using a CDN for common
scripts, always using an https absolute URL, or accepting that some
browsers will throw a security warning when viewing the site in https.
This change allows scheme-relative URLs & updates RequirementsTest.
2012-08-22 16:49:55 -07:00
Hamish Friedlander
e160b76df5
BUG 7362 dont include trailing space in bare string
2012-07-23 15:42:58 +12:00
Will Rossiter
168663657b
MINOR: add flag for combine in order to test Requirements::combine_files() while in dev
2012-06-29 18:35:55 +12:00
Hamish Friedlander
0bea6974b6
BUGFIX: Make themedCSS use {theme}_{module}/css/{name}.css files if they exist
...
2.4 used to use a manifest to find css. One side-effect of that is that even without explicit support,
css files in module-specific themes (/themes/{theme}_{module}/) would get picked up. This broke in 3.
This fix does still require the module name to be explicitly passed as a parameter to themedCSS, but if
you do, and a css file of that name exists in the module-specific themes css directory, that will
be included in preference to the theme or module provided css
2012-06-22 13:34:03 +12:00
Sam Minnee
3f0136749b
API CHANGE: Add Security::ignore_disallowed_actions() to allow site features to be disabled when permissions have failed, rather than redirecting to the log-in form. (Trac #7097 )
2012-06-15 15:17:48 +12:00
Sean Harvey
cbf4ad3a75
MINOR Replace deprecation warnings with Deprecation::notice() instead
2012-05-30 22:33:11 +12:00
Sean Harvey
fa764c72b4
MINOR Using Deprecation::notice() for deprecated method in ViewableData
2012-05-30 22:29:58 +12:00
Sean Harvey
792c89e103
ENHANCEMENT Adding List() in the GenericTemplateGlobalProvider so
...
templates can use <% cached List(Member).max(LastEdited) %> instead
of deprecated "Aggregate" syntax.
2012-05-29 20:04:51 +12:00
Sean Harvey
1bf6495ae0
MINOR Partially reverted 4d4f9e08d9
as we don't need to check
...
forTemplate() exists
2012-05-19 18:17:25 +12:00
Sean Harvey
4d4f9e08d9
MINOR Code formatting in SSViewer
2012-05-19 18:09:39 +12:00
Sean Harvey
e5e8f489a2
Merge branch (pull request #247 ) 'template-global-fixes' of https://github.com/sminnee/sapphire into sminnee-template-global-fixes
2012-05-19 15:39:59 +12:00
Ingo Schommer
13c9011082
Merge pull request #430 from halkyon/getallfields_fixes
...
MINOR Fixing use of deprecated getAllFields(), mark field as deprecated ...
2012-05-11 01:04:38 -07:00
Simon Welsh
ab34688273
BUGFIX: Looping over a PaginatedList in the template caused a seg fault/bus error.
2012-05-11 14:03:31 +12:00
Sean Harvey
1859070fa9
MINOR Fixing use of deprecated getAllFields(), mark field as deprecated properly.
2012-05-11 11:23:24 +12:00
Stig Lindqvist
ce5684c776
BUGFIX Throwing an InvalidArgumentException without the new keyword results in a Fatal error
2012-05-10 11:21:32 +12:00
Will Rossiter
585417d141
Merge pull request #343 from halkyon/object_static_remove_deprecation
...
BUGFIX Remove calls to deprecated Object static methods, update ConfigTest
2012-04-19 14:41:45 -07:00
Sean Harvey
ccb941ea9d
BUGFIX Fixed places where Object::get_static() was being used. Replace
...
with Config system instead.
2012-04-18 23:55:37 +12:00
Sean Harvey
4c6be2931b
BUGFIX Removing use of deprecated Object static functions like
...
get_static(), set_static(), uninherited() etc. Replace with equivalent
Config system get(), update()
2012-04-18 23:10:57 +12:00
Julian Seidenberg
65e3651ff4
API-CHANGE: new translatable syntax _t function
2012-04-18 17:35:31 +12:00
Julian Seidenberg
189c305c83
API-CHANGE: parser for new i18n syntax
2012-04-18 17:35:30 +12:00
Julian Seidenberg
45c7dfd9f5
ENHANCEMENT: tests for new i18n syntax
2012-04-18 17:35:29 +12:00
Sean Harvey
effc654009
MINOR Moved ModulePath to GenericTemplateGlobalProvider
2012-04-15 10:50:21 +12:00
Sean Harvey
8949dfa691
ENHANCEMENT Replaced locations of sapphire with $ModulePath(framework) in templates, based off Controller which implements TemplateGlobalProvider
2012-04-15 10:50:20 +12:00
Simon Welsh
f07258f3cf
MINOR Update @package values to match renaming sapphire
2012-04-15 10:50:19 +12:00
Simon Welsh
3a6341a251
API-CHANGE sapphire folder can now be renamed.
2012-04-15 10:50:19 +12:00
Simon Welsh
f8082e4814
MINOR Add newline to end of files without one
2012-04-15 10:50:19 +12:00
Hamish Friedlander
521742aaf8
ENHANCEMENT: Split arguments passed to SSViewer into underlay and overlay arguments to control precedence. Also fixes breakage of SecurityAdmin
2012-04-13 12:15:34 +12:00
Ingo Schommer
c73b80049a
MINOR Removed usage of deprecated Object::uninherited_static() in core, improves CMS loading speed in live mode by ~3.5%
2012-04-12 18:26:56 +02:00
Sam Minnee
77c95b3434
MINOR: Hamish is all class. ;-)
2012-04-12 13:19:48 +12:00
Sam Minnée
1189322b41
Merge pull request #302 from robert-h-curry/7113-nested-controls-breaking-last
...
BUGFIX: Issue #7113 : Recalculate itemIteratorCount when popping viewer state.
2012-04-11 17:19:46 -07:00
Sam Minnée
168eaf72d8
Merge pull request #300 from silverstripe-scienceninjas/feature/ssviewer-enhancements
...
Feature/ssviewer enhancements
2012-04-11 16:29:22 -07:00
Robert Curry
0daa76d0b7
BUGFIX: Issue #7113 : Recalculate itemIteratorCount when popping viewer state.
2012-04-12 11:16:41 +12:00
Hamish Friedlander
5c336329b6
MINOR: When Up called and we are at the top of the scope, throw a useful error, not just an index undefined error
2012-04-11 22:08:05 +12:00
Hamish Friedlander
21bf409b7b
BUGFIX: Pass arguments through to subtemplates when rendering those too
2012-04-11 21:50:06 +12:00
Hamish Friedlander
e4a043ac0b
ENHANCEMENT: Allow arguments to be passed to templates via an array passed to SSViewer#process and via keyword=value pairs in the <% include %> tag
2012-04-11 21:34:27 +12:00
Hamish Friedlander
40ca21e6e5
MINOR: Remove bugfix that is (a) unnessecary because the key is already just sha hashes, underscores and numbers and (b) broken because it strips the open and close quotes from the key
2012-04-11 21:30:57 +12:00
Andrew O'Neil
142a073ce3
MINOR: Fix E_STRICT warning in SSViewer
2012-04-11 17:36:56 +12:00
Ingo Schommer
40d73127ae
MINOR Using late static binding instead of Object::create() calls
2012-04-04 17:10:31 +02:00
Sam Minnee
acdd07ac6f
BUGFIX: Allow template globals to be used in both object and value contexts (e.g. $Now.Year)
...
BUGFIX: Allow template globals to return objects as well as values.
2012-03-16 15:05:25 +13:00
Sam Minnee
1535ce6d36
BUGFIX: Removed used of lcfirst, as it's PHP 5.3 only
2012-03-09 18:21:01 +13:00