Recently Browsing 0 members
- No registered users viewing this page.
Hi there, I'm hoping someone can help here.
I've just moved a new site from my development server account over (where the site was working fine for the client to edit content pre-launch) to the client's final hosting account and the live site is all fine. However, while most edits can be done without an issue, image uploads in admin cannot. I know this has been an issue before but, having trawled the posts about it and suggested esolutions I still can't resolve it on their host.
PW Version: 3.0.123
PHP version: 7.3.20
GD Library is enabled
Looking at the console data it looks like the AJAX request from the image upload is getting a 403 error which is suggesting a permissions issue? First we get this on console:
?id=1169&s=1&c=1:1 Uncaught SyntaxError: Unexpected token < in JSON at position 0 Then, the AJAX request:
https://*******/admin/page/edit/?&id=1169&InputfieldFileAjax=1 Gets a 403 according to Chrome Dev Tools > Network XHR. Also, the response is empty.
Can anyone point me in the direction of the directory that deals with this and what the permission should be to allow it or indeed any other fix / area to investigate?
Thanks so much for your help.
Hi everyone, I'm happy to present my latest project, which is a collection of guides and tutorials for web development with ProcessWire written by me.
What is this?
I have written several tutorials in this forum, and I wanted a central place to collect all my tutorials and put them in a logical order. processwire.dev is exactly that, a curated list of tutorials for different topics related to ProcessWire development. I have revised, updated and expanded most of my existing tutorials. There are also some completely new tutorials.
How to integrate Composer in your ProcessWire sites, and a general explainer for namespaces and autoloading. A two-part guide to using Twig with ProcessWire and adding custom functionality. How to create flexible content modules with Repeater Matrix fields and Twig. A general guide to performance optimization for ProcessWire. A starter guide for the "ProcessWire mindset" - how to structure your content. ... and much more! What's next?
I hope this will be a useful resource to all of you fine people. Please note that these tutorials are very much opinionated, and they reflect my personal experience and development practices. So if you disagree with some of my conclusions, that's perfectly fine! I'm happy to discuss all my recommendations and approaches with you, so let me know if you have any feedback, suggestions or error corrections!
I plan to expand this resource over time and already have some new topics planned. If you have suggestions for new topics, go ahead and post them here as well!
Start reading now: processwire.dev
Hello, I finished this toy project. A simple API to show data for Chilean Birds.
Used to flex my PW and React muscles, since a lot of time has passed since making something with those techs.
Frontend (React): https://aves.ninjas.cl
Backend (PW): https://aves.ninjas.cl/api
Hope you like it 🙂
By Kiwi Chris
I don't really have anything public to show, as nearly all the work is back-end, but I thought I'd post here anyway as it's a pretty good example of just how powerful Processwire can be.
About a year ago, I inherited an incomplete Craft website made by a designer. Apart from the usual company information site, it was supposed to provide a customer portal for clients of a wine bottling company to make bookings for production runs.
Data for stock levels of goods like bottles and labels was to come from an inventory management system Unleashed https://www.unleashedsoftware.com/
Unleashed provides a REST API, so I had to integrate with that first by writing an API integration module, and then ended up using Processwire's core lazy cron module to periodically pull data from Unleashed using a custom module.
The booking forms have a lot of conditional fields, eg if you are bottling a given wine variety, you should only be able to select labels that match that variety. All this conditional stuff was achieved with a lot of additions to ready.php.
I also needed to be able to created a predefined set of pages when a new user is added if they have a 'client' role. Once again, more hooking in ready.php
I've used the Admin Restrict Branch module so clients can only see their own records when they're logged in, but staff can see all records.
Lister Pro provides the ability to search and view completed production runs.
Part way through the project, as the client was happy with the way things were going, I was asked to add in logistics and dispatch which is provided by another company, which also runs Unleashed with a separate set of data, and with some clients who don't bottle wine, but will end up using the same portal, so using the roles and permissions inherent in Processwire, I set up production templates with separate roles to dispatch templates, so I could easily have clients assigned access to just the templates they need.
Tracey Debugger got a thorough workout along the way, and the debugger console is an absolute killer tool for making quick changes to data when updating a live site to match changes from the dev site.
At the start of this project, I'd used Processwire quite a bit, but never dived into module development or hooking, but I've now ended up with a reasonable idea how they work.
@bernhard has produced some excellent tutorials which I found really helpful figuring out how to create modules, and other people like @Robin S have answered questions when I've got stuck. @ryan himself has been helpful when I've been trying to do things that push either the limits of my knowledge or Processwire or both 😋 .
Could I have done this with other tools? Depends. Wordpress would have been as useless as using petrol to fight a fire, however something like ASP.Net COULD have done the job but would have probably made things a lot more complicated. In parallel, I've been working on building a REST API with ASP.Net for another client to integrate with an existing SQL Server database, and I've found that Visual Studio is inclined to break projects quite regularly, with dependencies getting messed up, or even whole configuration files getting corrupted when it has a hissy fit, so working with Processwire is a pleasure in comparison.
By Kevin C. McCarthy
For some background, I'm great with WordPress and I'm great with writing websites by hand with Notepad only. The biggest hurdles I have with PW is the phrasing is so far left of WP at times that it's a massive hurdle for me to get over. Like in WP, themes, templates, etc are totally different things. And as someone who builds WP sites for a living, it gets hard to kill those old preconceived meanings.
I want to start building out PW sites for numerous reasons. For one, most of my clients they would benefit from it vs the Bloated Beast. Two, it would allow me to differentiate me in a market saturated by WP devs. I know I have a long ways to go until I reach that point of considering myself a "PW dev", but I am desperate for resources to help me wrap my head around it.
I've built my own website in PW but TBH it only handles some of the data while most of the text has been hard-coded into the PHP template files because I couldn't get my my head around the "best practice" of structuring the data.
Anyway, enough rambling, I'm just hoping those of you in the community can point me to easily-digestible sources out there that can help move me along so I can actually benefit from using the platform. Thank you!