Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
fuf
Sep 12, 2004

haha
I inherited a site where the client has been casually uploading hundreds of 25mb images to the media library, so the uploads folder is now over 8gb. I mentioned it and before I could stop them someone went through and resized them all using the built in WordPress edit image tool.

The problem is that WordPress doesn't delete the original image, so now the uploads folder is full of:
giant-image.jpg (25mb)
giant-image-e1621800752309.jpg (1mb)

imsanity has a bulk image resize tool, but it only operates on items in the media library, i.e. it will try to resize giant-image-e1621800752309.jpg but ignores giant-image.jpg. Smush seems to do the same thing.

I really want to resize / optimise all the giant images to save space. I am wary of straight up deleting them just in case some pages or theme templates are still referencing the original file and not the edited version. (I also couldn't actually find a plugin that would just delete the original images and only keep the edited version, which seems surprising?)

Does anyone know of a plugin that will resize / optimise images based on the entire /uploads/ directory, not just the items in the media library?

Adbot
ADBOT LOVES YOU

Thorbeef
Jul 24, 2007

fuf posted:

Does anyone know of a plugin that will resize / optimise images based on the entire /uploads/ directory, not just the items in the media library?

I'm a recent convert to Smush. Have barely used the free version, but I'm in charge of a few sites with huge uploads folders and the paid version of Smush has saved them. It can also convert the images to WebP too.

https://wordpress.org/plugins/wp-smushit/

fuf
Sep 12, 2004

haha

supermegaultra posted:

I'm a recent convert to Smush. Have barely used the free version, but I'm in charge of a few sites with huge uploads folders and the paid version of Smush has saved them. It can also convert the images to WebP too.

https://wordpress.org/plugins/wp-smushit/

Thanks, but I don't think Smush has an option to delete the original file after resizing / optimising? At least I can't see an option in the free version...

frogbs
May 5, 2004
Well well well

fuf posted:

Thanks, but I don't think Smush has an option to delete the original file after resizing / optimising? At least I can't see an option in the free version...

Smush was going to be my recommendation, based on other people recommending it to me for this kind of stuff. If Smush isn't an option, couldn't you download the entire /wp-content directory, find all the largest images, batch resize them using the original filenames and re-upload, overwriting them?

Siguy
Sep 15, 2010

10.0 10.0 10.0 10.0 10.0
A whine/boring backstory/general request for advice:

I don’t usually use Wordpress. I’m not even a web developer by profession. But I helped an organization I know make a very custom Wordpress theme from scratch five years ago (it felt a like a flashback into my teenage years smashing bits of random PHP together). It worked out fine but it was a pain in the butt because there were multiple custom post types and I basically hand coded everything from a super generic theme template.

So now my wife’s church needs someone to update their Wordpress and its theme and she’s volunteered my services. And I thought it would be way easier this time since they don’t need any custom post types at all. I’ll just buy a theme and tweak it.

But I don’t like what I’m finding. Every generic theme seems built around woo commerce and if I look for something church specific then I get sites trying to charge $200-a-year to keep the theme updated. A lot of them are also built around big WYSIWYG page builders, which I’m suspicious of.

I feel like I’m going to have to do everything from scratch again which is what I’d like to avoid. I looked at Underscores and Sage to try to at least build from a more modern base but both of them are tied into npm node-sass poo poo that is apparently deprecated and refuses to build on my computer no matter how many times I remove and reinstall node.

So questions:

1. Where should I be looking for themes that aren’t so ecommerce focused?

2. Am I right to be suspicious of the themes with built in page builders or am I just making life harder for myself?

3. If I do give up and build from mostly scratch, is there a template or theme you recommend starting with?

LifeLynx
Feb 27, 2001

Dang so this is like looking over his shoulder in real-time
Grimey Drawer

Siguy posted:

A whine/boring backstory/general request for advice:

I don’t usually use Wordpress. I’m not even a web developer by profession. But I helped an organization I know make a very custom Wordpress theme from scratch five years ago (it felt a like a flashback into my teenage years smashing bits of random PHP together). It worked out fine but it was a pain in the butt because there were multiple custom post types and I basically hand coded everything from a super generic theme template.

So now my wife’s church needs someone to update their Wordpress and its theme and she’s volunteered my services. And I thought it would be way easier this time since they don’t need any custom post types at all. I’ll just buy a theme and tweak it.

But I don’t like what I’m finding. Every generic theme seems built around woo commerce and if I look for something church specific then I get sites trying to charge $200-a-year to keep the theme updated. A lot of them are also built around big WYSIWYG page builders, which I’m suspicious of.

I feel like I’m going to have to do everything from scratch again which is what I’d like to avoid. I looked at Underscores and Sage to try to at least build from a more modern base but both of them are tied into npm node-sass poo poo that is apparently deprecated and refuses to build on my computer no matter how many times I remove and reinstall node.

So questions:

1. Where should I be looking for themes that aren’t so ecommerce focused?

2. Am I right to be suspicious of the themes with built in page builders or am I just making life harder for myself?

3. If I do give up and build from mostly scratch, is there a template or theme you recommend starting with?

You don't need npm to install Underscores, I don't even see any SASS in the test theme I just downloaded from https://underscores.me/. Just put the directory in the /wp-content/themes/ directory and enable it.

Page builders add so much bloat, but I don't have much experience with already-made themes so I don't know what's good. I found these themes here that might be a good start: https://andersnoren.se/teman/

Siguy
Sep 15, 2010

10.0 10.0 10.0 10.0 10.0
Thanks for the helpful links. I’ll try the download from the underscore website and check out those free themes.

The version of underscores I was using was from their GitHub and required composer and npm and a deprecated version of node-sass.

Empress Brosephine
Mar 31, 2012

by Jeffrey of YOSPOS
If you're technical enough to use underscores then I would say just download generate press and generateblocks and build something simple for them imho.

kedo
Nov 27, 2007

Siguy posted:

1. Where should I be looking for themes that aren’t so ecommerce focused?

https://themeforest.net/ is pretty much the go-to for pre-made themes. Many of the really good ones charge an annual fee for updates, though. That's just the way things are today.

Siguy posted:

2. Am I right to be suspicious of the themes with built in page builders or am I just making life harder for myself?

I hate to say, "it depends," but it depends. I've built dozens of sites with and without page builders, and there are plenty of pros and cons I could list in a 5000 word post, but the short version is:

PROS:
  • Gives your users a ton of control over the layout and structure of pages, which makes clients very happy
  • Requires less time spent in PHPland

CONS:
  • Gives your users a ton of control over the layout and structure of pages, which results in fugly pages designed by Marsha From Marketing who "has an eye for that kind of thing" and likes all the text to be rendered in Curlz MT in pink on a red background.
  • Pages get saved as sort of mini-applications that use HTML, CSS and JS that's specific to each page. This makes them fragile and easily broken by plugin updates. It also makes it virtually impossible to move the content out of the page builder, so if you ever need to migrate content at some distant point in the future it will be a manual copy/paste job.
  • Many are very bloated, as LifeLynx said. The one I've used most is Elementor and it's not too bad when it comes to bloat and it's very developer friendly which is nice, but again you're basically making each page a JS app which has a lot of overhead.

Siguy posted:

3. If I do give up and build from mostly scratch, is there a template or theme you recommend starting with?

Sage is definitely the go-to modern blank slate theme, but as you've learned it leans heavily into modern front-end practices and is extremely opinionated about where and how you write your code. I personally really like it because it helps keep things clean and organized and it's incredibly well documented so I feel great about handing projects off to other devs (as opposed to, say, using a blank theme I coded completely from scratch and "forgot" to document), but it has a steep learning curve.



My two cents: unless you want to be on the hook for support for the rest of the site's life, you should just have them buy a theme and do the basic install/setup for them. In all honesty, I wouldn't even accept this gig. Cheap or free clients are the worst clients 100% of the time because since they're not paying for your time, they don't value your time. Better yet, tell them to use Squarespace (which any idiot can set up), and bow out, imo.

Siguy
Sep 15, 2010

10.0 10.0 10.0 10.0 10.0
This is all helpful. Thanks for the general advice and perspective.

frogbs
May 5, 2004
Well well well
I've had several clients this week ask me about moving away from Wordpress to ShowIt (https://showit.co/), since it's 'easier'. The fact that it's Wordpress under the hood doesn't matter to them, and makes me think that Automattic is missing an opportunity by not re-branding Wordpress.com to something else. To the lay-person Wordpress.com vs. Wordpress.org hasn't made any sense, and Gutenberg hasn't really caught any traction with Wordpress.org users. Spin Gutenberg and Wordpress.com out as a separate service called 'Weblicate' or something, with like 10 easy templates like ShowIt and watch the money roll in!

LifeLynx
Feb 27, 2001

Dang so this is like looking over his shoulder in real-time
Grimey Drawer

Empress Brosephine posted:

If you're technical enough to use underscores then I would say just download generate press and generateblocks and build something simple for them imho.

Quoting a banned goon from a month ago, but it's insane how complicated creating a basic Gutenberg block is. Advanced Custom Fields is one of the most popular plugins, so they have to know about it and how easy it makes things. There are generators that make Gutenberg blocks, but they don't give you the code, so that you're locked into using their plugin. I wanted to make a block that was a date picker, so I could get that data from a custom post type. The date picker control is there, but not used in any official Gutenberg blocks, but after an hour of research I gave up because I had more productive things to do.

You can create custom post types and assign them block templates pretty easily, and it would likely completely obsolete Advanced Custom Fields and page builder plugins entirely if the dev process for creating blocks was easier.

wearing a lampshade
Mar 6, 2013

The fact that wordpress stores block data as html inside post_content column is absolutely insane to me.

frogbs
May 5, 2004
Well well well
A few months back someone recommended a Form plugin (or maybe it was SMTP plugin?) that would send you a notice if there was a deliverability issue with a form notification email. Does that ring a bell for anyone?


wearing a lampshade posted:

The fact that wordpress stores block data as html inside post_content column is absolutely insane to me.

It's a complete mess and I hate it.

LifeLynx posted:

Quoting a banned goon from a month ago, but it's insane how complicated creating a basic Gutenberg block is. Advanced Custom Fields is one of the most popular plugins, so they have to know about it and how easy it makes things. There are generators that make Gutenberg blocks, but they don't give you the code, so that you're locked into using their plugin. I wanted to make a block that was a date picker, so I could get that data from a custom post type. The date picker control is there, but not used in any official Gutenberg blocks, but after an hour of research I gave up because I had more productive things to do.

You can create custom post types and assign them block templates pretty easily, and it would likely completely obsolete Advanced Custom Fields and page builder plugins entirely if the dev process for creating blocks was easier.

I'd be way more likely to use Gutenberg if you could just create blocks from within Wordpress ala Advanced Custom Fields. The fact that you have to monkey around in code to add fields to common post types in 2021 is surprising to me, but then again I suppose you'd still need to add them on the front-end too.

foghorn
Oct 9, 2006

Haters gunna hate.

wearing a lampshade posted:

The fact that wordpress stores block data as html inside post_content column is absolutely insane to me.

It's the legacy sites that are going to keep that insanity going. So many older sites are built on that structural idea, and way too many plugins expect it to make any radical changes. Shifting it into something that makes more sense, like having it sliced into multiple rows in a child table, would mean a dramatic shift that will probably break a lot of things.

Like someone else mentioned, moving away from the WP brand might be a good idea for this too. Leaving the existing code as the legacy WP system, and building a semi clean sheet system that can take advantage of these designs as a new brand would make a ton of sense.

wearing a lampshade
Mar 6, 2013

foghorn posted:

It's the legacy sites that are going to keep that insanity going. So many older sites are built on that structural idea, and way too many plugins expect it to make any radical changes. Shifting it into something that makes more sense, like having it sliced into multiple rows in a child table, would mean a dramatic shift that will probably break a lot of things.

Like someone else mentioned, moving away from the WP brand might be a good idea for this too. Leaving the existing code as the legacy WP system, and building a semi clean sheet system that can take advantage of these designs as a new brand would make a ton of sense.

Its something awful :classiclol:

My dream is to just set up a silverstripe install inside a wp theme somehow. Its probably more work than its worth but itd be fun to figure out.

kedo
Nov 27, 2007

I'm pretty sure I talked about this previously in this thread, but ACF allows you to create custom blocks. I've used this on all of my recent Gutenberg projects and it's just as easy as everything else ACF does.

Writing a Gutenburg block from scratch is about as easy as writing a complex React app from scratch. I have no idea why they made it so incredibly difficult. It feels very un-WordPress.

frogbs
May 5, 2004
Well well well
So the Sendgrid Wordpress plugin was just removed from the Wordpress Plugin Directory for a vulnerability that they've said they will never patch. Does anyone have a good recomendation for a plugin that supports sending email via Sendgrid's api? Alternatively we could use one of the many SMTP plugins, but i'd rather just hook it up using their API and be done with it.

WP Mail SMTP seems to be the most obvious option, but maybe y'all have other recommendations? https://wordpress.org/plugins/wp-mail-smtp/

XBenedict
May 23, 2006

YOUR LIPS SAY 0, BUT YOUR EYES SAY 1.

frogbs posted:

So the Sendgrid Wordpress plugin was just removed from the Wordpress Plugin Directory for a vulnerability that they've said they will never patch. Does anyone have a good recomendation for a plugin that supports sending email via Sendgrid's api? Alternatively we could use one of the many SMTP plugins, but i'd rather just hook it up using their API and be done with it.

WP Mail SMTP seems to be the most obvious option, but maybe y'all have other recommendations? https://wordpress.org/plugins/wp-mail-smtp/

Mailster is good.

frogbs
May 5, 2004
Well well well

Thanks! I'll give it a look.

Also, laughing heartily at this Tweet and the ensuing thread from the official Wordpress.org account, saying they're extending support for the Classic Editor plugin through 2022, "after discussing it with Matt". I think that keeping classic editor functionality is a good thing, but the fact that they have to run it by him is insane. https://twitter.com/WordPress/status/1430573741793325060

I really, really, wish that Wordpress.org was a little more decoupled from Automattic/Wordpress.com.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
Any of you have any woocommerce experience? I'm trying to figure out how to offer free shipping but support multiple addresses for shipping and only allow free shipping for every instance of $59 spent...if that makes sense. Willing to pay if anyone can do this or can help out. Just pm me

Thorbeef
Jul 24, 2007

Fixins posted:

Any of you have any woocommerce experience? I'm trying to figure out how to offer free shipping but support multiple addresses for shipping and only allow free shipping for every instance of $59 spent...if that makes sense. Willing to pay if anyone can do this or can help out. Just pm me

Hey chief, hope I understand right, but I think you should be able to do this with default Woocommerce.. Set up your shipping zones, then add a "Free Shipping" shipping method to each shipping zone you want free shipping on, set the free shipping method shipping requirement to "a minimum order amount" and you should be away laughing.

Here's a screenshot incase my ramblings make no sense.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
Lol. Thanks s okay. That works but the issue I have is that if the order.is.over x amount it sets free shipping to every address. Here's what I wrote up for a spec:


"The company offers free shipping on orders over $59 per address. So, that means that if someone orders lets say $110 worth of merchandise that is being sent to two addresses, they would only receive the free shipping on One address and not both. That said if the order was for $121 then both address would receive the free shipping. BUT a address has to have at least $59 worth of products in order to get free shipping. So, for example, let's say a person has a order for $70 shipping to two seperate address, with $24 going to address 1 and $46 going to address 2 they would not receive any free shipping on either address. The logic I believe would really be as follows:

x = # of address being shipped too
y = Order Subtotal
z = x;


while x >= 0:
if (y / x >= 59)
free shipping for x addresses
paid shipping for (z - x) addresses
break;
else
x--;



The plugin I am using to offer Multiple shipping addresses is "WooCommerce Shipping to Multiple Addresses" by IgniteWoo. For shipping calculations, I am using Flexible Shipping UPS. "


So I'm just stuck as to what logic to hook info to achieve this I guess. I have the project on codeable but I'd rather pay a goon if anyone's interested in this quick job

ChickenWing
Jul 22, 2010

:v:

Hey goons, I was talked into taking charge of building a moderately complicated application on top of an existing wordpress site. The original application lived in the same server but was otherwise basically completely decoupled from the site. I'm hoping to at least be able to use the same theme and whatnot (because god knows I can't design worth a drat) and I'm wondering what the right approach is. Internet says I can create templates (one template per page I have feels weird and cluttery), or I can just include the blog header (useful, but I feel like I'm not leveraging the wordpress theme as well as I could be here).

I'm moderately proficient with PHP, at least as of like 5 years ago, but my experience is pretty limited - I'm not sure what the PHP+wordpress dev universe is like but my experience is equivalent to writing pure javascript rather than using jquery/node/etc.

So: I've got a basic dev environment set up (running wordpress out of docker, vscode set up with PHP snippets/intellisense). What else should I be using to make my life easier (e.g. I hear a lot about composer, is that useful or overkill?), and in what way should I be integrating with Wordpress?

kedo
Nov 27, 2007

If you're more comfortable JS, you could consider going headless WP and create a JS app that queries the WP REST API. GatsbyJS is commonly used for this purpose.

Otherwise your question is so general I'm not sure what advice to give you. Is your plan to link the app more closely with WordPress, or to continue keeping them separate?

ChickenWing
Jul 22, 2010

:v:

Yeah, sorry - I'm mostly just worried I'm doing the equivalent of writing code in a text editor, I want to make sure I'm not doing anything to make my life significantly harder.

The app I'm writing is a CRUD application with its own backing database. I want to integrate with the wordpress theme, but creating a template for every single page I need to write sounds painful, and I've read that it's way easier to gently caress up and delete template pages than it is to delete standalone pages in the web root. The only other option I've seen is to include the wordpress blog header, and then handle all your own HTML, which feels more like what I should be doing, but naturally I have to handcraft all my own HTML.

Basically, I want the app to feel like it's integrated with the wordpress site, but I need it to do do stuff like render tables based on my other database, which I feel like the wordpress templates stuff is ill-equipped to do?

kedo
Nov 27, 2007

Writing code in a text editor is what I do as well for 99% of my WordPress work, so you're just fine there. A lot of articles written about WordPress target non-developer users, so it's easy to go down the rabbit hole of "everything you make on WordPress must be created in the WP GUI and live within the WP ecosystem," but that's not entirely the case. At the end of the day WP is just a big PHP application, and you can do anything with it you might be able to do with any other PHP application.

Will your app be written in PHP? If so, it seems like an integration should be pretty simple. If it were me, I'd probably have the application live in its own directory at the web root (or as a WP plugin for that matter, which would probably be the "correct" way to do it), I'd create a single page template with the WP header and footer (this is required for WP pages to function), and then I'd require/include the application between the two. I've done something similar before with a React app – basically WP just acted like a wrapper for the application and allowed users to create additional pages surrounding the application, but the app itself was all executed in code that was untouchable by my client and completely disconnected from WP in almost every way.

Composer would be helpful if you need to manage PHP dependencies for your app, but I don't find it terribly helpful for traditional WP sites. Whether or not it's usable on the live site will also depend on who hosts the thing as there are many hosts who still don't support Composer.

