-
Posts
1,556 -
Joined
-
Last visited
-
Days Won
19
Everything posted by Peter Knight
-
Some updates to the Processwire / Cursor MCP Module. But first a recap (composed by Cursor) ProcessWire MCP — 360 Content Sync Between Cursor and Any ProcessWire Site With this Cursor MCP module for ProcessWire, you can say "Pull the about page, update the intro, and push it to production" — and Cursor does exactly that. No CMS login, no FTP, no copy-paste between environments. The module gives Cursor full read and write access to any ProcessWire site — local or remote — via a secure API. Pull pages down as editable YAML files, make changes in your IDE, and push them back. Or go the other direction: scaffold new pages locally and publish them to production in bulk. Fields and templates sync the same way, with diff previews and dry-run support before anything is written. The practical result is a genuine 360 workflow — content and structure moving freely between your local dev environment and any live site, driven entirely by natural language prompts in Cursor. What's new in this release: Remote site connection Cursor can now connect directly to any live ProcessWire site over HTTPS. Previously all MCP tools only worked against your local database — remote changes meant logging into the CMS admin manually. Now a single configured API endpoint is all that's needed. Schema sync — push, pull, diff Field and template definitions are exported as versioned JSON files. Compare your local schema against production, see exactly what would change, and push with a single prompt. Think of it as Prisma migrations for ProcessWire. Previously adding a new field to production meant recreating it by hand in the admin and hoping it matched local. Page content sync — pull Any live page can be pulled down to a local YAML file. Your content is now code — version-controlled, editable in your IDE, and diffable like any other file. Previously content only lived in the database and the only way to edit it was through the CMS. Page content sync — push Edit content locally and push it back to local, production, or both simultaneously. Dry-run is on by default so you see exactly what will change before it's applied. Cursor writes directly to the ProcessWire database via the API — the CMS admin is never involved. Create and publish pages remotely — without touching the CMS Scaffold a new page in Cursor, write the content, and publish it directly to production in one step. Template, parent, name, fields, and published status are all set via a single prompt. This is the foundation for more powerful automated workflows — bulk landing page generation, scheduled blog publishing, or programmatic content pipelines driven by keyword data or external feeds. Cross-environment page reference resolution Pages that reference other pages (a homepage featuring service pages, for example) previously stored those relationships as raw database IDs. Those IDs differ between local and production, so pushing a page reference to a different environment would silently link to the wrong page — or nothing at all. References are now stored with their URL path and resolved correctly on whatever environment receives the push. Pre-push reference validation Before any push, a new pw_validate_refs tool scans every synced page and checks that all page references actually exist on the target environment. It reports missing references (which would blank the field on push) and unpublished references (valid but hidden) separately. Previously a broken reference had no way to surface until it caused a visible problem on the live site. Coming next The next phase adds a staging environment tier (local → staging → production promotion), matrix and repeater item sync, and autonomous content publishing — where an external scheduled process generates and publishes SEO-optimised content directly to ProcessWire without Cursor or the CMS admin being open at all.
-
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
I really like Sublime text. Slightly OT but have you tried Nova by Panic? I really like it and the built in remote server configuration: https://help.nova.app/remote-files/publishing/ -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
That's the one. You know it well ? Unfortunately, the gym here only has 1 of them. It's certainly the only cycling machine I know of that pumps out km and processwire code at the same time. Well, AI agents do at least. -
*nudge* 😉 is this just not a thing.
-
Hi Whats the most straightforward way to create pages and fields on a remote PW site from my macbook / local version of the site? I've created an MCP server and some surrounding UI which can quickly do a lot of this locally but it seems like the next logical step with my Cursor / AI tool is to be able to quickly scaffold remote stuff too. Am I overlooking something simple?
-
Media Hub update. Just a few small ones. You can rename the asset filename. If you select a folder or Collection, you can upload media / images directly into that I have started using Media Hub in one of my own live sites and it's highlghted some great areas for improvement etc. There's a significant difference between uploading a few Instagram photos and real staff photos, logos, and branding assets, which need to reside in multiple places across the site, yet remain a single image in the back-end. So, thats where I am. Hoping to ask for a few beta testers soon. If you're interested, please PM me.
- 37 replies
-
- 3
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
Yes already have it done. Each asset has a details page with a Usage table. This lists the places where an asset is used etc. The attached should give you an idea even if this asset is only used in one place.
- 37 replies
-
- 2
-
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
Media Hub update The Media Hub now has a folder view Folders is the default name for the view. It can be renamed to Gallery, Collections, Assets, Media, etc. Media assets can exist in one or more Folders so essentially they operate like Tags Clicking a Folder name will filter the main MediaHub by items within that Folder (and optionally sub folders) On an Asset detail view, you can quickly add and remove an association to a folder Support for Folder nesting, renaming etc is working
- 37 replies
-
- 4
-
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
Incidentally, when you mention you reached limits of performance, where and how did those limits manifest? I ran your query / issue through my AI Agent and had the following response. The Real Diagnosis Your friend likely experienced real slowness, but the cause is almost certainly inefficient query patterns (loading too many pages at once, N+1 queries, unindexed searches) rather than a fundamental limitation of pages-as-assets. These are the same problems any ORM-based system hits at scale, and they have well-known solutions. What MediaHub Would Need for 100K Assets Problem Fix Effort Crops filter loads all crop pages Direct SQL: SELECT DISTINCT master_id Small N+1 crop count per listing Batch query or denormalized count field Small LIKE search on title/desc Add FULLTEXT indexes Small Tag dropdown loads all tags Already paginated or use autocomplete Small No query caching Add WireCache for expensive queries Medium Standard pagination at scale PW handles this natively with start= + limit= Already done Streaming large exports Use $pages->findMany() (lazy loading) Small None of these require rethinking the data model. They're standard database optimization work. Summary The page-per-asset architecture is sound and scalable. ProcessWire's page model with proper indexing handles 100K+ pages without issue. The current MediaHub implementation has a handful of query patterns that would need optimization (mostly the crop filter and N+1 counts), but these are straightforward fixes. Switching to a JSON-in-field approach would solve the wrong problem while creating a bespoke data layer that loses most of PW's value and introduces its own harder-to-fix scaling issues. //END What do you think of above
- 37 replies
-
- 3
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
Hey David Thanks for that. I am planning another sprint next week. Right now, I am approaching this from a traditional image-as-page approach. Each crop variation of a 'master' image is also a separate page. That's possibly not as good for scalability but better from the point of view of having a new page image field listing all my images and crops. I dont have any sites with 10K + images so I'm happy enough with this solution but I will certainly reconsider and you've given me some other ideas too which I'll tackle next week. Will DM you re. other items. Cheers
- 37 replies
-
- 1
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
GrokImagine: AI Image Generation via x.ai
Peter Knight replied to maximus's topic in Modules/Plugins
Sounds great. Any examples or screenshots for us? -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
Anyone tried OpenClaw yet on a local machine? I see lots of tweets about Mac minis and OC and people running much cheaper agents etc -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
Sure, just visit cursor.com on a mobile device and log in. Look for the Agents link in top right. Select your project and branch if you’re connected to Git Then if you’re out, at the gym or on anywhere away from desk I just dictate the features I want and let the cloud agents run. -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
Toon link. Less readable perhaps than JSON for humans but it’s created for and optimised for machines -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
That’s amazing. I note you chose JSON for export. Have you seen the token optimised Toon? Might be a good additional option or even YAML? Looking forward to trying P -
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
I’m on Cursor Ultra and have been for some time. Even on Ultra I am frequently hitting my plan limits and while I don’t mind paying more, I’m going to rely less on the highest end models soon and start trying auto mode more. I’ll try to do more manual coding for the tasks I can do and stop leaning on agents for CSS changes etc. -
Cheer for the support Maximus. Having one of those days where I need a break from it all but more coming soon. Good to hear it’s useful.
- 37 replies
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
How does everyone feel about folders? I have tags working but I am also considering Collections. A photo could belong to one or more collections. In the background I’d allow the agency/developer to rename collections as folders. I know collections are more powerful but many clients are more at home with the concept of folders. And I feel like, why make them choose?
- 37 replies
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
How to Leverage AI for Smarter ProcessWire Development
Peter Knight replied to bernhard's topic in Dev Talk
Don’t forget Cursor cloud agents. Give a cloud agent a plan and the agent works in the background while you’re away from the laptop. I give them a task on the iPad when I’m at the gym and by the time I’m home there’s a new branch waiting for me. I can’t verify this but somehow I’ve often found the quality of the cloud agents to be better than the desktop ones even on the same model. Can’t be true? But feels that way. -
Rethinking my Media Hub cropping model 😑 I discovered a limitation when adding images via my new ImageHub field: selecting a crop doesn’t add a second item. Instead, it replaces the first crop selection. Root cause: the field stores a PageArray / reference list keyed by page ID, so it silently dedupes. All crops belong to the same master image page (same ID), so you can only reference it once. I’m leaning toward treating each crop as its own image/page (unique ID) with a master_id link, so multiple crops can be selected, ordered, reused across pages, and tracked for “where used”.
- 37 replies
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
It's good to see Cursor getting a bit of airtime and some mentions. Been using it since around 2024, and it's improving rapidly. The latest AI models too are impressive. It helps me with development, some UI design, SEO and pretty much is across 90% of my daily work these days apart from some design work. One of the best things about AI Agents is they can run in the cloud. So I'll often fire up a Cusror AI agent while I'm out for a walk or at the gym. I get home and the development work is ready for review and merge. I have yet to use Claude Code yet but I also see people speak highly of it. It's more terminal-based. Worth a look. Especially with Claude's new skills. Here's a good video from a Meta Engineer using CC.
-
Some updates to the Cursor MCP to Processwire Module. There's a new front-end called MCP Sync. So if the MCP server acted as a bridge between Processwire and Cursor, why do I then need a front-end UI? Surely the point of an MCP server was 50% to bypass the Admin? Well, apart from building it for fun, I thought it was nice to have a more visual front-end for the import and export of pages. From the screenshot you might notice a traditional tree view with some useful columns... Change Status Never exported - probably doesnt need a badge but just means it's the original state Local Changes - I've downloaded the page to a file and edited it In Sync - changes have been imported Conflict - both the remote (PW) and the local file) have changes In the Actions column the three icons are WTF (Wire to file) 🙂 - exporting FTW (File to wire) - importing This was a little tricky because import and export mean different things wether you're operating from Curors MCP or import/export via the Cursor UI. So I settled on WTF and FTW because they are less relative to your environment. Big change Previously, when a page was in WTF mod,e I was storing a YAML file. Apart from Matrix items which were separate YAML files. But as we know, YAML can be prone to misformatting so the Module now understands if a field is a Rich Text field and will export that as a stand-alone HTML file with a match name. It means a few more files on the file system than the previous method, but I like that I get a separate HTML entity. The screenshot of my local file system you can see I have WTF my Diagram and Illustrations page. And not just because the content was out of date and mentioned Macromedia Flash! Back to the GUI, you can see a screenshot of that row now picks up the change requiring a FTW. There's a few other helpful functions such as a changes preview as a safety step prior to committing a FTW. There's also a View YAML icon on each row which is a preview too. Here's the raw details of my WTF of Diagram and Illustrations page site/assets/pw-mcp/services/diagrams-illustration/page.meta.json This is a high-level overview of the exported page and is not meant to be edited. { "_readme": "DO NOT EDIT - This file is auto-generated. Edit page.yaml and field HTML files instead.", "pageId": 1051, "canonicalPath": "/services/diagrams-illustration/", "template": "services-detail", "title": "Professional Diagram Design & Illustration Services", "pulledAt": "2026-02-11T11:27:58+00:00", "lastPushedAt": null, "revisionHash": "sha256:2c264809d740ff009e27a5c664b3dced0e529493e54f39c3b458a718d47defb4", "contentHash": "0fc046d624ae2a6add4f6ffbcd6b80dd", "status": "clean" } /site/assets/pw-mcp/services/diagrams-illustration/page.yaml Note how the body field around line 4 or 5 is an RTE, so it's not included in the raw YAML but saved as a standalone file. fields: title: "Professional Diagram Design & Illustration Services" body_summary: "Need to clarify a product, process or service? Clarify your offering with our diagram design services." body: _file: fields/body.html image: [] service_thumbnail: - filename: icon-service-diagrams.png description: null width: 173 height: 113 seo_tab: null seo_title: "Professional Diagram Design & Illustration Services" seo_keywords: null seo_description: Transform complex ideas into clear, compelling diagrams. We create technical illustrations, infographics, and process diagrams that simplify your message and engage your audience. seo_image: null seo_custom: null seo_canonical: null seo_tab_END: null First_Child_Redirect: 0 sitemap_ignore: 0 site/assets/pw-mcp/services/diagrams-illustration/fields/body.html Just a html page and not worth including That's it for the mo.
-
Yeah sure. This is how I’m proceeding… Every file is a page and has its own id folder. I guess that part is predictable enough. Crops are simply variations of an image. They are stored in the same id folder with their own unique name. Re. image fields, there’s a custom field which is designed to look and feel like a normal image field, but isn't a regular image field. A user adds images to the image hub field, but they are living, connected references to the source hub. IE the image hub assets are not detached copies. The hub is meant to be the centralised media hub. Otherwise, it wouldn’t be much of a hub. At least that’s how it’s working right now. 🙂
- 37 replies
-
- 1
-
-
- media upload
- media
-
(and 3 more)
Tagged with:
-
Some more work. Not sure why the images are so fuzzy Image detail page You can edit the usual stuff...Title, Alt, Description, and add Tags etc Some utilities in there too such as Download, Copy URl, Duplicate, Delete If an image has Crop versions they are displayed under the main image Crop versions has thumbs and table view A crop version has a detailed view too Image Crop page There are presets, but you can create your own named crops Save as a crop version or save as a new image. The hardest part is in progress which is A custom Inputfield which allows you to add images from the MediaHub. All while maintaining a connection back to the hub source file. IE it's important that there's no duplication and that the images in the Media Hub are a true source / canonical version Displaying images in the page edit field in a nice consistent way with the existing UI. As much as possible, I want the user to feel like this the core and not some bolt-on with its own CSS. Although I am changing some things… Hope you like! P
- 37 replies
-
- 6
-
-
- media upload
- media
-
(and 3 more)
Tagged with: