Re:I tried to use WordPress with GitHub Pages
by disgruntledphd2 on Monday August 17, 2020 @08:13AM
(#24186458)
Many packages store the raw URLs in the DB, and don't respect the change of that setting. At least that was my experience.
I did try the obvious things first, to be fair.
Re:I tried to use WordPress with GitHub Pages
by tacone on Tuesday August 18, 2020 @10:37AM
(#24199083)
You need to use wp-cli to carefully find and replace urls and filesystem paths inside the db. Many professionals don't even know about it.
Another way is to perform the find and replace with PhpMyAdmin.
Re:I tried to use WordPress with GitHub Pages
by tacone on Tuesday August 18, 2020 @10:40AM
(#24199117)
Forget what I said about PhpMyAdmin, you can't edit serialized blobs easily. Wp-cli is the way to do it.
Re:I tried to use WordPress with GitHub Pages
by disgruntledphd2 on Tuesday August 18, 2020 @11:04AM
(#24199510)
Or you could just use SQL (which is what I did).
Re:I tried to use WordPress with GitHub Pages
by tacone on Thursday August 20, 2020 @11:29AM
(#24224253)
No, you would invalidate all PHP serialized blobs. Things may keep working, but you would lose some config/data.
Re:I tried to use WordPress with GitHub Pages
by disgruntledphd2 on Friday August 21, 2020 @04:55AM
(#24233265)
Apologies, SQL for almost everything, and sed for the text files that didn't get updated.
It appeared to work a few times (or at least my wife/her customers didn't complain).
For context my wife uses wordpress to build various sites. I got lumped with the task of moving this online. It was super painful, as WP encodes the URL name (i.e. localhost) flipping everywhere.
I eventually resolved this by editing the tables which stored the URLS (fortunately, as a DS I know SQL) and doing some sed on various files that cached the URL.
I now refuse to do this, and set her up online with a website before she does any work, because moving it is so painful.