Simple Fields
[resolved] How can I call these fields value on a them template.. (4 posts)

  1. Sudhanshu Dubey
    Posted 3 years ago #


    I found this plugin good but somewhere I got stuck ..Like you didn't mentioned that how can people can call on post,page or even on the template file of theme.Like as for now I have created two many images and made two section repeatedly.and again putted many images in that.Now what I need how to call on template in a loop so that they all could be visible on my front page coming through a template..

    Before of this I have asked another question.Please take me out from this problem..



  2. Pär Thernström
    Plugin Author

    Posted 3 years ago #

    Yes, the documentation is lacking in some areas. Sorry about that..

    One simple way to add your images to your posts on the front end is to modify your functions.php and add something similar:

    function add_simple_fields_to_content($content) {
    	$images = simple_fields_values('your_images_slug');
    	if ( empty( $images ) ) return $content;
    	foreach ($images as $image_id) {
    		$content .= sprintf(
    			wp_get_attachment_image($image_id, NULL, TRUE)
    	return $content;
    add_action("the_content", "add_simple_fields_to_content");

    You may have to modify it a bit to suit your needs, but it should be a good starting point. Good luck!

  3. Sudhanshu Dubey
    Posted 3 years ago #

    Hi Pär Thernström,

    I am a new in WordPress,But I think you didn't addressed my requirements properly as what I need is:
    1.Multiple group of slection at a time that contains different fields on a single post.Like I have made two groups
    1.single->contains some fields
    2.Doulble->conteins some different fields.

    I want to show both group fields at a time on a single post.

    2.How can I call all fields values on a template not only image field but all fields values and I can't use featured image option in this ..Please help me.


  4. Sudhanshu Dubey
    Posted 3 years ago #

    I got the solution thanks!!

    you will get all the stuffs from here :


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Simple Fields
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic