Title: [Plugin: WordPress SEO by Yoast] Set Description with PHP
Last modified: August 20, 2016

---

# [Plugin: WordPress SEO by Yoast] Set Description with PHP

 *  [forexfilms.com](https://wordpress.org/support/users/forexfilmscom/)
 * (@forexfilmscom)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/plugin-wordpress-seo-by-yoast-set-description-with-php/)
 * I’m adding to post meta for WPSEO with the code below
 *     ```
       update_post_meta($post_id, '_yoast_wpseo_focuskw', '');
       update_post_meta($post_id, '_yoast_wpseo_title', '');
       update_post_meta($post_id, '_yoast_wpseo_metadesc', $media->group->description);
       update_post_meta($post_id, '_yoast_wpseo_meta-robots-noindex', 0);
       update_post_meta($post_id, '_yoast_wpseo_meta-robots-nofollow', 0);
       update_post_meta($post_id, '_yoast_wpseo_meta-robots-adv', 'none');
       update_post_meta($post_id, '_yoast_wpseo_sitemap-include', '-');
       update_post_meta($post_id, '_yoast_wpseo_sitemap-prio', '-');
       update_post_meta($post_id, '_yoast_wpseo_canonical', '');
       update_post_meta($post_id, '_yoast_wpseo_redirect', '');
       ```
   
 * I get this error message in the edit post screen of wordpress
 * Warning: WPSEO_Metabox::do_meta_box() [wpseo-metabox.do-meta-box]: Node no longer
   exists in /…/wp-content/plugins/wordpress-seo/admin/class-metabox.php on line
   326
 * The metabox does not show the description from the sql database and I’m currently
   at a loss of where to go from here.
 * ANY IDEAS?
 * [http://wordpress.org/extend/plugins/wordpress-seo/](http://wordpress.org/extend/plugins/wordpress-seo/)

The topic ‘[Plugin: WordPress SEO by Yoast] Set Description with PHP’ is closed 
to new replies.

 * ![](https://ps.w.org/wordpress-seo/assets/icon-256x256.gif?rev=3419908)
 * [Yoast SEO - Advanced SEO with real-time guidance and built-in AI](https://wordpress.org/plugins/wordpress-seo/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-seo/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-seo/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-seo/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-seo/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-seo/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [forexfilms.com](https://wordpress.org/support/users/forexfilmscom/)
 * Last activity: [14 years, 4 months ago](https://wordpress.org/support/topic/plugin-wordpress-seo-by-yoast-set-description-with-php/)
 * Status: not resolved