As an aside: it's entirely possible to connect to a second database within WP, so if you wanted to have your application live within the WP ecosystem, it's technically possible. See wpdb, and this basic example. The more that I think about it, creating your app as a WP plugin is probably the way to go unless you can foresee a future where it would need to exist outside of WP. As a plugin, you'd have the ability to expose various controls to admin users via the WP interface (creating an options page in the WP admin dashboard is trivial, especially if you use the ACF plugin which I would highly recommend), and you'd gain all the benefits of WP without having your code tied to a theme or template that a non-developer can easily gently caress up.

ChickenWing posted:

I've read that it's way easier to gently caress up and delete template pages than it is to delete standalone pages in the web root.

Administrative users can delete themes (which is where template pages would live), and the theme editor provides a GUI that allows them to muck with the actual code of template files. A non-technical user could unintentionally delete important stuff, but it's a rare occurance. Usually I hide those admin menus from users so they can't accidentally break things. Creating your app as a plugin would avoid this issue because WP doesn't allow users to edit plugin code via a GUI. The worst they could do would be to disable/delete the plugin, but all you'd need to do would be to re-install/enable it again.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
https://www.nhlovescampers.com

So that's a hybrid site I made using WordPress as a API and the actual WordPress system. So the majority of the site is built within WordPress but of you go to find a campground that's a nextjs app using wp graph ql to grab WordPress data on campgrounds.

https://search.nhlovescampers.com/camps?city=all&campfeatures=all&region=all&camptype=all

I used Apollo I think to grab the data but in hindsight o wish I just built the site entirely in nextjs and just used WordPress for a data endpoint. Granted I'd lose out on some SEO but I think overall it's be much nicer.

I've basically moved away from doing this and just do most stuff within php now as I find it easier for most stuff. Hope this kinda helps.

ChickenWing
Jul 22, 2010

:v:

Those are both perfect, thanks.

kedo posted:

If it were me, I'd probably have the application live in its own directory at the web root (or as a WP plugin for that matter, which would probably be the "correct" way to do it), I'd create a single page template with the WP header and footer (this is required for WP pages to function), and then I'd require/include the application between the two.

Right, that sounds smart, but I have no idea what you mean by "include the application" - I'm used to a collection of individual pages with PHP embedded in them, I assume "a php application" is something more robust/substantial than that?

worms butthole guy
Jan 29, 2021

by Fluffdaddy
I think he means put the application within the main WordPress loop. So WordPress would load the header and the footer and essentially side load the app. Although that would kind of depend on the app you're making

fuf
Sep 12, 2004

haha
Does anyone have a favourite migrator plugin or app that goes directly from server to server? Without having to download a package like duplicator?

kedo
Nov 27, 2007

