Home › Forums › ACF PRO › Display json along with acf. › Reply To: Display json along with acf.
My question is: How could I manipulate the information. Ex:
If the biography does not exist, how could I type it manually? I wanted to save this data received within acf. I can display all the information perfectly. However, I can not manipulate and edit the data I received. Can you point the way?
<?php //field is ID $url = 'https://api.themoviedb.org/3/person/'.get_field('api').'?api_key=f16d933a3e68465c1ef9a4a82b41a2d5&language=pt-BR'; $contents = file_get_contents($url); $person=json_decode($contents); $personname = $person->name; $biography = $person->biography; $profile_path=$person->profile_path; echo $personname . "<br>"; echo "<img src='https://image.tmdb.org/t/p/w600_and_h900_bestv2/" . $profile_path ."'/ >"; echo $biography = the_field('biography'); ?>
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
Are you building WordPress sites with ACF and @BeaverBuilder, and wanted to use your ACF Blocks in both the block editor and Beaver Builder?— Advanced Custom Fields (@wp_acf) May 10, 2023
The BB team recently added support for using ACF Blocks in Beaver Builder. Check it out 👇https://t.co/UalEIa5aQi
© 2023 Advanced Custom Fields.