After days of trying I managed to fix it myself.
Instead of using update_post_meta, I just did this:
$_POST[ "yoast_wpseo_metadesc" ] = $intro_y;
It works perfectly.
Hope this can help someone.
Related Posts:
- How to use max and min values of custom fields
- ACF not showing
- How to retrieve the values of a sub-field in the first and last row of an (ACF) repeater inside function?
- Perform function on publish AND save (not just save)
- Reference multiple style sheets, clearing styles for permalink page, custom fields for css
- update_post_meta not working in function
- How to display custom field in woocommerce orders in admin panel?
- Programatically add options to “add new” custom field dropdown
- Get a list of all available fields in the User Profile
- functions.php inject inline css
- Enabling shortcodes for custom fields
- Show/hide Widgets in Dashboard Based on Current Advanced Custom Fields Option
- Add options to featured image
- Is checking whether the blog is installed necessary?
- Authors details such as social media links, emails etc → Is this Meta or something else?
- Assign category using custom field?
- Function to Download External Images to My Site
- Checked() showing up twice in custom fields
- Woocommerce Storefront WordPress Ignore Media Gallery Images and use External 3rd Party Host
- Customizer field value into functions.php variable
- Adding multiple taxonomy filters to functions.php
- Auto delete post if certain custom field data is empty
- Retrieve tags data in post body
- Having issues with a foreach inside of a shortcode with ACF gallery
- How to display custom option field in woocommerce orders in admin panel?
- How to add a slide toggle to the Woocommerce-Layout__Activity-Panel area in the orders admin page
- Get Current Post ID in functions php, meta query filter
- What WordPress function to use to get meta value by using meta keys?
- Change label for registration Fields
- Custom Attachment Caption Fields
- Default Custom Field Value Automatically Update
- WordPress function saves a post twice and updates all posts
- Redirect to another page using contact form 7? [closed]
- Retrieve a value from Yoast SEO to use to set a default twitter card image honoring overrides
- How to get correct value from checked()?
- Prevent custom field from being updated after first publish
- Filter yoast canonical add_action priority [closed]
- Adding class to last list item? Not WP generated
- Add php code to wp_print_scripts?
- How to inherit field value from parent post into in child / sub post
- Access category within rss2_head hook?
- Show ACF field with link to ultimate member profile/WordPress user profile below the post (single post layout)
- Can set_post_thumbnail be used to remove a thumbnail?
- Compare meta key to current date in pre get post
- Insert Address fields into function
- Problem with adding custom CSS class to image in ACF Photo Gallery plugin [closed]
- How to make custom comment fields required
- How add body_class from wp_termmeta
- Using two loops in one WordPress template
- How do I display a date correctly that is stored in the database as a backwards 8 digit number from Advanced Custom Fields? [closed]
- Sort and display pages with specific custom field (not tag)
- shorthand syntax for custom fields
- Insert a field with PREG_REPLACE – strange behaviour
- Fill empty custom field with other custom field
- Excerpt length: get first paragraph
- Display ACF category image on archive and single template files
- How to Display WooCommerce Product Price in WooCommerce Archive
- How to change text color depending on the number value (Using javascript)
- Delete images from media library when user deletes an image from ACF Gallery
- Featured Image and Tags problem
- Override a Post’s URL with Advanced Custom Fields Function
- WordPress Function Assistance with Loop
- How to show ACF value under post/page title in wp-admin
- How to display an image before title text in menu items
- wp_set_object_term via js btn frontend
- Filter works on last selection but no others
- Populate Product Regular Price with a calculated ACF Field Value
- How to update an image attachment’s alt text from a custom field when saving a post?
- Help with with my function for wordpress
- ACF Date Form in Custom Admin Field
- Assign IDs to headings in ACF using functions.php
- How Can I Concatenate A String With One Of My Custom Field Value Before Saving The Post?
- Create New User Custom Field not Saving
- get_field() with ID in one signal filter not working
- Creating a “Related Meta” type field?
- How would I correctly implement a new if statement in a child functions file?
- Hide empty custom field
- Echo a String Based On Geolocation? [Woocommerce || ACF]
- Comment function for page
- ACF Filter return value
- How To Show Shortcodes In WordPress Custom Fields?
- Return ACF Field value function
- How to echo the translated custom field?
- How to add function to custom fields when page/post has a password?
- Providing fallback function and allow override by plugin
- How to exclude posts with empty and non-existent relational custom field with meta_query?
- Post date on Custom field
- Different body image backgrounds on different pages, posts and categories
- Dynamically generated Navigation Diagram using Custom Fields
- Define an extra field for all pages (with no plugin?)
- How to display data from custom fields in my custom shortcode?
- Syling Custom Fields echo’s from from functions.php
- does acf_save_post cause endless loop?
- Add custom fields after post/page title
- ACF Date fileds to Age Convert [closed]
- Call ACF data from functions.php [closed]
- Adding and updating repeating custom field meta data
- Change Post status based on custom field date +1 day
- Update post meta with wp cron
- ACF number less than comparison not working