Commit Graph

260 Commits

Author SHA1 Message Date
Ingo Schommer
a95efe833f added is_cli()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44573 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-11 02:54:19 +00:00
Ingo Schommer
97a44ce0be code formatting, changed $mode_additions to $callbacks
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44567 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-10 05:17:30 +00:00
Sam Minnee
15eff6e217 #1662 - Secured draft/archived content
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44555 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-09 03:42:04 +00:00
Andrew O'Neil
ba4645f8aa Fix Session not saving on some servers (merged from 2.1.1 branch, r43627)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44200 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-04 21:33:50 +00:00
Andrew O'Neil
a462cd2c20 Use the hostname, not the ip address, in dev/test mode tests (merged from 2.1.1 branch, r43542)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44194 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-04 21:15:41 +00:00
Sam Minnee
9dad7b5f1a Bypassed security on the login page
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44140 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-02 01:11:13 +00:00
Andrew O'Neil
367cc65019 #1463 - unlink in ContentController::deleteinstallfiles() needs to have errors caught
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43940 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-29 02:53:53 +00:00
Andrew O'Neil
808d6875cb #941 - Security flaw: SS prone to CSRF attack
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43901 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-28 21:44:38 +00:00
Andrew O'Neil
dc1775169d #941 - Security flaw: SS prone to CSRF attack
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43876 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-26 02:23:55 +00:00
Andrew O'Neil
06c2bd9b10 #1462 - OpenID $currentController problem
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43841 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-25 02:38:35 +00:00
Andrew O'Neil
efc69f3717 GSOC #119 - Sitemap.php/Statistics.php in sapphire/core/control
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43833 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-25 01:21:35 +00:00
Andrew O'Neil
a99a727c29 GSOC #118 - Coding Conventions
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43832 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-25 01:10:31 +00:00
Andrew O'Neil
220a321212 GSOC #113 - Coding Conventions
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43827 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-25 00:37:09 +00:00
Andrew O'Neil
ba02a631c9 Added better checking for wonky databases (merged from 2.1.0 branch, r42589)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42924 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-02 04:56:43 +00:00
Andrew O'Neil
bd81e2a2be Optional reporting of versions to SilverStripe (merged from 2.1.0 branch, r42422)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42920 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-02 04:51:22 +00:00
Andrew O'Neil
3a6556bbd0 Remove css requirements from core, in case user does not want to include these. (merged from 2.1.0 branch, r42168)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42915 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-02 04:40:08 +00:00
Andrew O'Neil
7455457964 Fixed php notice (merged from 2.1.0 branch, r41552)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42911 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-02 04:33:18 +00:00
Ingo Schommer
07c3a3a32b aoneil: allow the dev servers and test servers to be set via Director (merged from branches/2.1.0)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42736 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-27 21:50:10 +00:00
Sam Minnee
fad2ab3eda Updated and improved StaticExporter
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42536 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-25 03:44:07 +00:00
Ingo Schommer
f1285c839d fixed php notices, meaningful heredoc-modifiers
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42159 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 20:35:04 +00:00
Ingo Schommer
5b330d38c4 bfojcapell: If we are visiting a multilingual site Translatable::get_one should be used
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42116 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 16:14:01 +00:00
Ingo Schommer
e435705685 bfojcapell: Added LangAttributes? function
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42115 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 16:12:42 +00:00
Ingo Schommer
4ceb428cb5 bfojcapell: If we are visiting a multilingual site Translatable::get_one should be used
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42114 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 16:12:07 +00:00
Ingo Schommer
c294d023af mlanthaler: Bugfix: Variable was not set as needed.
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42107 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 16:00:35 +00:00
Ingo Schommer
59bc3f83db qhoxie: recent views tweaks
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42101 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:43:22 +00:00
Ingo Schommer
f512d02af7 qhoxie: user activity graphing adjusted
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42100 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:41:31 +00:00
Ingo Schommer
0273d70259 qhoxie: modified chart generation for usability
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42098 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:38:37 +00:00
Ingo Schommer
ea40654253 qhoxie: Statistics controller added for global reporting functions, pageview datatype for recording hit data
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42097 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:37:33 +00:00
Ingo Schommer
40aa45c926 mlanthaler: Director::redirectBack() redirects now to the base URL if neither the referer nor the _REDIRECT_BACK_URL is set.
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42093 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:34:05 +00:00
Ingo Schommer
e9d323b0d8 mlanthaler: The introduction of the HTTPResponse object broke some of my code. It's fixed now.
There was also a bug in the Director class: Director::redirectBack() didn't work because it stopped the script before outputting the headers. 
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42092 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 15:31:44 +00:00
Ingo Schommer
8d89050618 mlanthaler: Refactored the created code since the coding conventions for static methods were changed (ticket #49).
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42019 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-16 01:48:38 +00:00
Ingo Schommer
ef33498a97 elofgren: In SilverStripeNavigator?(), change 'View page in:' to 'Page view:', 'CMS' to 'Edit', and group 'Edit' & 'Draft Site' together. Reason: http://www.silverstripe.com/silverstripe-development/flat/626?showPost=1785#post1785
(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41838 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-15 00:26:21 +00:00
Ingo Schommer
fbc375a282 mlanthaler:OpenID authentication works now. To use it simple create an user account without password and put your *complete* OpenID identifier in the email field, e.g. "http://markus-lanthaler.myopenid.com/".
You can get a free OpenID from http://www.myopenid.com  (merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41785 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 19:10:18 +00:00
Ingo Schommer
4ae8c85d46 mlantahler:Bugfix: Small bugfix to prevent the usage of uninitialized $funcName. Happens if the form is submitted by pressing <enter> instead of pressing the button (at least in IE7). (merged from branches/gsoc)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41779 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 18:02:03 +00:00
Ingo Schommer
898d897c9e mlantahler: Bugfix: $URL != $url. The variable names are case-sensitive in PHP (http://www.php.net/manual/en/language.variables.php) (merged from branches/gsoc)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41777 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 17:47:45 +00:00
Ingo Schommer
0d80ed0e7b wscott: Patched the director to allow modules to register a function
that will be run on every page load. 


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41691 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 00:54:02 +00:00
Ingo Schommer
4cb5bd719a wscott: Added some additional fixes & such to sapphire
TooglePanel? can be created initially closed 
PasswordField? honors a max size passed to it 
SiteTree? / Pages can now have custom meta tags 
Sitemap can deal with pinging google on updates, plus a couple other minor changes 


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41690 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 00:47:00 +00:00
Ingo Schommer
5857c4cab6 wscott: Added base code for a working Google Sitemaps support.
Changes in Files: 
* Sitemap.php - controller for the sitemap, new 
* Sitemap.ss - template for the sitemap, new 

* main.php - added director rule 
* SiteTree?.php - added 'priority' database field, cms code to override priority 

TODO: ping google when the sitemap is updated, 

namely when pages are added / removed, or when a priority is overridden 


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41689 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-14 00:27:15 +00:00
Matt Peel
aaabe7ee94 Removed junk from CVS, unnecessary newlines etc
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41462 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-09-08 03:18:26 +00:00
Sam Minnee
c0660c147b Added Director::redirected_to / Controller::redirectedTo() for redirection-detection
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@41093 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-31 00:26:41 +00:00
Sam Minnee
c8f38617cb #write:31 - Fixed redirection from /home/ to /./ in IE6
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40980 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-28 02:49:31 +00:00
Sam Minnee
79460dadfc Added HTTPResponse::getHeader(), to aid test verification
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40911 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-27 05:09:54 +00:00
Normann Lou
3bc0eaafbb implement validation to tablefield,
fixed bug on validation of datefield, emailfield, numericefield.
make CMS validation enabled.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40755 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-23 05:47:54 +00:00
Andrew O'Neil
30fc2e2a50 Fix redirect back after failing login
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40630 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-21 22:05:40 +00:00
Sam Minnee
3007fa55d5 Added return type hinting to comments
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40596 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-20 23:22:30 +00:00
Sam Minnee
734cf2ad4f Added Director::test() for unit testing
Changed From::testSubmission to use Director::test(), so that it can check whether URLs are correctly set
Made Director::is_ajax() look at the controller data

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40590 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-20 22:39:44 +00:00
Sam Minnee
b5848c9b87 Added HTTPResponse::getLinks() for unit testing
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40589 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-20 22:38:37 +00:00
Andrew O'Neil
7a150c48db Publish error page after installation is complete
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40531 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-20 05:21:39 +00:00
Andrew O'Neil
7eb1c266a6 Fixed error introduced by Controller modifications
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40453 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 23:31:51 +00:00
Sam Minnee
1d3ca74a78 Typo in error message
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40452 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 23:14:30 +00:00
Sam Minnee
9f78d4aa5e Fixed bugs in Session implementation of nested controllers
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40451 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 23:11:43 +00:00
Sam Minnee
9c80282dfd Updated controller model so that sessions are linked to controllers, and current-controller is represented as a stack
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40424 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 05:45:15 +00:00
Sam Minnee
23dab38035 Added missing file from r40392
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40398 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 03:32:14 +00:00
Sam Minnee
8a0688aa5d Added HTTPResponse object, to encapsulate Controller responses for aid testing and other 'quirky' uses of Controllers
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40390 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-17 03:09:46 +00:00
Sam Minnee
c3f124dd95 Let controller extensions define new action MEthods
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40225 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-16 06:27:55 +00:00
Sam Minnee
f97fc4ad65 Added ability for SiteTree extensions to define contentcontrollerInit() or modelascontrollerInit(), to add extra behaviour necessary for some modules (in particular, subsites)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40224 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-16 06:27:32 +00:00
Hayden Smith
b785d359fa Merged in Markus' changes from [37478].
Tidied up the permission checks in SiteTree->can() so they are easier to follow.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@39189 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-07-24 03:43:21 +00:00
Andrew O'Neil
4f6a8736e2 Automatically include form css
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@39081 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-07-20 04:32:58 +00:00
Andrew O'Neil
fccd958077 Move stuff out of Page.php into ContentController so they aren't needed at default install
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@39074 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-07-20 04:05:51 +00:00
Hayden Smith
4a5d9b03f8 Moved Sapphire module to open source path
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@39001 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-07-19 10:40:28 +00:00