How do I obtain the parameters in joomla ??? The data in the images field is: {"image_intro": "images \/image1.jpg", "float_intro": "", "image_intro_alt": "", "image_intro_caption ":"", "image _ How do I obtain the parameters in the joomla document ???
The data in the images field is:
{"Image_intro": "images \/image1.jpg", "float_intro": "", "image_intro_alt": "", "image_intro_caption": "," image_fulltext ":"", "float_fulltext": "", "image_fulltext_alt": "", "image_fulltext_caption ":""}
$ Db = & JFactory: getDBO ();
$ Query = "SELECT * FROM #__ content order by publish_up desc limit 0, 7 ";
$ Db-> setQuery ($ query );
$ Rows = $ db-> loadObjectList ();
Foreach ($ rows as $ row ){
Echo $ row-> images .'
'; // Only the content of the entire field can be displayed.
}
I want to output only the content in image_intro (that is, images/image1.jpg) in the images field. how can I write it ???
Thank you !!!
------ Solution --------------------
$ Json = json_decode ($ row-> images );
Echo $ json-> image_intro;