Support » Developing with WordPress » How to set position of post when you get data from rss feed?

  • Hi all,

    Greetings from me !!

    I want to make a when you publish the post then we have migrated that post in another site. but I want to post on the specific position like 3, 5 and etc..

    Is it possible?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator bcworkz

    (@bcworkz)

    You haven’t given much detail, but generally speaking, the 2 servers need to communicate with each other. This can be done many ways. A good option is to communicate through /wp-admin/admin-post.php. The code hooked into the action created from the passed “action” data item is what does all the work. Other data can be transmitted by any convenient format. JSON would be a good choice.

    Displaying content at particular positions as the Loop progresses is a matter of adding counter to the loop or using WP_Query::current_post, which is a counter itself. When the remainder of an integer division operation on the counter equals a certain value, output the content. For example: if ( 2 == $counter % 3 ) echo 'Special content goes here';

    Hello,

    I need a like post below we have to give options as site name and position of that post.

    once parent site published post then it will reflect other all website.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to set position of post when you get data from rss feed?’ is closed to new replies.