blacknight9
Newbie
- Jan 1, 2009
- 44
- 38
First off, I am not ripping other people's code. The information provided here can be found using Google
D) If this is now allowed, please delete.
The result is similar to: http://hiderefer.org/?http://www.facebook.com/pages/Spotify-Remove-Commercial-Hack-No-More-Disturbing-Commercial/364881740375
I am not giving you the whole code to paste but I'll show you how to achieve the key elements
1. Search for "Static FBML" and add it to your page.
2. Edit your page, click to edit "Static FBML" and paste the code, you need to know html too (remember to replace XXXs with your page id)
That's it, you have to layout the page yourself. HTML is required.
References
The result is similar to: http://hiderefer.org/?http://www.facebook.com/pages/Spotify-Remove-Commercial-Hack-No-More-Disturbing-Commercial/364881740375
I am not giving you the whole code to paste but I'll show you how to achieve the key elements
1. Search for "Static FBML" and add it to your page.
2. Edit your page, click to edit "Static FBML" and paste the code, you need to know html too (remember to replace XXXs with your page id)
- The become fan button
Code:<span id="profile_connect"> <a ajaxify="/ajax/pages/fan_status.php?fbpage_id=XXX&add=1&reload=1&preserve_tab=1&use_primer=1" rel="async-post" class="UIButton UIButton_Gray UIActionButton" href="#"><span class="UIButton_Text"><span class="UIButton_Icon UIButton_IconNoSpriteMap" style="background-position: 0pt -410px;"></span>Become a Fan</span></a></span>
You'll want step 2 visible to fan only. Once they click it, the content in step 2 will be revealed.
Code:<fb:visible-to-connection> Put content of your step 2 and 3 here </fb:visible-to-connection> - The friend invitation popup
Code:<a href="#" ajaxify="/ajax/social_graph/invite_dialog.php?class=FanManager&node_id=XXX" class=" profile_action actionspro_a" rel="dialog-post">Click here to invite your friend</a> - dialog popup
Code:<a href="#" style="border-top: 1px solid #ffffff;" clicktoshowdialog="Code">click here to show pop up dialog</a> <fb:dialog id="Code"> <fb:dialog-title>How To Invite Friends Quickly</fb:dialog-title> <fb:dialog-content> Your dialog content here </fb:dialog-content> <fb:dialog-button type="button" value="Okay" close_dialog="1"/> </fb:dialog> - Update! Sorry guys, and this is the download button
Code:<a id="tobehidden" onClick="outside_location.setInnerFBML(link_1);" style="cursor: pointer;">Download now</a> <div id="outside_location"></div> <fb:js-string var="link_1"> <fb:iframe height="500" allowTransparency="true" frameborder="0" scrolling="no" style="width:100%; border:none" src="http://URL-TO-OUTSIDE-LOCATION"></fb:iframe> </fb:js-string> <script type="text/javascript" charset="utf-8"> var outside_location = document.getElementById('outside_location'); tobehidden=document.getElementById('tobehidden'); tobehidden.setStyle('display', 'none'); </script> - Update! I've got some PMs regarding comments. Here's how:
Code:<div class="UIIntentionalStream_Content UIStream"> <div id="div_story_840890611_333846711183" class="GenericStory UIStory clearfix aid_548388434"> <div class="GenericStory_Body"> <form name="add_comment" id="commentable_item_840890611_333846711183" class="commentable_item one_row_add_box autoexpand_mode comment_form_333846711183"> </span> <div class="comment_box"> <div class="comment_box_nub"></div> <div class="like_box"></div> <div class="feed_comments"> [COLOR="Red"]<div class="ufi_section UIImageBlock clearfix" id="comment_840890611_333846711183_11812702"> <a href="#" class="UIImageBlock_Image UIImageBlock_SMALL_Image" title="XXX"><img class="UIProfileImage UIProfileImage_SMALL img" src="IMAGE_URL" alt="XXX"></a> <div class="UIImageBlock_Content UIImageBlock_SMALL_Content"> <div class="comment_text"><a href="XXX" class="comment_author">Commentors' Name</a> <div id="text_expose_id_4b8c7ea8398de511da3ca" class="comment_actual_text">This is a very long comment that you need to relace</div> </div> <div class="comment_actions"><abbr class="timestamp" title="Mon, 01 Mar 2009 16:50:49 -0800">2 hours ago</abbr></div> </div> </div>[/COLOR] </div> <div class="ufi_section comments_add_box clearfix"> <textarea name="add_comment_text" class="add_comment_text DOMControl_placeholder" placeholder="Write a comment...">Write a comment...</textarea> <img class="UIProfileImage UIProfileImage_SMALL img" src="IMAGE_URL"><span class="comments_add_box_submit clearfix UIButton UIButton_Blue UIFormButton"> <input value="Comment" type="submit" class="UIButton_Text" name="comment"> </span></div> </div> </form> </div> </div> </div>
Duplicate the part in red to add a new comment, you'll need to put in some thumbnail url.
That's it, you have to layout the page yourself. HTML is required.
References
Code:
http://w3.hyperarts.c0m/blog/tutorial-facebook-pages-with-static-fbml-application/
http://w3.developers.facebook.com/index.php/FBML
Last edited: