Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/14/2019 in all areas

  1. This week we’ll take a look at LoginRegisterPro — a new module that provides an all-in-one, self contained module for providing new user registration, secure logins, profile editing, and more. It does this all in a manner that is reliable, efficient, comprehensive and secure. As we continue preparing the ProcessWire core dev branch to become our new master, I've been trying to stay hands-off on new feature additions there as much as possible (till the new master is out), and instead focusing on finishing up modules I've had in development. Last time I told you about the UserActivity module, and this time we’ll look at LoginRegisterPro, which is another module dealing with users; though significantly larger in scale/scope. LoginRegisterPro is a module I've been working on for more than a year, and finally this month have it ready to share. While I don't have it available for download today I do expect to have a beta release as soon as early next week. Read this week’s post for more details— https://processwire.com/blog/posts/login-register-pro/
    16 points
  2. @Robin S I agree and this is already in progress. It's not in the first version but is in the next one—here's the relevant section from the draft documentation:
    12 points
  3. @ryan, thanks for this new module - really looking forward to getting my hands on it! One important thing that I think is missing though is support for Image fields (the screenshots say no File fields and I figure this means no Image fields either). It's a really common need to allow avatar/profile images for members. A simple file input would suffice, but of course it would great to have things like preview before upload, front-end image resizing, and progress bar for upload (especially if front-end resizing isn't possible).
    6 points
  4. Sad to see you go, but this seems like a reasonable conclusion in your case ? Regarding your issue – I've never come across anything exactly similar myself. Since we're talking about the default multi-language site profile, there's very little data to load, so my initial guess would be that the request, or perhaps the PHP process, gets stuck somewhere. In the case of PHP the file compiler (core feature originally intended to ease migration from 2.x to 3.x) comes to mind – though that probably shouldn't be the case here – while disk based sessions could be another. Of course the database connection could also be the bottleneck, but if you're sure that it's configured properly, then I have no idea how it could be that slow. MySQL slow query log could help in ruling this issue out though. If you still want to debug this further, you might want to give database sessions a try (they can be enabled by installing the Sessions / ProcessSessionDB module, which is bundled with the core package), and just in case specifically disable the file compiler by setting $config->moduleCompile and $config->templateCompile to false in /site/config.php. I have no recent experience with Windows, so not sure if something there could cause the slowdown. That being said, I do know that others are running ProcessWire on Windows, so that alone shouldn't be a problem, unless it's some rather obscure configuration issue there. If other systems are working as expected then a configuration issue sounds less likely. While WordPress admittedly caters for a number of really unlikely borderline cases (including the use of the deprecated mysql PHP extension), Laravel working as expected probably means that the environment itself is properly set up.
    2 points
  5. Although the PW backend is really intuitive, ever so often my clients need some assistance. Be it they are not so tech savvy or they are not working in the backend often. For those cases it is nice to make some help videos available to editors. This is what this module does. ProcessHelpVideos Module A Process module to display help videos for the ProcessWire CMS. It can be used to make help videos (screencasts) available to content editors. This module adds a 'Help Videos" section to the ProcessWire backend. The help videos are accessible through an automatically created page in the Admin page tree. You can add your help videos as pages in the page tree. The module adds a hidden page to the page tree that acts as parent page for the help video pages. All necessary fields and templates will be installed automatically. If there are already a CKEditor field and/or a file field for mp4 files installed in the system, the module will use those. Otherwise it will create the necessary fields. Also the necessary templates for the parent help videos page and it's children are created on module install. The module installs a permission process-helpvideos. Every user role that should have access to the help video section, needs this permission. I use the help video approach on quite a few production sites. It is stable so far and well received by site owners/editors. Up until now I installed required fields, templates and pages manually and then added the module. Now I added all this logic to the install method of the module and it should be ready to share. The module and further description on how to use it is available on github: https://github.com/gebeer/ProcessHelpVideos If you like to give it a try, I am happy to receive your comments/suggestions here.
    2 points
  6. Hello All, This is just simple thought of mine over a simple a WordPress work I had to take recently. I am just discussing how I felt about WordPress is falling apart on the Content Management. My Article is here P:S :- My blog is still uses WordPress ?
    1 point
  7. It would happen to any fieldtype since filter() and not() methods are destructive. On the first call the $fields array ($productTemplate->fields) would contain all fields, after applying filter it would contain only filtered fields. On the second call of your function $productTemplate->fields does not returns all fields but only filtered fields ('FieldtypeText', 'FieldtypeTextLanguage', 'FieldtypePageTitle' and 'FieldtypePageTitleLanguage') and FieldtypePage is not among them. Use find() instead of filter() as it returns a new WireArray, this might work: if ($allowedFieldTypes) $fields = $fields->find('type=' . implode('|', $allowedFieldTypes));
    1 point
  8. Ah I see. I mistakenly thought you wanted to do a comparison. Yes, it does work. I was just wondering if it is a new PHP 7 feature or a PHP quirk. I am just used to count(array) or empty(array) Btw, did you see my edit above? The filter works fine for me with FieldtypePage check.
    1 point
  9. 1 point
  10. The current float sanitizer should have options like 'localeAware' (true/false) and 'decimalSeparator' (,/.)
    1 point
  11. Sure... tell more about you, your company, your sites, your needs... and there will be plenty of talented ProcessWire developers that like to help you.
    1 point
  12. BTW, when can we expect that to happen? Sounds like sooner than the end of December maybe? Is it going to be the first production ready version? Thanks for sharing all your hard work, and do not forget to ship it with a "Donation button".
    1 point
  13. Thank you very much for taking your time and putting this visual together! I don't really want to have icons next to the preview image because in future I might support selection of multiple images. Larger icon near the thumbnails might be a good solution. Also please understand, that I do not want to make this a hybrid between native image fieldtype and my fieldtype. The fieldtype now advertises that you can pick an image from another page. If it would also allow to upload to the page it lives on, it might become confusing to the user. If you want to stay consistent with the UI, it has ? To me it looks odd having icons from different libraries on one page or even across pages. As long as there is an icon available for the framework I am using, I always prefer that one over an alien one.
    1 point
  14. Happy to receive suggestions with visuals ? Thanks for the idea. In my experience users hardly ever use image tags. They'd be a good way to categorize thumbnails, though. Will think about some more how to best implement this. Maybe automatically categorize if tags are there. Don't want to offer another option for this to avoid clutter in the field settings. You sure do love panels ? Thank you! I thought about this option. 2 things that kept me from using panels: First, they don't offer hooking into close events easily out of the box like pw-modal. Second, in my opinion for this use case it is cleaner to have an overlay over the whole page. It is more distraction-free. But thank you for taking the time and demonstrating! Interesting thought. I'd say for those cases also offer a normal image field and then in your template render only the one that has content. What you describe sounds like a hybrid between normal image field and my fieldtype. Actually I am thinking a lot about how to best present the input for my fieldtype. And I'd love to use the standard image input from PW. Basically make my inputfield extend InputfieldImage or InputfieldFile and modify according to the needs. Only had a quick look and it involves quite a lot of changes to the original classes. It is on my personal wishlist and I will fiddle with it and see if I can produce something that makes sense and is usable without being confusing.
    1 point
  15. OK. However, my point was that multisite option #1 works with subdomains as well ?. Yes but to some extent No. Let me explain: Core Modules (e.g. AdminThemeUikit) will be physically shared between the sites since they live under wire/modules. By physical is meant the module files. However, optional core modules such as AdminThemeUiKit can be installed in some site-* but not others. Since site-* each have their own databases, site-a might have AdminThemeUikit installed whereas site-b might not. Install just means a reference to the installed module in a site's database. Custom modules, i.e. those that live in site-*/modules are not physically shared. Unless you are using symbolic links (which can be problematic!) each site-* will have its own modules folder. This means site-a/modules can have SomeModule and site-b/modules can also have the identical or same SomeModule. Of course, their respective databases will have references to their respective SomeModule. So, back to your problem. Did you physically copy AdminThemeUiKit to both your site/modules and site-stirnweiss/modules? This is in addition to the core copy in wire/modules/AdminTheme. If you did so, that is wholly unnecessary. If the answer is no, then you are experiencing a different problem, maybe a server configuration issue. It's hard to tell without more information about the 500 errors (apache logs, ProcessWire error logs, etc.
    1 point
  16. Just in case its useful for anyone, this is my function for creating a folder list with public links to files: <?php namespace ProcessWire; use Kunnu\Dropbox\Dropbox; use Kunnu\Dropbox\DropboxApp; use Kunnu\Dropbox\DropboxFile; $drop = $modules->get('DropboxAPI'); //Configure Dropbox Application $app = new DropboxApp($drop->app_key, $drop->app_secret, $drop->authorization_code); //Configure Dropbox service $dropbox = new Dropbox($app); // get folder from user $folder_path = ""; $folder_path = $user->folder; // get items from dropbox folder $listFolderContents = $dropbox->listFolder($folder_path); //root folder is the folder you nominated in the Dropbox App config. Refer doco $items = $listFolderContents->getItems(); function listItems($items, $dropbox, $depth = 0){ $out = "<ul class='depth-{$depth}'>"; foreach ($items as $item){ // get file name $name = $item->getName(); // getPathLower $path = $item->getpathLower(); $thumbPath = "no thumb"; $thumbHasExt = strpos($path, '.'); // file if($thumbHasExt && $path){ $file = $dropbox->getTemporaryLink($path); $link = $file->getLink(); $ext = substr($path, $thumbHasExt+1); // fontawesome file name icons $icon = "fa-file-o"; switch ($ext) { case 'png': case 'jpg': case 'gif': case 'psd': case 'tiff': $icon = 'fa-file-image-o'; break; case 'pdf': $icon = 'fa-file-pdf-o'; break; case 'mp3': case 'wav': $icon = 'fa-file-audio-o'; break; case 'mov': case 'mp4': case 'm4a': $icon = 'fa-file-video-o'; break; case 'doc': case 'docx': $icon = 'fa-file-word-o'; break; case 'xls': case 'xlsx': $icon = 'fa-file-excel-o'; break; case 'ppt': case 'pptx': $icon = 'fa-file-powerpoint-o'; break; case 'zip': case 'rar': $icon = 'fa-file-archive-o'; break; } $out .= "<li><span class='{$icon} fa'></span><a title='click to download' href='{$link}'>{$name} {$ext}</a></li>"; // folder }else{ ++$depth; $out .= "<li><span class='fa-folder-open-o fa'></span>{$name}"; $listSubFolderContents = $dropbox->listFolder($path); $items = $listSubFolderContents->getItems(); // get list of files in subfolder $out .= listItems($items, $dropbox, $depth); $out .= "</li>"; } } $out .= "</ul>"; return $out; } // get depth 0 folder items $out = listItems($items, $dropbox, $depth);
    1 point
×
×
  • Create New...