Commit graph

49 commits

Author SHA1 Message Date
Joshua Sherman
c9f39e2e18 Updated email address 2014-01-20 15:19:38 -05:00
Joshua Sherman
9cc466bcd3 Module testing coverage 100% 2014-01-17 15:30:58 -05:00
Joshua Sherman
200988eecf Swapped all array() for the shorthand []
Also finished up coverage on the Cache class.
2014-01-15 14:09:54 -05:00
Joshua Sherman
8fc726b983 Updated copyright date.
It's a new year, figured it would be nice to get this done before summer time
like most years.
2014-01-05 13:44:25 -05:00
Joshua Sherman
64dc006b5f Documented some stuff, refactoring some other stuff
Moved re-used object instances to the Object class and added object loader logic to the constructor.
2013-12-30 15:47:13 -05:00
Joshua Sherman
19a211cf6a More refactoring, ditching old code
Added a new 404 system which checks for templates/__shared/404.phtml (module-less bare in mind) and falls back to a generic Apache-ish Not found page with PICKLES shout out. Added some more assumptions (login page is always /login a/k/a the login.php module) also there's no way to customize which template is used for the 404. Removed some code that was no longer used in the Security class.
2013-12-29 12:52:13 -05:00
Joshua Sherman
09d1744910 Refactoring old code
More like removing old code. Added some memento notes for myself in there.
2013-12-28 18:41:56 -05:00
Joshua Sherman
a050c7d031 Hacked in some public variables
Very hacky, switched variables to public and added a catch in the __get method to assign to the right place for the variables that modules are using (instead of having to update all of the modules in the wild)
2013-12-28 16:22:22 -05:00
Josh Sherman
07a95a7508 Built out new Display class with tests
Not hooked up to the Controller yet, wanted to get Travis setup.
2013-12-28 01:13:02 -05:00
Josh Sherman
d96181c60f Q4 2013, seemed like a good time to update the copyright notices 2013-11-04 17:36:04 -05:00
Josh Sherman
8f57077ef6 Created a validation class to handle validation
Instead of making the Module the keeper of validation, moved the actual sanity checks to another class. This makes it stupid easy to use one module's validation (some or all) to validate arbitrary values elsewhere in your system.
2013-09-29 15:51:45 -04:00
Josh Sherman
f2835252bd Fixed a typo 2013-09-08 18:30:14 -04:00
Josh Sherman
ae188a82a6 Added third option to determine if regex needs to match or not match.
Also fixed a bug where errors were overwriting eachother
2013-09-08 14:31:55 -04:00
Josh Sherman
94a9e08661 In module input validation logic 2013-09-08 13:56:07 -04:00
Josh Sherman
d25b042d8e Revert "Reworked Database stuff to be Datastore stuff"
This reverts commit ebd0018473.
2013-02-26 15:14:17 -05:00
Josh Sherman
ebd0018473 Reworked Database stuff to be Datastore stuff
Wanted a generic grouping for all datastores so there's a place for memcached and redis.
2013-02-26 10:15:52 -05:00
Josh Sherman
8fb7622061 If the module doesn't return anything, pass the return array instead
Now you can set variables in the module itself and have them returned to the template instead of needing to explicitly return the data. Will come in handy in scenarios where you've extended another module and want to retain it's return data. Previously you had to set a variable and then add to that and return it from the child class.
2012-10-14 18:08:27 -04:00
Josh Sherman
3c2c936cee Added fluid variable to the Module class
As a developer you still need to code for it (it's shown at work in the bootstrap) but you can use the variable to toggle fluid and fixed right from the module itself
2012-10-14 17:53:23 -04:00
Josh Sherman
553f70fdb8 Fixed issue with setting the template to false
Magic getter was overwriting the value because it was == null. Updated Module to check if the value isset() and if not, try to load from the config or set to false.
2012-10-13 12:04:02 -04:00
Josh Sherman
6f114361bd Updated copyright, website and contact email 2012-09-30 12:40:29 -04:00
Josh Sherman
3e58cd89bf Emptied the JAR and cleaned up some whitespace 2012-09-30 12:26:32 -04:00
Josh Sherman
4b96d28bb7 Added cache object to Model and cleaned up some variable names. 2011-10-30 19:24:23 -04:00
Josh Sherman
02c0eef632 Added caching flag to database. 2011-10-30 17:30:05 -04:00
Josh Sherman
996241debb Updated headers to have 2011 in the copyright date. Also updated copyright to my name as the LLC is currently defunct. 2011-05-09 22:14:55 -04:00
Josh Sherman
8fa5471aa7 Added private module functionality. 2010-12-09 22:52:26 -05:00
Josh Sherman
89e2c3db19 Cleaned up stray whitespace. 2010-12-09 20:12:05 -05:00
Josh Sherman
212843386d Added optional security hash check. 2010-11-26 02:43:41 -05:00
Josh Sherman
98e7f0fb34 Added optional request method checking. 2010-11-26 01:36:06 -05:00
Josh Sherman
14f0efbea0 Implemented secure variable in the module, removed request variable and will potentially add it back in at a later time. 2010-11-25 01:52:00 -05:00
Josh Sherman
d64251c098 Default parent template to "index" and added sanity check if template exists. 2010-11-12 23:03:18 -05:00
Josh Sherman
1cd61dda42 Updated licensing to use the [better suited] MIT License. 2010-10-14 20:12:40 -04:00
Josh Sherman
9fe5ce72d4 Building in security capabilities. 2010-10-06 00:01:49 -04:00
Josh Sherman
b210803e81 Added the Form class and updated the configuration arrangement. 2010-09-26 20:07:50 -04:00
Josh Sherman
6bd87d270d Refactored a bunch of the display logic, added handling to avoid the infinite redirect loop in the controller. 2010-09-19 19:13:11 -04:00
Josh Sherman
cab6641a96 After many years of using Smarty, loving Smarty and eventually hating Smarty, I've decided to remove it from PICKLES. The latest release candidates for the new Smarty 3 have not impressed me enough to keep it around, in fact peeping the code of the new version makes me think it should have never been included in the first place. May end up using Savant, may end up rolling a custom PICKLES solution, only time will tell. 2010-09-12 20:21:18 -04:00
Josh Sherman
a48706da4b Removed whitespace. 2010-05-15 22:51:17 -04:00
Josh Sherman
b1d7ef7645 Added better error handling
* Nice HTML output for errors

 * Cleaned up some @todo's while creating some new ones

 * Added a method for setting the request variable for the module that only the Controller can use

 * Fixed that nasty infinite loop, even though it's not ideal yet.
2010-03-28 23:05:46 -04:00
Josh Sherman
cda9c7d28e Implementing the Database class.
* Updated the Database class to work like a Singleton with a getInstance() method.

 * The Database class does not have a private constructor so it can still be instantiated in case someone needs to do so.

 * Replaced Logger class with Log class.

 * Updated Module to have an instance of the Database object as well as the Model class.

 * In my perfect vision for usage, the Module classes should never talk directly to the database, but do so via Models, but I know that's asking a lot, so I'm leaving in some options for folks.

 * Updated documentation.
2010-03-16 22:54:21 -04:00
Josh Sherman
a2073f71c4 Fixed typo in variable name
* Still had a lingering ->site when the interrogated variable moved to ->module.
2010-03-14 18:53:59 -04:00
Josh Sherman
efad51e92f Refactoring Display logic.
* Revamping the display logic, lots of code is being removed / streamlined.
2010-03-14 18:42:13 -04:00
Josh Sherman
7ae9569f59 Updated module variables some more.
* Defaulted all variables to null since false is a valid value for the variables.

 * Contemplating removing all of the variable declarations and changing the sanity check from == null to !isset(), although this would eliminate the nice documentation that is generated from the delcarations?  Maybe I can leave the comments and remove the variables?  Nah, seems hackey.

 * Updated getter to check the module section of the config instead of the site section of the config.  Just seemed to make more sense.
2010-03-14 15:59:55 -04:00
Josh Sherman
1e3c48d126 Updated Module variables.
* Moved variables from the public scope to protected.

 * Added magic methods to prohibit overriding the variables directly and to "magically" load config values when module variables aren't set.
2010-03-14 15:54:53 -04:00
Josh Sherman
7814b5dacb Updated @package name from pickles to PICKLES. 2010-03-12 23:42:21 -05:00
Josh Sherman
1f4d4acf94 Updated Module class.
* Set all variables to public for easier access from the Controller (easier than writing setter methods, meh.)

 * Added engine variable and defaulted it to PHP.
2010-03-11 23:32:50 -05:00
Josh Sherman
c2445d3a62 Removed Cache class.
* File was little more than just a stub file for the Cache class.

Removed Mailer class.

 * Attempting to remove non-critical classes from the system.

 * Class will be re-added / re-factored at a later date once the core of PICKLES is done.

Removed Security class.

 * Removing non-critcal classes from the system.

 * Security class was not very generic and will be replaced down the road once the security scheme is full realized.

Removed Form class.

 * Removing non-critcal classes from PICKLES to help the rewrite efforts.

 * Form class would take a database table and convert it into a webform.  Nice script, but really had no place in PICKLES.

 * Eventually will replace with a generic HTML form element generation class.

Added INSTALL file.

Updated derivation of the hostname.

 * Hostname is now defaulted in the class variable definition.

Refactoring Controller and Module
2010-03-11 23:19:33 -05:00
Josh Sherman
fab27b3332 Added the SILK icon set, also added the affiliate admin stuff.
git-svn-id: http://svn.cleancode.org/svn/pickles@110 4d10bc64-7434-11dc-a737-d2d0f8310089
2009-03-24 04:26:36 +00:00
Josh Sherman
466c35a6bb Massive update that broke backwards compatibility with older versions of PICKLES.
git-svn-id: http://svn.cleancode.org/svn/pickles@109 4d10bc64-7434-11dc-a737-d2d0f8310089
2009-03-19 05:07:20 +00:00
Josh Sherman
42e316fc05 Shit ton of updates.
git-svn-id: http://svn.cleancode.org/svn/pickles@81 4d10bc64-7434-11dc-a737-d2d0f8310089
2008-10-20 01:03:00 +00:00
Josh Sherman
b53f52ac1e Changes.
git-svn-id: http://svn.cleancode.org/svn/pickles@79 4d10bc64-7434-11dc-a737-d2d0f8310089
2008-10-18 13:42:10 +00:00
Renamed from classes/Model.php (Browse further)