Hello
I'm trying to insert a meta data of a custom post from customers frontend.
In a backend I use yoast to complete metadata of custom, but I'd like to know if you have some way to integrate yoast automatically from frontend.
I'd like to integrate a field in the same custom form that automatically insert meta data.
Thank you for any help about this task
Regards
Hello
Thank you for help me with this task, I saw the link you shared with me and I found field create for other plugin, but unfortunally I couldn't find field of yoast .
Do you have some idea how and where I can find it ?
Best regards
Thank you I checked on the site and it seems that you're not allowing the editing of files through your backend.
However you will perhaps need to try using this code below.
/** * Make all post types available on Forms screen to manage non-Types fields */
add_filter( 'option_wpcf-custom-types', 'ts_blank_cpt_option' ); function ts_blank_cpt_option( $option ){
$screen = get_current_screen();
if ( isset( $screen ) && $screen->id == 'toolset_page_CRED_Fields' ) { $option = false; }
return $option; }
This will make all the post types visible on the manage non-Types fields .
If you're able to add this code to your theme's functions.php and then check on the manage non-Types fields screen and see if your CPT shows up and then start searching for the yoast fields.
Please let me know once you've done this.
Thanks,
Shane
Hi Shane
I tried to add the code to function.php on backend theme but after that the site stop to work and to fix I had to deleted the code I added.
Do you have some Idea?
I use generatepress theme
thank you
many regards
Given that the code is meant to run only on the backend we will need to add a filter to ensure that happens.
Usually this is done when you add the custom code to Toolset->Settings-> Custom Code and set the run context to Admin Only. However given that you've restricted the permissions of your server I wasn't able to add the code here and set the context.
Try using this code below that should set the context of the code.
Hi Again,
I added the code you sent me in toolset - > settings - > Custom code after modify wp-config to have access to edit area.
I saved and then I went in Post Form and manage not toolset field but can't see anything of yoast
Do you have some Idea?
I didn't restrict your access and you want I can share credential of my website to check why it is doing like so.
Is this private area where I can share credential with you?
Hi
thank you, now there is something more even I don't know which is the field I have to use
here is a screenshoot about not toolset fields I can see now. Which is the one about meta title and meta description? How I have to use with this function?
In order for some of the fields to show up you would've need to populate the fields manually at least once so it can be picked up by our plugin.
I went ahead and did this on one of your post and removed the test data but the fields below should now be available for you to select.
_yoast_wpseo_metadesc
_yoast_wpseo_title
I've confirmed that they are now showing up and you should now be able to add it to your form.
Ok many thanks, Finally I found yoast meta description and title, I'm happy now to continue with my project.
Can I ask you about relationship between 2 custom post type?
Regards
Hello Shane,
It's working but I'm noticing something that is not working properly on view loop after that modify:
It's stop to working dynamic choose in Heading, Single field, conditional block.
It's not possible to set dynamic choose from custom of current custom type.
It could be possible it's correlate with modify on filter I added to show in admin non toolset field like yoast field?
Could you help me to fix the problem without loose the possibility to see yoast field?
Many thanks
regards