Are you only migrating content, or moving the full site from one server to another? A content migration means the content leaves one site/WP theme and enters a completely new site/WP theme, wheras a site move means moving all of the site (web files, database, etc.) and dropping it on a new server.

I've done a few very hefty content migrations lately (>30,000 posts each, with complicated field structures and mapping), and honestly all of the sever to server plugins I tried sucked. WPMU's migration tool is okay if you're running a mostly vanilla WP instance w/ few or no custom fields, but if your migration is large or in any way complex your best bet is WP All Import (and the affiliated export/custom fields add ons). If your field mapping from site A to site B isn't 1:1, you may need to look into custom bulk actions as well to update the content on each post after they're imported.

If you're simply moving a WP site from one server to the other and not actually migrating content, it's usually as easy as downloading all of the web files, creating a database dump, and then uploading everything to the new server. All-in-One WP Migration does this well, if you don't feel like mucking around in SQL-PHP-land yourself.

LifeLynx
Feb 27, 2001

Dang so this is like looking over his shoulder in real-time
Grimey Drawer
All-in-One WP Migration is the best I've found after trying them all. It requires an extra plugin to move sites over 32 MB, and I think it does it in multiple chunks instead of all at once. Pro tip though: Your .wpress backup files will be massive on your average medium size site, because odds are someone has uploaded hundreds of 1.5 MB JPGs to the media folder, and even though Wordpress is good at optimizing images, the original files are still there taking up space. AIO WP Migration has an advanced setting to not export media files, so try doing that and manually porting over the contents of /wp-content/uploads through SSH or whatever.

I tried creating my own event calendar by installing Pods, creating a custom post type for Event, and creating a Pod that had event_date and entry_fee. They appear in the REST API, which is great because the aim of this was to use NextJS for the front end. The bad thing is, I can't figure out a way to query by event_date. I even installed WPGraphQL and added the fields to show up in the GraphQL output, but you can't filter them by "where". I can filter it on the front end, but the issue I see is that as more events get added, eventually it'll be querying hundreds of events, most of which have "expired". So unless someone goes in once a month and unpublishes all the expired events, it's going to get slower and slower. I need to see how the popular event calendar plugins handle this. I was hoping not to use one because they're overkill for what I need, but I guess it doesn't matter if I'm controlling the entire front-end. The major downside of any WP plugin is the amount of bullshit JS and HTML it spits out to the page.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
I use CPTUI but with that the custom posts work the same as regular posts, you just have to add it in so wp graph ql can recognize it. So you can query but publish date or event date if it's a ACF.

