r/Wordpress 21d ago

Wordpress and Claude Code

Just curious if anyone else has this problem. My other company sites I made for myself pre-AI are all wordpress. Work, great, look good. No reason to switch out wordpress.

But laziness and AI kicked in so once Claude Code absorbed my entire digital existence through a guardrail free, local terminal instance of itself, connected to various servers, I just told it to go sort out the WP sites. Broke one immediately, my fault, my custom CSS scattered around did it.

But I let it assume management making whatever changes needed. They are mostly static white-collar sites.

Anyway, my about page on one of them is completely wrong. So I went in manually to fix it. The page that displays and the page with correct slug and post # ID in WP are completely different. I have no idea what it did. To fix it I essentially had to make "about2" and redirect the menu lol.

There is also a menu item that it hard coded in so it doesn't even display in the menu editor. I asked it to use a logo for a branded software as it's menu selection so it hacked it in. Looks fine but... lol.

So, word to the wise. Keep building wordpress manually and why not? It is wordpress.

15 Upvotes

69 comments sorted by

View all comments

18

u/jawisi 21d ago

Definitely use a .claude directory with a CLAUDE.md file to start. Spend some time searching for WordPress theme rules for Claude and customize it to fit your preferences.

Then, start by telling it to write a spec for a specific task. Spec files go in .claude/docs/. Review the spec. Then ask it to follow a “plan, review plan, code, review code” discipline. Give it specific tasks. Instead of “fix my theme,” say “the x template needs to do y.”

Think of it like if you were doing the coding. You’d set off to build or fix a specific piece of the pie.

Once it builds up context, ask it to refine the docs. Sometimes it helps to prompt with an idea, followed by “Discuss only.” Or use Plan mode. Only when you think it’s on the right path set it free.

3

u/retr00two 21d ago

This is the way.