Jump to content

Stikki

Members
  • Content Count

    53
  • Joined

  • Last visited

Community Reputation

45 Excellent

About Stikki

  • Rank
    Full Member

Contact Methods

  • Website URL
    http://i-do-this.com/

Profile Information

  • Gender
    Male
  • Location
    Finland

Recent Profile Visitors

4,078 profile views
  1. Howdy, i was just wondering if there is already workaround in core that would automatically sniff for composer.json up on module installation and install dependencies? What i'm currently doing is that i include vendor folder into modules, but somehow this feels stupid as of core could just handle this part up on module installation and place dependencies under ROOT_PATH/vendor/? i tried quickly to look around for previous posts about this topic, but couldn't find anything. Cheers!
  2. Or get + set combined: $data = $cache->get('my-key', WireCache::expireHourly, function() { return []; // return array (for example), if returns absolute false, won't get cached. });
  3. So, tell me am i stupid or isn't system just handling this? What i'm doing: // Save record locally $record->save(); $record = $pages->get($record->id); // Reload record to refresh database columns, stupid i know! -- But it seems that i have to reload page data to acquire some properties from database, even tho i would expect $pages->save() method to handle return values to $page object ($record in my case). So system just ain't handling this, or am i missing something? Thanks everyone!
  4. Where do i get? From here: https://github.com/IDT-media/IntegerAutoIncrement What does this do? Adds additional option to Fieldtype Integer to make it auto increment. How to use? Simply install this module, Create / Modify Field that is Integer, set auto increment on/off. Enjoy!
  5. So this is turning another Drupal? Shame.
  6. Howdy dragan, Will look into this matter when i start testing with 3.x series, haven't touched that yet. And what comes to Matrix repeater, it only works with standard fields currently, special fields would require own checkpoint, and since haven't used Matrix repeater myself yet, there is no check for that. You can always hook to getValue() method and implement you own check without hacking module.
  7. My solution was following: function t($text) { return include(wire('config')->paths->templates . '_translations.php'); } _translations.php: <?php $translations = []; $translations[$text] = _x('String', 'General'); return $translations[$text]; This to avoid actual function file to be translatable at any point + better access for strings overall. EDIT: Actually, this was good idea, but ain't working Sorry about posting, back to drawing board.
  8. Thanks for the confirmation Wanze, this is exactly what i meant. Cheers also.
  9. Thank you again Mr. Kobra Danke
  10. And more stuff follows: Is there full documentation what stuff method: getModuleInfo() can return? Documentation says: * 1. Using a static getModuleInfo method: * --------------------------------------- * * public static function getModuleInfo() { * return array( * 'title' => 'Your Module Title', * 'version' => 100, * 'author' => 'Ryan Cramer', * 'summary' => 'Description of what this module does and who made it.', * 'href' => 'http://www.domain.com/info/about/this/module/', * 'singular' => false, * 'autoload' => false, * 'requires' => array('HelloWorld>=1.0.1', 'PHP>=5.4.1', 'ProcessWire>=2.4.1'), * 'installs' => array('Module1', 'Module2', 'Module3'), * ); * } while example in ProcessCommentsManager.module: public static function getModuleInfo() { return array( 'title' => 'Comments', 'summary' => 'Manage comments in your site outside of the page editor.', 'version' => 5, 'author' => 'Ryan Cramer', 'icon' => 'comments', 'requires' => 'FieldtypeComments', 'permission' => 'comments-manager', 'permissions' => array( 'comments-manager' => 'Use the comments manager', ), 'page' => array( 'name' => 'comments', 'parent' => 'setup', 'title' => 'Comments', ), 'nav' => array( array( 'url' => '?go=approved', 'label' => __('Approved', __FILE__), ), array( 'url' => '?go=pending', 'label' => __('Pending', __FILE__), ), array( 'url' => '?go=spam', 'label' => __('Spam', __FILE__), ), array( 'url' => '?go=all', 'label' => __('All', __FILE__), ) ) ); } So are 'page' and 'nav' part of Process Module interface, and if so, where can i read about this?
  11. Okey, then again * Optional methods for Module interface * ===================================== * 1. __construct() - called before module config is populated. * 2. init() - called after module config is populated. * 3. ready() - called after init(), after API ready. * Note that ready() applies to 'autoload' modules only. * 4. ___install() - called when module is installed. * 5. ___uninstall() - called when module is uninstalled. While method header says: * While the method is required, if you don't need it, then just leave the implementation blank.
  12. Howdy howdy, I was reading stuff about module interfaces init() method and it's declared as required method while being only documentational guidance with in interface. Even all loading methods that i see are checking against existence of this method and executing it only if it's present. So my question: is this actually required method anymore? If not, documentation needs some update.
  13. It should reset $to on each iteration as you initialize wireMail over and over again, but if it doesn't try: $mail->to(); which should reset recipients list before adding more recipients into list.
  14. Yeah baby, this is what i wanted. I love ya! This system dosen't stop amaze me day after day. Cheers for your answer
  15. Howdy again, Is it possible like have virtual directories? With this i mean that when i have Users listed on frontend under members page (actual page with FE template), is it possible to list users from under admin/access/users virtually, so it would be a bit more user friendly to edit these users (if access) directly under members tree? Can't move users as admin template is required, not that this would be good idea anyways, so was just wondering if this kind of "dual" behavior is somehow possible where Lister would consider having virtual child elements under this template. Anyways, thanks again for possible answers
×
×
  • Create New...