Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Hot answers tagged

9

If the URLs are the only difference between the installs you can edit one of the config.php files and add define('WP_HOME','http://A.mysite.com'); define('WP_SITEURL','http://A.mysite.com'); and to the other config.php add define('WP_HOME','http://B.mysite.com'); define('WP_SITEURL','http://B.mysite.com'); Both installs will use the same database info ...


7

There's a reason people say that you shouldn't download free themes from outside of wordpress.org, they might contain hidden surprises In your case, the theme inserts an advertisement at the beginning of the post content div: <div style="position:absolute;top:0;left:-9999px;">Want create site? Find <a href="http://dlwordpress.com/">Free ...


4

In the source code I see two og:description meta tags. The first and correct one seems to be coming from your Yoast WordPress SEO Plugin. The other one is outside the plugin's block, so I guess it's defined elsewhere. Check your theme if it includes that meta tag. If not, check your other plugins. Disable them one by one to find the culprit.


3

Facebook scrapes your pages for images to go along with the post you share. When it finds an image on the page it will use that. To specify which image exactly you have to use Open Graph tags in the head part of you html page. The og:image tag in particular: <meta property="og:image" content="http://graphics.myfavnews.com/images/logo-100x100.jpg" /> ...


2

You can't modify the core function's output, but you can replace it with your own function by unhooking it from embed_footer and adding your own function with custom output: remove_action( 'embed_footer', 'print_embed_sharing_dialog' ); add_action( 'embed_footer', 'my_custom_sharing_dialog', 9 ); function my_custom_sharing_dialog() { // write your own ...


2

It's not possible in Wordpress to have shared users between 2 separates installations on 2 separated databases. It could be possible just by hardcoding: hardcode WP_User class connect to other database and retrieve users from there hardcode get_metadata() function, that for wp_usermeta table connect to other database and retrieve users from there but ...


1

If they're subscribed to your feed, go to Settings > Reading in wp-admin and where it says "For each article in a feed, show" choose "Summary" instead of "Full text."


1

Yes there are beautiful plugin for you, Adminimize and User role editor where you can edit the user's role as per your choice.


1

By the below code you can give contributor to upload image. function rwc_allow_contributor_uploads() { $contributor = get_role('contributor'); $contributor->add_cap('upload_files'); } add_action('admin_init', 'rwc_allow_contributor_uploads');` And admin will review the post and then publish it.


1

You can just use the function switch_to_blog before running the WP_Query on your post_type "projects". Switch the current blog to a different blog. switch_to_blog(), is useful if you need to pull posts or other information from other blogs. Sounds like this is what you want. So lets say you have your content on the main_site. Run this on the ...


1

I'd personally go with WebHooks (or something similar). »Mitcho« already designed a plugin for that, called HookPress. Webhooks are a simple paradigm for developing instant notifications and mashups based on simple HTTP requests. With HookPress you can set up webhooks so that a specified URL (a public service or something you set up) is requested when ...


1

Facebook caches shared links. Maybe you/someone else tried sharing the site when it was still under development and it hasn't been updated on Facebook since. Try this: https://developers.facebook.com/tools/debug


1

If you experience such issues, examine the source code of the page, and search for the stylesheet used by Jetpack on the page: http://yoursite.com/wp-content/plugins/jetpack/modules/sharedaddy/admin-sharing.css You want to make sure that this URL can be accessed; if you use a caching service or plugin or if you have added redirection rules that impact this ...


1

Have you take a look at Options Page Add-on for Advanced Custom Field? http://www.advancedcustomfields.com/add-ons/options-page/ I created an option page for my client once where they enter promotion content once in that options page, and display that same information elsewhere via widget, shortcode, and PHP functions. It costs 25AUD but it's unlimited ...


1

You can update the sub sites when the main site is updated. Assuming your post IDs for the duplicated content remain the same as the same post in the main site you can write a plugin which runs only on the main site and with every save updates the sub sites add_action('save_post','wase87206_broadcast'); function wase87206_broadcast($post_id) { $mainurl =...


1

If your main requirement is to synchronise blog posts from a master site to a slave, then maybe look at the FeedWordPress plugin. It means that you would only add/edit posts on one website and they would be replicated to the other site. That will allow you to cleanly run different plugins on the two sites.


Only top voted, non community-wiki answers of a minimum length are eligible