This plugin should do it

https://www.wpgraphql.com/docs/custom-post-types/

LifeLynx
Feb 27, 2001

Dang so this is like looking over his shoulder in real-time
Grimey Drawer

Fixins posted:

I use CPTUI but with that the custom posts work the same as regular posts, you just have to add it in so wp graph ql can recognize it. So you can query but publish date or event date if it's a ACF.

This plugin should do it

https://www.wpgraphql.com/docs/custom-post-types/

You can query them with WPGraphQL, but as far as I can tell you can't query for things that have a key and a specific value, just if they have the key. They don't show up under the "where" part of the IDE, and I don't know if that means they can't be searched. I don't know if that makes sense, my brain is scrambled.

Pods explicitly says it won't help you have your pod fields be queryable in REST API and says you should create your own endpoint for things like that, which I think is an even deeper dive into WP_Query and MySQL.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
Ohh I gotcha. In that case you would query everything and then run the specialized query within NextJS/Apollo. It's a big drain but that's what I had to do with that campground search

fuf
Sep 12, 2004

haha

kedo posted:

If you're simply moving a WP site from one server to the other and not actually migrating content, it's usually as easy as downloading all of the web files, creating a database dump, and then uploading everything to the new server. All-in-One WP Migration does this well, if you don't feel like mucking around in SQL-PHP-land yourself.


LifeLynx posted:

All-in-One WP Migration is the best I've found after trying them all. It requires an extra plugin to move sites over 32 MB, and I think it does it in multiple chunks instead of all at once. Pro tip though: Your .wpress backup files will be massive on your average medium size site, because odds are someone has uploaded hundreds of 1.5 MB JPGs to the media folder, and even though Wordpress is good at optimizing images, the original files are still there taking up space. AIO WP Migration has an advanced setting to not export media files, so try doing that and manually porting over the contents of /wp-content/uploads through SSH or whatever.

Thanks guys, yeah I ended up using All-in-One WP Migration. In fact on a whim I searched my email for the company name and it turns out I bought a license for it in 2015...

It's cool that the license still works so I can get past the size limits, but it sucks that I'm still solving the same problems as if from scratch six years later lol

greazeball
Feb 4, 2003



I haven't been following this thread since you all gave me a bunch of advice earlier (thanks again!) and don't know how relevant this will be but...

Jetpack sent a notice to my wife today that there was an issue with Divi, click here to resolve it. And it loving DELETED DIVI without a confirmation check and certainly no indication that it was deleting instead of deactivating poo poo. She's restoring from backup now. Maybe you guys are used to this from Jetpack or you never get it but I thought I'd raise the alarm just in case it helps someone avoid this particular bullshit.

worms butthole guy
Jan 29, 2021

by Fluffdaddy
I don't use Jetpack. Because of horror stories like that. Sorry it happened to you.

Adbot
ADBOT LOVES YOU

kedo
Nov 27, 2007

greazeball posted:

I haven't been following this thread since you all gave me a bunch of advice earlier (thanks again!) and don't know how relevant this will be but...

Jetpack sent a notice to my wife today that there was an issue with Divi, click here to resolve it. And it loving DELETED DIVI without a confirmation check and certainly no indication that it was deleting instead of deactivating poo poo. She's restoring from backup now. Maybe you guys are used to this from Jetpack or you never get it but I thought I'd raise the alarm just in case it helps someone avoid this particular bullshit.

That sounds like a pain in the rear end, but tbh it sounds like Jetpack is doing the lord's work because Divi is a huge piece of poo poo theme that deserves deletion! I totally get how painful it probably was to deal with, but this still gave me a nice, sensible chuckle over my morning coffee.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply