PHP and jQuery to create : facebook post to wall system

Sharing is caring!

Assuming that you have not perused our past post on making a Facebook post to divider framework then you might as well read it first. In this article, we will demonstrate how I included code antiquated bind” for the purpose that when clicked, it will post the substance of the content range as divider post.

HOW IT WORKS ?

When you click on “share” button :

The file insert.php is called via ajax to save message in database, if message is saved successfully , then add message to the unordered list like below:

<ul id=”posts”>
<li>My wall post message </li>
</ul>

Jquery code below is used to add the message as list :
$(‘ul#posts’).prepend(‘My wall post message’);

The textarea message is then cleared
$(‘textarea#wall’).val(”);

If another message is shared on the wall , it is added on the dom like this :
<ul id=”posts”>
<li>This is my second post </li>
<li>My wall post message </li>
</ul>

Download Files

Leave a Reply

Your email address will not be published. Required fields are marked *

Got Project on mind? Let's ConnectContact Us

Secured By miniOrange