Submit form in Recent Post
-
I understand on how to submit a form as post. I can also select certain form data (labels and items) to be displayed. But this only applies to posting a Page by using slug. If I post 10 Pages I should insert the slug 10 times. I would like certain labels and items to be displayed in Recent Post. So, when my students submit a form, the data in selected label-item will be displayed in Recent Post. I got headache in tweaking the code of custom template. I tried the following code but with no luck: I have 10 labels, the results are each label with item (title, author, abstract) appear 10 times (total: 30). Unselected labels disappear.
<ul id="fm-summary-multi"> <?php while(fm_summary_have_items()): fm_summary_the_item(); ?> <?php if(fm_summary_the_type() == 'separator'): ?> <hr /> <?php elseif(fm_summary_has_data()): ?> <li<?php if(fm_summary_the_nickname() != "") echo " id=\"fm-item-".fm_summary_the_nickname()."\"";?>><?php echo fm_summary_get_item_label('title');?>: <strong><?php echo fm_summary_get_item_value('title');?></strong> <li<?php if(fm_summary_the_nickname() != "") echo " id=\"fm-item-".fm_summary_the_nickname()."\"";?>><?php echo fm_summary_get_item_label('author');?>: <strong><?php echo fm_summary_get_item_value('author');?></strong> <li<?php if(fm_summary_the_nickname() != "") echo " id=\"fm-item-".fm_summary_the_nickname()."\"";?>><?php echo fm_summary_get_item_label('abstract');?>: <strong><?php echo fm_summary_get_item_value('abstract');?></strong> <?php endif; ?> <?php endwhile; ?> <hr />
I also tried to remove the following code in the second and third selected label-item (author, abstract) but the result are the same (=30 label-item).
<?php if(fm_summary_the_nickname() != "") echo " id=\"fm-item-".fm_summary_the_nickname()."\"";?>
Please help me.
http://wordpress.org/extend/plugins/wordpress-form-manager/
[Moderator Note: Please post code or markup snippets between backticks or use the code button. As it stands, your posted code may now have been permanently damaged/corrupted by the forum’s parser.]
- The topic ‘Submit form in Recent Post’ is closed to new replies.