Skip Navigation

[Resolved] Update Php with new API. Help me!!!

This support ticket is created 3 years, 7 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 - - 9:00 – 13:00
14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 - - 14:00 – 18:00

Supporter timezone: Africa/Casablanca (GMT+01:00)

This topic contains 1 reply, has 2 voices.

Last updated by Jamal 3 years, 7 months ago.

Assisted by: Jamal.

Author
Posts
#2008771
Schermata 2021-04-02 alle 22.31.50.png
Schermata 2021-04-02 alle 22.31.56.png

Hi,
please help me upgrade to version 3 of the plugin. The screen that I am attaching appears to me and how to see there is some obsolete code that I paste in this ticket.

Two questions:

1)
File del tema file: /jupiter-child/views/singular/wp-single-media.php - line 157, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/---wp-single-osservatorio.php - line 162, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/----wp-single-news.php - line 157, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-ricerca-bk.php - line 104, column 41 _wpcf_belongs_ricerca-rapporto_id',
File del tema file: /jupiter-child/views/singular/wp-single-ricerca-bk.php - line 140, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-evento.php - line 155, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-documenti.php - line 70, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-osservatorio.php - line 167, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-ricerca-reader.php - line 133, column 41 _wpcf_belongs_ricerca-rapporto_id',
File del tema file: /jupiter-child/views/singular/wp-single-ricerca-reader.php - line 206, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/views/singular/wp-single-ricerca.php - line 136, column 41 _wpcf_belongs_ricerca-rapporto_id',
File del tema file: /jupiter-child/views/singular/wp-single-ricerca.php - line 211, column 47 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/functions.php - line 168, column 44 _wpcf_belongs_categoria_ricerche_id
File del tema file: /jupiter-child/functions.php - line 200, column 48 _wpcf_belongs_news_category_id');

How exactly should these codes be changed? I had built my layouts all from php with your API. I'm not a developer it took me a long time, I need to figure out how to replace exactly that code, I can also send you some files or give you FTP access. Without making the transition I cannot create the grouped fields.

$post_type = get_post_meta( $post_id, '_wpcf_belongs_categoria_ricerche_id', true);
'meta_query' => array(array('key' => '_wpcf_belongs_ricerca-rapporto_id', 'value' => get_the_ID()))

2)
What should I select on "Articles without a version in the default language" in the attached screen?
It's not very clear ... will content be deleted? Will content be duplicated? In which case?

Thanks

#2009053

Hello and thank you for contacting the Toolset support.

Toolset Types 2.x relied on a custom field to handle one-to-many relationships, the custom field was named as follows: _wpcf_belongs_{relationship_slug}_id
Starting from Types 3.x new database tables were introduced to handle the relationships instead of custom fields. Check this article on how to migrate your existing PHP code to the new database schema
https://toolset.com/documentation/customizing-sites-using-php/post-relationships-api/how-to-migrate-your-site-to-new-post-relationships/

Regarding the 2nd point, it will depend on how you use WPML. If you always publish in the primary language then translate to other languages, you can safely choose that option. But if you publish in the secondary languages without systematically having an original post in the primary language, you should not choose that option.