Jump to content

All Activity

This stream auto-updates     

  1. Past hour
  2. Using the module on a multi-language site. When saving a page, I get the following error: "Call to a member function setLanguageValue() on string", File: .../modules/SearchEngine/lib/Indexer.php:99 98: if ($index_field_exists) { 99: $page->get($index_field)->setLanguageValue($language, $index[$language->id]); 101: } I suppose we need a $page->of(false) here before calling setLanguageValue() ?
  3. Today
  4. Thanks for your replies guys! Here is the output when outputting all the debugInfo inside the JSON. What seems interesting to me is that every variation seems to refer to itself as the original? That could be something maybe? The weird thing is, I use this exact same technique on a lot of sites and never had this issue. So I would guess it's some configuration setting somewhere that might be off. { "image": { "name": "cirkels_oo.jpg", "description": [], "focus": "50% 50%", "original": { "src": "/site/assets/files/2823/cirkels_oo.jpg", "width": 300, "height": 240, "orientation": "landscape" }, "debug": { "L": { "thumb": "<img src='/site/assets/files/2823/cirkels_oo.jpg' style='max-width:120px; max-height:120px;width:100px; height:auto;' alt='' />", "files": { "original": "{SELF}", "basename": "cirkels_oo.jpg", "url": "/site/assets/files/2823/cirkels_oo.jpg", "filename": "/Users/eelke/Documents/Werk/Server/janvaneyck/site/assets/files/2823/cirkels_oo.jpg", "created": "2020-03-12 17:08:20", "modified": "2020-03-12 17:08:20", "filemtime": "2020-04-29 12:34:22", "suffix": "", "extension": "jpg", "filesize": 55446 }, "variations": [ "cirkels_oo.400x0.jpg", "cirkels_oo.1500x1500.jpg", "cirkels_oo.320x320.jpg", "cirkels_oo.750x750.jpg" ], "imageinfo": { "imageType": 2, "mime": "image/jpeg", "width": 300, "height": 240, "focus": null, "description": "", "tags": "", "orientation": 0, "rotate": 0, "flip": 0, "channels": 3, "bits": 8, "appmarker": { "APP0": "JFIF", "APP13": "Photoshop 3.0", "APP2": "ICC_PROFILE", "APP14": "Adobe" }, "iptcRaw": null }, "webp_copy": { "hasWebp": false, "webpUrl": null, "webpQuality": 90, "filesize": 0, "savings": 0, "savings_percent": 0 }, "engines": { "neededEngineSupport": "JPG", "installedEngines": { "ImageSizerEngineIMagick": "priority 0", "ImageSizerEngineAnimatedGif": "priority 0", "ImageSizerEngineGD": "priority 0" }, "selectedEngine": "ImageSizerEngineIMagick", "engineWebpSupport": false }, "options_hierarchy": { "imageSizerOptions": { "upscaling": true, "cropping": true, "autoRotation": true, "interlace": false, "sharpening": "medium", "quality": 90, "hidpiQuality": 60, "defaultGamma": -1, "webpAdd": true }, "individualOptions": { "sharpening": "medium", "cropping": false, "quality": 95, "forceNew": false }, "finalOptions": { "hidpiQuality": 60, "forceNew": false, "quality": 95, "webpQuality": 90, "webpAdd": true, "webpOnly": false, "cropping": false, "upscaling": true, "interlace": false, "autoRotation": true, "sharpening": "medium", "defaultGamma": -1, "cropExtra": null, "scale": 1, "useUSM": false } } }, "M": { "thumb": "<img src='/site/assets/files/2823/cirkels_oo.jpg' style='max-width:120px; max-height:120px;width:100px; height:auto;' alt='' />", "files": { "original": "{SELF}", "basename": "cirkels_oo.jpg", "url": "/site/assets/files/2823/cirkels_oo.jpg", "filename": "/Users/eelke/Documents/Werk/Server/janvaneyck/site/assets/files/2823/cirkels_oo.jpg", "created": "2020-03-12 17:08:20", "modified": "2020-03-12 17:08:20", "filemtime": "2020-04-29 12:34:22", "suffix": "", "extension": "jpg", "filesize": 55446 }, "variations": [ "cirkels_oo.400x0.jpg", "cirkels_oo.1500x1500.jpg", "cirkels_oo.320x320.jpg", "cirkels_oo.750x750.jpg" ], "imageinfo": { "imageType": 2, "mime": "image/jpeg", "width": 300, "height": 240, "focus": null, "description": "", "tags": "", "orientation": 0, "rotate": 0, "flip": 0, "channels": 3, "bits": 8, "appmarker": { "APP0": "JFIF", "APP13": "Photoshop 3.0", "APP2": "ICC_PROFILE", "APP14": "Adobe" }, "iptcRaw": null }, "webp_copy": { "hasWebp": false, "webpUrl": null, "webpQuality": 90, "filesize": 0, "savings": 0, "savings_percent": 0 }, "engines": { "neededEngineSupport": "JPG", "installedEngines": { "ImageSizerEngineIMagick": "priority 0", "ImageSizerEngineAnimatedGif": "priority 0", "ImageSizerEngineGD": "priority 0" }, "selectedEngine": "ImageSizerEngineIMagick", "engineWebpSupport": false }, "options_hierarchy": { "imageSizerOptions": { "upscaling": true, "cropping": true, "autoRotation": true, "interlace": false, "sharpening": "medium", "quality": 90, "hidpiQuality": 60, "defaultGamma": -1, "webpAdd": true }, "individualOptions": { "sharpening": "medium", "cropping": false, "quality": 95, "forceNew": false }, "finalOptions": { "hidpiQuality": 60, "forceNew": false, "quality": 95, "webpQuality": 90, "webpAdd": true, "webpOnly": false, "cropping": false, "upscaling": true, "interlace": false, "autoRotation": true, "sharpening": "medium", "defaultGamma": -1, "cropExtra": null, "scale": 1, "useUSM": false } } }, "S": { "thumb": "<img src='/site/assets/files/2823/cirkels_oo.jpg' style='max-width:120px; max-height:120px;width:100px; height:auto;' alt='' />", "files": { "original": "{SELF}", "basename": "cirkels_oo.jpg", "url": "/site/assets/files/2823/cirkels_oo.jpg", "filename": "/Users/eelke/Documents/Werk/Server/janvaneyck/site/assets/files/2823/cirkels_oo.jpg", "created": "2020-03-12 17:08:20", "modified": "2020-03-12 17:08:20", "filemtime": "2020-04-29 12:34:22", "suffix": "", "extension": "jpg", "filesize": 55446 }, "variations": [ "cirkels_oo.400x0.jpg", "cirkels_oo.1500x1500.jpg", "cirkels_oo.320x320.jpg", "cirkels_oo.750x750.jpg" ], "imageinfo": { "imageType": 2, "mime": "image/jpeg", "width": 300, "height": 240, "focus": null, "description": "", "tags": "", "orientation": 0, "rotate": 0, "flip": 0, "channels": 3, "bits": 8, "appmarker": { "APP0": "JFIF", "APP13": "Photoshop 3.0", "APP2": "ICC_PROFILE", "APP14": "Adobe" }, "iptcRaw": null }, "webp_copy": { "hasWebp": false, "webpUrl": null, "webpQuality": 90, "filesize": 0, "savings": 0, "savings_percent": 0 }, "engines": { "neededEngineSupport": "JPG", "installedEngines": { "ImageSizerEngineIMagick": "priority 0", "ImageSizerEngineAnimatedGif": "priority 0", "ImageSizerEngineGD": "priority 0" }, "selectedEngine": "ImageSizerEngineIMagick", "engineWebpSupport": false }, "options_hierarchy": { "imageSizerOptions": { "upscaling": true, "cropping": true, "autoRotation": true, "interlace": false, "sharpening": "medium", "quality": 90, "hidpiQuality": 60, "defaultGamma": -1, "webpAdd": true }, "individualOptions": { "sharpening": "medium", "cropping": false, "quality": 95, "forceNew": false }, "finalOptions": { "hidpiQuality": 60, "forceNew": false, "quality": 95, "webpQuality": 90, "webpAdd": true, "webpOnly": false, "cropping": false, "upscaling": true, "interlace": false, "autoRotation": true, "sharpening": "medium", "defaultGamma": -1, "cropExtra": null, "scale": 1, "useUSM": false } } } }, "L": "/site/assets/files/2823/cirkels_oo.1500x1500.jpg", "M": "/site/assets/files/2823/cirkels_oo.750x750.jpg", "S": "/site/assets/files/2823/cirkels_oo.320x320.jpg" } }
  5. Some client dont let to keep the credits, some do but however, you can see the source code - Meta author - Jeevanism@processwire http://bhimonlineclassroom.in/ http://onnippu.com/ http://www.kasitabusiness.com/ http://pkrosifoundation.org/
  6. can I follow the OP steps in 2020 ? or any thing altered now ?
  7. $news = $pages->find("template=news-article,sort=-publish_date, publish_date<$today,id!={$page->id}"); PS: if publish_date is a datetime field, then ProcessWire already knows 'today' (string) πŸ™‚.
  8. What's the best way to exclude the current page from results without resorting to filtering the results in a FOR LOOP. $news = $pages->find("template=news-article,sort=-publish_date, publish_date<$today"); In this example If I want to exclude the current page how would I do that? Is there a sibling reference?
  9. Hello, I tried to uninstall this module so I could test another, but I'm getting this error after uninstalling it. Based on what this error seems to be indicating, I made sure that I uninstalled TextformatterPrivacyWire first, before uninstalling PrivacyWire. But that didn't work either. Is there something else that I should be doing? I thought it might be ProCache, but I turned that off too. Please let me know. Thank you! Error: Exception: Module TextformatterPrivacyWire requires: PrivacyWire>=0.0.5 (in /usr/home/jc/public_html/test.com/wire/core/Modules.php line 1857 #0 /usr/home/jc/public_html/test.com/wire/core/Wire.php(383): ProcessWire\Modules->___install('TextformatterPr...') #1 /usr/home/jc/public_html/test.com/wire/core/WireHooks.php(823): ProcessWire\Wire->_callMethod('___install', Array) #2 /usr/home/jc/public_html/test.com/wire/core/Wire.php(450): ProcessWire\WireHooks->runHooks(Object(ProcessWire\Modules), 'install', Array) #3 /usr/home/jc/public_html/test.com/wire/core/Modules.php(1303): ProcessWire\Wire->__call('install', Array) #4 /usr/home/jc/public_html/test.com/wire/core/Modules.php(1194): ProcessWire\Modules->getModule('TextformatterPr...') #5 /usr/home/jc/public_html/test.com/wire/modules/Fieldtype/FieldtypeText.module(97): ProcessWire\Modules->get('TextformatterPr...') This error message was shown because: you are logged in as a Superuser. Error has been logged.
  10. Yesterday
  11. What exactly is the resulting settings or options here with the size call? Have a look at it with: https://processwire.com/api/ref/pageimage/get-debug-info/ // instead of // $img = $image->size($size["width"], $size["height"], $size["settings"]); // call $debuginfo = $pageimage->getDebugInfo($size["settings"], 'string'); // 'string' | 'array' | 'object' // and inspect the $debuginfo with Tracy or a var_dump()
  12. Hi @Greg Lumley, Implementing a "user admin" on the front-end isn't difficult because of PW's API -- In theory, that is. If you aren't familiar with PHP, or aren't familiar with the API, then it obviously will be a little more difficult. You can ask any questions here in the forum and a plethora of highly-skilled programmers will be glad to help. That's another big selling point with PW vs any other. The community support is second to none. The following is an example break-down of one of my sites. I have one site where specific users have the only permissions to access specific pages. All other users could only view pages. Think of it like the *nix RGE permission structure, where Root is super user, Group is any registered user, and Everyone else is a guest just visiting. PW initially gives you the Root and Everyone roles, so you will need to add the Group role. You can name it what you want. And since I don't let *any* user access the PW admin, I don't need to specify any permissions, such as page-edit, etc. I use Processwire's built-in page management to further limit a user to only their pages. Specifically, all pages have a created_users_id, and other information that is saved each time a page is created or updated. So when a user wants to create a new entry (page) their $user->id is assigned to the created_users_id property. Now I have a one-to-many relationship between a user and all of their pages. I also have different sections where a user can create a page. For example, when a user logs into my site acme.com, they can create a page under "high-explosives", and another page under "jet-powered devices". They may not wish to create a page under any other section. Each section has it's own template, so I can easily use selectors to retrieve the user pages by section, or even retrieve all pages. The front-end "user admin" interface is simply a two column layout with a menu on the left and the content on the right. I use the Group role to determine the menu options. I obviously don't want one user viewing details of another user, except for me as super user (Root). This also restricts the admin page(s) from view by the Everyone (Guest) role. I also have a drill-down capability from this initial user admin page to get more specific details. Each user can manage their own personal data page as well. That is the basic overview. The next thing are the modules. If you do not have your own login system then I would recommend LoginRegisterPro as it covers all the bases (register, login, forgot password, etc.) that you will need for your user access requirements. I am currently looking into implementing @bernhard's RockFinder3 module to handle queries because I have many users and they each have many pages and I want to be as efficient as possible. You must have TracyDebugger. That is a requirement (should be in core 😎 ). It will save you many hundreds of hours of scratchin' your head. You may elect to use other modules, such as caching, etc. These are just the minimum I would recommend for a project like yours. I hope this helps.
  13. @horst, if you have a chance, please look at the above? Sorry for pinging you like this.... πŸ™‚
  14. Hi Rick, I'd like it to be a front-end as in "user admin", so essentially a custom front end admin. If that makes sense. 😁
  15. Isn't it required in the new word of EU web bureaucracy to list every single cookie on demand (by category) and explain what is does, where it's from and can set it individually? So, for example, in the same example category "my user settings" I can agree to remember a "my selected language" cookie but not another cookie with "my last page visited"? As Borlabs cookie does it, or Klaro (kind of)? Am I wrong with my understanding of the current GDPR law situation? Or is this implemented already and I just did not find it? (Right now I am evaluation this module against using KLARO directy)
  16. @Robin S Dudeeeeee, you rock! It works like a charm. Didn't know there's such a thing!!!!! Thanks!
  17. When I look at the templates in the site via ftp it does not match what PW sees: The basic-page & session templates are missing from the ftp [yes, it has been refreshed].
  18. I have followed your instructions. There are now some data entered. When the tabs have not been selected: - the current site shows: <div class="accordion"> <div class="accordion-section"> <a class="accordion-section-title community-club" href="#accordion-1">Badminton</a> <div id="accordion-1" class="accordion-section-content" style="display: none;"> </div> </div><!--end .accordion-section--> </div> - whereas the original site shows: <div class="accordion"> <div class="accordion-section"> <a class="accordion-section-title community-club active" href="#accordion-1">Badminton</a> <div id="accordion-1" class="accordion-section-content open" style="display: block;"> <div class="row"> <div class="col-md-12"> <div class="session"> <h3>Huddersfield Eagles Junior Badminton Club</h3> <h4>Royds Hall Sports Centre</h4> <p>Sunday - 9:00am - 12:00pm</p> <p> </p> <p><a href="https://web.archive.org/web/20180815082939/mailto:enquiries@vivesport.co.uk?subject=Huddersfield Eagles Junior Badminton Club booking please" class="btn btn-primary" target="_blank">Book this session</a></p> Clicking the current version alters nothing. When the original is clicked and opened the code starts: <div class="accordion"> <div class="accordion-section"> <a class="accordion-section-title community-club active" href="#accordion-1">Badminton</a> <div id="accordion-1" class="accordion-section-content open" style="display: block;"> So, being a great detective [!!], the accordion isn't opening!
  19. After setting up a new user template using this guide: https://processwire.com/blog/posts/processwire-core-updates-2.5.14/#multiple-templates-or-parents-for-users, the pages are created fine but I can't log in as the newly created user. I did notice that my new template doesn't have a 'name' field like the users in admin/access/users. Is this the field that is checked when logging in? Here is my code that I am using to create the page when someone registers: $np = new Page(); // create new page object $np->template = $templates->get("user-hunt"); $np->parent = $pages->get("/members/"); // Match up the sanitized inputs we just got with the template fields $np->of(false); $np->name = $hunt_name; $np->title = $hunt_name; $np->member_hunt_name = $hunt_name; $np->member_hunt_contact_name = $contactname; $np->member_hunt_position = $position; $np->member_hunt_address = $address; $np->member_hunt_postcode = $postcode; $np->member_hunt_telephone = $telephone; $np->member_hunt_country = $country; $np->email = $email_address; $np->pass = $password; // Save the page $np->save(); $np->of(true); Also, when it creates the page, it's putting the title as the created date/time for some reason. 🀯
  20. No Your 'Our Sessions' page needs to have children for this (and the other similar) code to work: The children will be titled Huddersfield Eagles Junior Badminton Club, etc. In addition, those children: Need to use a template named session. That template (session) needs to have the following fields: session_type, session_day, session_venue, session_time and session_area
  21. Our Sessions No No, but it's template [sessions-page] does now. Text area It does now. Text No, there's one called 'sessions-page'
  22. Hi everybody, First time for me here to ask an help. So I apologize in advance for any section mistakes or forum rules not respected. I'm a newbie in PW, only 1 year working on it. I have a page with Date/Time pickers and they work perfectly, but I should have those in Italian (for safe editors that aren't so good with English). So I followed the translation suggestions founded in some old posts. Once setted the correct URL, the DatePicker are displayed in the right language, but I have an error on page saving: it seems that the field doesn't register the date/time change from the older language. The same problem occurs if I create a new page, not only changing the old ones. May I have missed something? Thanks a lot in advance.
  23. @Mamun Paul, this is a double post (https://processwire.com/talk/topic/9711-map-marker-map/?do=findComment&comment=202283) and also not related to module development, so I'm closing this thread. One topic per issue, please.
  24. Hey @montero4, First of all, just wanted to say that I really need to figure out some way to handle these conflicts with Hanna Code β€” it's becoming a common issue. I'll see what I can do about that soon πŸ™‚ Technically there's nothing wrong in your code. It will work just fine on the front-end, where it's really intended to run. The problem is that in order to get useful index out of field content, SearchEngine actually gets it via $page->getFormatted(), which means that TextFormatters (such as Hanna Code) will also run in the admin side. In this case you're using $pages->get() to get another Page, and since the default in the admin is that output formatting is off, this means that this new Page will have output formatting disabled β€” and that's why $page->image actually returns an instance of Pageimages (instead of a single Pageimage). ... anyway, just wanted to explain what's going on in here πŸ™‚ Right now the easy fix would be checking for the type in the Hanna Code snippet. (Again, I'd like to automatically handle this in SearchEngine, but I can't say for sure when I'll get to that.) $page=$pages->get($id); //gets the page $image = $page->image instanceof Pageimages ? $page->image->eq(0) : $page->image; $image = $image->width(1240, ["suffix" => "srcset"]); //create image that is 1200px wide Alternatively you could make sure that output formatting state is on β€” it's mostly a matter of taste, really: $page=$pages->get($id); //gets the page $of = $page->of() // store initial output formatting state for later use $page->of(true); // make sure that output formatting is on $image = $page->image->width(1240, ["suffix" => "srcset"]); //create image that is 1200px wide $page->of($of); // restore initial output formatting state
  25. I've upgraded Processwire from 2.8 to 3.0.148 and also upgraded map marker module to 2.0.9 Still on the admin sub location maps are not visible on page load on chrome. Need to double click then it appears. While on Mozilla it works fine. Why this is happening?
  26. Big fan of the implementation of this. I was still using soma's Module Manager with a quick hacky fix for the lack of pagination support. I am having an issue, however - when selecting the "Show All" category, it just shows nothing. Permanently. From what I can tell, it's not even sending an XHR request which is probably part of the problem. πŸ˜› (For reference, I'm using PW version 3.0.158 dev) If that could be fixed, it would basically be perfect, imo. Edit: And I do agree with @Peter Knight about using a select rather than radio, and "Active" and "Inactive" seem to have more obvious meanings than "show only uninstalled", imo.
  1. Load more activity
Γ—
Γ—
  • Create New...