delete_user_meta : how to delete all the metadata of a given user (witout SQL)

Yes, it does delete the usermeta. Here’s the code it uses: $meta = $wpdb->get_col( $wpdb->prepare( “SELECT umeta_id FROM $wpdb->usermeta WHERE user_id = %d”, $id ) ); foreach ( $meta as $mid ) delete_metadata_by_mid( ‘user’, $mid ); There’s identical code in wp_delete_user (for the non-multisite case) and they use the same pattern for deleting taxonomy metadata, … Read more

Multisite, multiple domains per site

In vanilla WP, a site cannot serve multiple domains like that unless it’s the root site. Additionally, your desired setup would lead you to one of two situations: You’re succesfully serving the site on 2 domains, but all the canonical tags point to the first domain regardless of which is setup Google sees duplicated content … Read more

WordPress Images Not Showing When FTP

Uploading the image is only one part of the process. When you add media to your site via the Media Library, it’s actually added as an attachment, a built-in post type that carries with it a bunch of metadata. Simply FTPing images into the appropriate directory doesn’t create the associated attachment post or set any … Read more

Retrieve taxonomies from arbitrary site

how can I retrieve all taxonomy terms for a post in an arbitrary site programmatically? In other words, given post $post and site $siteId, how can I retrieve all terms for all taxonomies of that post in that site? You can do this by omitting the taxonomy from WP_Term_Query: $query = new WP_Term_Query( [ ‘object_ids’ … Read more

Can a user spread virus on my Multisite?

Out of the box multisite has the same security as wordpress.com gives it users – being that it strips all kinds of extras, even if you are an administrator of your own blog. Super Admin has the basic WordPress permissions, everyone else does not. no iframes, no javascript, no code.

Create a network of sites

I read that, for a network or sites, wordpress impose certain rules in the url generated. is this true? because if is, it could destroy ten years of google indexing in our site… 🙁 Mostly whatever works for your individual sites (I assume they are on WP?) will work for multisite. Only explicit limitation that … Read more

Multisites, upload issues, and iOS!

After 6 days of pure sadness, this ended up being the fix: http://www.technowut.com/2012/05/14/how-to-stream-videos-to-ios-devices-with-multisite-wordpress/ Here’s how to get it working on CentOS 6 with the packaged Apache httpd: Nils Maier wrote the module for Apache httpd. Download the source and take some time to review the docs there. Compile and install the module on the command … Read more

Google Docs Viewer have problem in MultiSite sub-blogs

Only fix for 3.4.2 involves hacking a core file. The issue is already corrected in the upcoming version 3.5. Edit wp-includes/functions.php. Around line 1810, you’ll find this: ‘doc|docx’ => ‘application/msword’, Change that to this: ‘doc’ => ‘application/msword’, The docx file extension is actually already handled properly later down in the file, line 1819: ‘docx|dotx’ => … Read more

Any downsides on using Multisite for many look-alike-websites?

The main rule of thumb that I follow in these cases is: “Use WordPress multisite if it gives you clear advantages, not just because you can”. Mike Epstein explained this pretty well in the “Don’t use WordPress Multisite” post. This question is also answered on Quora before: Are there any disadvantages to using wordpress Multisite? … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)