Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/01/2016 in all areas

  1. @Mats @gebeer Thanks to a job I just finished for @dab I have been actively taking your work forward. I have a fork of the project here that... Simplifies getting the needed files used by MarkupLeafletMap into a template's header Integrates the Leaflet.AwesomeMarkers project and the latest FontAwesome icons into the module Adds a callback function for customising the content's of a marker's popup box Adds a callback function for customising the visual appearance of any marker Updates the readme file significantly Provides an example template file to help get folks underway with this module in their projects I based my work on gebeer's extension of your repo Mats, so I have issued a pull request to gebeer - but I'd like to get these changes into your repo if possible as then we can revert to your repo as the master codebase and, hopefully, have the latest goodies straight from the PW module directory. It's now very easy to add fields to the marker pages that let you customise their appearance. Below I have added an Options field, a FieldtypeFontIconPicker and a Text field to control the marker visuals via the added callback. If anyone want's to try it out, here is the link to the zip file.
    9 points
  2. Media Manager version 004 (released (01/08/2016)) Happy to announce the latest release of Media Manager. Changelog FieldtypeMediaManager/InputfieldMediaManager: Configurable setting to insert media in inputfield and close modal. Set in the Details tab of your FieldtypeMediaManager field Fixed bug where non-allowed media types (for those limiting media types available to InputfieldMediaManager) would still show up in the results in the selection modal. Fixed bug where the menu item 'All' would not appear in the InptufieldMediaManager media selection modal even if allowed media types was limited to at least 2 types By popular demand, a CKEditor image plugin! mmimage (cloned and adapted from pwimage thanks @ryan) lets you insert images in your Media Manager Image Library directly into the rich text editor. See a video demo + instructions here @TODO: Multi-tagging of media Documentation (thanks for being patient with me guys...)
    4 points
  3. Did you view the website in an incognito screen/private mode to make sure you are not logged in by accident?
    3 points
  4. The latest post includes coverage of weekly updates to the ProcessWire core, as well as a look at how to create your own custom utility hook functions… https://processwire.com/blog/posts/pw-3.0.28/
    3 points
  5. the profile itself has a $useDone variable, so you can also just set that to false and load your alternate file. /* * Whether to include the _done.php markup file? For example, your template * file would set it to false when generating a page for sitemap.xml * or ajax output, in order to prevent display of the main <html> document. * */ $useDone = true; in other scenarios you can stop what happens after the template by using: return $this->halt(); so therefore you could use wireRenderFile, or include/wireIncludeFile your alternate file, and then prevent loading _done by halting.
    2 points
  6. Thanks for the report - that was introduced only a couple of versions ago. I think it should be fixed in the latest version - please test and let me know.
    2 points
  7. @mr-fan if you are still having the problem from with geocoding from your custom fields, maybe my modified InputfieldLeafletMapMarker.js gist can help. I have a custom button in the form that triggers the geocoding, defined on line 48 and a fucntion from line 135 that takes values from custom fields, concats them and does the geocoding.
    2 points
  8. Thanks @netcarver and @dab! I'll update the code with your additions @netcarver.
    2 points
  9. 2 points
  10. Well, the first srcset (360,null) shouldn't be null, but perhaps this isn't the problem. Lazysizes uses the largest image even if you resize the browser. So if the page loads in desktop size, and you downsize it to 400px wide, it won't load the smaller images. In my tests it works only upwards (from small to large size).
    2 points
  11. Dynamic Selects Released 27 July 2016 Dynamic Selects is a commercial module that enables the creation of dynamically related/dependent ajax-driven chained dropdown lists (aka cascading selects) for display and storage of multiple types of data. The module can be used both in the front- (display only) and backend (display and storage of data). Setting up Dynamic Selects is very easy. With minimal effort, site developers can set up simple or complex chained selects. By making a selection in a trigger dropdown, via ajax, values are fetched and dynamically populate options in the dependent select. In turn, making a selection in the now populated select triggers the same action further down in a dependent select. The module only uses/stores ID references to selected options in the selects meaning the most current/up-to-date data will always be displayed in the selects. Currently only ProcessWire managed data are supported. If there is enough demand, we may incorporate external data sources (typically JSON). The module consists of 4 modules ProcessDynamicSelects MarkupDynamicSelects FieldtypeDynamicSelects InputfieldDynamicSelects Video Demo: https://youtu.be/wkhx8xQ5ue4 Documentation: http://dynamicselects.kongondo.com/ Shop: https://processwireshop.pw/plugins/dynamic-selects/ Requires: ProcessWire 2.5 or newer and jQuery if using the frontend module (MarkupDynamicSelects) Features Easily create powerful ajax-driven cascading/chained selects/dropdowns Unlimited number of select dropdowns per field Data-mapping made easy thanks to multiple possible combinations of data relationships, triggers and sources Mutlipe data relationships to chose from ID-based data referencing ensures your data values always stay fresh Remote and local caching to speed up data access and reduce ajax-requests to server User-friendly, intuitive and easy to set up IMPORTANT Before using this module in the frontend, you will need to thoroughly read the security section in the documentation.
    1 point
  12. What does autojoin do? Using the 'autojoin' optimization can increase performance on fields that get used a lot. Not using it can reduce the page's memory footprint. What is more desirable in each instance depends on your situation. What sites should use autojoin? Autojoin is most applicable with larger sites. On smaller sites, there may be no benefit to using it or not using it. But it's good to know what it's for regardless. Where do you control autojoin? Autojoin is controlled per-field. You can turn it on by editing each field under Setup > Fields > [your field], and you'll see it under the 'Advanced' heading. When should you use autojoin? Autojoin causes the field's data to be loaded automatically with the page, whether you use it or not. This is an optimization for fields that you know will be used most of the time. Fields having their data loaded with the page can increase performance because ProcessWire grabs that data in the same query that it grabs the Page. Autojoin is a benefit for fields that are always used with the Page. This is best explained by an example. Lets say that you have a template for individual news stories called news_story. The news_story template has these fields: title date summary body sidebar We'll assume that when you view a page using the news_story template, all of the fields above are displayed. Fields that should have autojoin ON: Now consider a separate news_index template that displays ALL of the news stories together and links to them. But it only displays these fields from each news story: title* date summary In this case, the 3 fields above would be good to autojoin since they are used on both the news_index and news_story templates. If your title, date and summary fields didn't have autojoin turned on, then ProcessWire wouldn't go retrieve the value from the database until you asked for it it (via $page->summary, for example). Because the news_index template displays all the stories at once, and always uses the title, date and summary fields, it will perform better with title, date and summary having autojoin ON than with it OFF. In this case, it reduces the query load of the news_index template by 3 for each news story. To take that further, if it were displaying 20 news stories, that would mean 60 fewer queries, which could be significant. Fields that should have autojoin OFF: Now lets consider the body and sidebar fields, which are only used on the news_story template: body sidebar It would be desirable to leave autojoin OFF on those fields because there is no reason for the body and sidebar to be taking up space in memory when they are never used on the news_index template. While it might mean 2 fewer queries to view a news story, that is not significant and certainly not a worthwhile tradeoff for the increased memory footprint on the news_index template. Keeping autojoin OFF reduces a page's memory footprint. Conclusion Using the 'autojoin' optimization can increase performance on fields that get used a lot. Not using it can reduce the page's memory footprint. What is more desirable in each instance depends on your situation. But if your situation doesn't involve lots of pages or data, then you don't need to consider autojoin at all (and can generally just leave it off). Additional Notes Not all fields have autojoin capability. You won't see the option listed on fields that don't have the capability. *The title field has autojoin on by default, so you don't need to consider that one. It was included in the examples above because I thought it's omission might cause more confusion than it's inclusion. Be careful with multi-value fields that offer autojoin capability (page references and images, for example). Because MySQL limits the combined length of multiple values returned from a group in 1 query, autojoin will fail on multi-value fields that contain lots of values (combined length exceeding 1024 characters). If you experience strange behavior from a multi-value field that has autojoin ON, turn it OFF. If you want to play it safe, then don't use autojoin on multi-value fields like page references and images.
    1 point
  13. There have been a few issues raised here in the forums that seem to relate to SQL mode settings. There is nothing stated on the requirements page about SQL mode but it seems that certain mode settings can cause problems, and maybe even settings that are now enabled by default in MySQL 5.7. Might be a question for @ryan, or does anyone else know: What are the SQL mode requirements for ProcessWire?
    1 point
  14. Is working here on a massive setup for blockbuilding....no affect so far.
    1 point
  15. If you got a csv of your products from Magento it is pretty easy to import them with ImportPagesCSV. Read the instructions and posts in the topic. Your process comes down to your data structure. It depends on how to current Magento structure is set up. For example: does a product lives in one branch or in multiple? It makes a lot of difference when you want to import. My advice would be to map out all the data and create all the fields in your ProcessWire template. Then export/import the category structure. After that I would import the products (including category).
    1 point
  16. http://stackoverflow.com/questions/930900/how-to-set-time-zone-of-mysql
    1 point
  17. @netcarver Awesome work, thank you so much for sharing!
    1 point
  18. 1 point
  19. @LostKobrakai CAN, but the built in modal is really nice on mobile. it gets 100% width/height and has a really native feeling. at least for standard page edits.
    1 point
  20. Great job! Is or will it be possible to use this as a frontend module? Thanks!
    1 point
  21. I'm afraid I'm lost somewhere in between I was talking about the existing page list but prepending a small thumbnails to the items, not a thumbnail-only page list (there's a module for that as I know). I don't plan to add the latter because that would require much modifications and it's not the purpose of AOS. To make this pagelist compact with the thumbnails, I will see how usable it is with smaller thumbs but I'm not sure that would make much sense (thumbs were too small).
    1 point
  22. If you have a composer dependency than go ahead and use composer. I'd just not use it just as the autoloader.
    1 point
  23. Just for the sake of completeness; the Fatal Error is not related to Tracy, so I even get it with the option No (disabled compiler) too. Edit: one of the template files was missing "namespace Processwire;" so that is why wireRenderFile() was not found.
    1 point
  24. hi nico65, welcome to the forum! seems you want to achieve something like this? removed because i reached my attachment size limit Have a read about FREDI and FEEL the screencast above is a simple module made by me and not officially released yet, called ALFRED: you can try it out if you want. the source is here: https://gitlab.com/baumrock/Alfred/tree/dev
    1 point
  25. @adrian Hello Adrian, I have an issue to report, Error: VariablesPanel: This is my setup: Ghost Blog Clone by clsource: ProcessWire 3.0.28 and Tracy Debugger 2.5.4 so everything is the latest. In order to get the list of variables defined in the template file, I tried to turn on the compiler for the home template, based on this info: https://processwire.com/blog/posts/introducing-tracy-debugger/#non-processwire-template-variables-panel Home template: first I chose "Yes (template file and files included from it)". The result is what you can see in the spoiler. Next, I chose "Yes (template file only)" and in this case the result is even "worse", Fatal Error - undefined function wireRenderFile(): So this is a multilanguage setup, upon which I will probably build my future ProcessWire projects, so it will be nice to sort these out if possible. Maybe I'm missing something? Thanks in advance.
    1 point
  26. 1. Create all the fields you need relating to a single car. One field you don't need to create is "Title" because that is a global field that exists by default. 2. Create a template "car". To this template add the fields you created in step 1. This is the template that will output the fields for a single car. 3. Create a template "cars". This is the template that will output the list of cars. If it only outputs the list of cars it may not need any fields added to it apart from the default "Title". 4. Create a page "Cars" that uses the template "cars". 5. Create a child page of "Cars" for your first car that uses the template "car". Fill out the fields. Repeat this step for all your cars (see end of post for a time-saving tip). 6. Create template file "car.php" in /site/templates/. In this file output your fields as needed, getting each field as $page->my_field_name 7. Create template file "cars.php" in /site/templates/. In this file you will get a PageArray of all the cars and then loop over them to create links to the individual car pages. // get PageArray of all cars $cars = $pages->find("template=car"); // in this example you could also get $cars with: $cars = $page->children(); // Output list of links... if(count($cars)) { echo "<ul>"; foreach ($cars as $car) { // $car is the Page object for an individual car // You can get any field of the car with $car->my_field_name echo "<li><a href='{$car->url}'>{$car->title}</a></li>"; } echo "</ul>"; } Time-saving tip: you could import data for your car pages in bulk from a CSV using this module.
    1 point
  27. You can filter the notices with a hook before Page::render in /site/ready.php The file compiler notices are useful information so probably sensible to filter these notices only for non-superusers. $this->addHookBefore('Page::render', function($event) { $user = $this->user; if(!$user->isSuperuser()) { $notices = $this->notices; $notices->not("class=FileCompiler"); $notices->not("text~=Compiled file"); } });
    1 point
  28. @gebeer...in case it's still of interest to you, I have released a commercial dependent select module.
    1 point
  29. The French example seems to make sense, but as far as I can tell, English versions make more sense when the apostrophe is removed: lets-go vs. let-s-go, havent-been-there vs. haven-t-been-there, adrians-suggestion vs. adrian-s-suggestion, etc. I'd suggest going with Adrian's suggestion above.
    1 point
  30. Can't you add it to the Character Replacements list in the Page Name config settings: /module/edit?name=InputfieldPageName
    1 point
  31. The issue mentioned above was related to a recent change in the core class InputfieldWrapper. I've just created an issue for this to the ProcessWire repository in GitHub (https://github.com/ryancramerdesign/ProcessWire/issues/1936) and updated VersionControl to circumvent this issue. If you update the module to the latest version, it should work again. Sorry for the inconvenience! /cc @diogo, @ceberlin, @Zeka
    1 point
  32. What are the values of : IdleTimeout ProcessLifeTime FcgidMaxRequestLen FcgidIOTimeout ?
    1 point
  33. I suspect there are two types of backend development perspectives: modifying the appearance and functionality of the PW interface itself (aka admin themes), or creating highly-customised listing/editing/configuration pages. I've always regarded the existing PW backend as the place for superusers/developers only. A separate backend should be developed for users/editors/authors who wish to edit their own content and adjust basic settings related to how they interact with the frontend. This as opposed to something like Wordpress where the backend is usually quite suitable for all types of users from mere subscribers all the way up to admins. I mean, let's say you use PW to build a site where users can edit their own content. It seems much cleaner to provide a custom edit area, themed identically to the frontend, than to drop users into the PW backend even though you've hidden all the stuff the user doesn't have permissions for. That being the case, backend devlopment is nothing more than an extension of frontend development with robust auth/permission checks. I'd like to see tutorials on the pitfalls and best practices of that type of narrow, highly-customised admin area. Further, I concede there's a crossover between user-centric admin areas and a fully-exposed backend. I may be at cross purposes with the OP.
    1 point
  34. Turns out #MyTabs needs to be a form. Then it works. Seems hacky - I don't need a form...
    1 point
  35. InputfieldWrapper is the base class for a Form, Fieldset or Tab (InputfieldForm, InputfieldFieldset, etc.) It implies an Inputfield thats purpose is to contain other Inputfields. While Forms, Fieldsets and Tabs represent specific things, a regular InputfieldWrapper just acts as a wrapper/container for Inputfields, without any kind of visual representation. Because it is a type of Inputfield, it can take the place of a single Inputfield, while actually containing many of them.
    1 point
  36. Just checking: you've tried creating output (into a variable, such as $out = "my markup goes here") and returning that variable (return $out), not just echoing it out directly.. and it doesn't work? It definitely should, so I'm guessing there's something weird going on. If you could post some sample code that causes issues, I'd be happy to take a closer look. Answer to your non-intended question is that you'll still have to render some inputfield markup there. This is probably easiest to explain with some code. Example below will output "my value" first, then render any inputfields this wrapper contains (in this case just one markup inputfield with value "some markup.") $wrapper = new InputfieldWrapper; $wrapper->attr('value', 'my value'); $inputfield = new InputfieldMarkup; $inputfield->value = "some markup"; $wrapper->add($inputfield); echo $wrapper->render();
    1 point
  37. Add this to your head. <script> var config = {"JqueryWireTabs": {"rememberTabs": 0}}; </script>
    1 point
×
×
  • Create New...