Profile Boxes in Java

Creation QR Code in Java Profile Boxes
Profile Boxes
QR Code Drawer In Java
Using Barcode maker for Java Control to generate, create QR-Code image in Java applications.
As discussed in 1, Facebook Applications:The Basics, there are three kinds of profile boxes: Main,Wide, and Narrow Main profile boxes appear on the left of the Wall and Info tabs of the profile, and they are limited to 184px wide 250px high Only four of these profile boxes can appear at a time; as additional boxes are added, the oldest ones are moved to the Boxes tab Narrow and Wide profile boxes appear on the Boxes tabThe Narrow and Wide designation is for on which side of the page they appearThe left side is Wide, with a width of 380pxThe right side is Narrow, with a width of 184px Both sides have no height limit Figure 81 shows the various profile box sizes Users can move a profile box between the Wall and Boxes tabs by clicking the blue pencil in the top-right corner of the profile box and clicking Move to X Tab Users move a box between the Wide and Narrow sides of the Boxes tab by dragging and dropping it Content inside a <fb:narrow> tag only shows up when the profile box is on the Narrow side, while content in a <fb:wide> tag only shows up on the Wide sideA good profile box should support all these locations by displaying content formatted appropriately for the context All profile boxes are FBML based However, Facebook specifically disallows profiles from using IFrames and from anything automatically playing, such as Flash or JavaScript Users must first interact with the profile content before it can become active Profile box content is set by the application using the profilesetFBML() application programming interface (API) call Listing 81 shows a sample call Notice that the Main
Create Barcode In Java
Using Barcode generator for Java Control to generate, create bar code image in Java applications.
8 Updating the Profile
Decode Barcode In Java
Using Barcode recognizer for Java Control to read, scan read, scan image in Java applications.
profile box FBML is passed separately from the Narrow and Wide FBMLThe $markup and $profileAction parameters have been deprecated, so NULL should always be passed for theseTable 81 shows the parameters of the PHP Client Library s
Encode QR Code ISO/IEC18004 In Visual C#.NET
Using Barcode drawer for .NET framework Control to generate, create QR Code ISO/IEC18004 image in .NET applications.
profile_setFBML()
QR Code JIS X 0510 Drawer In .NET Framework
Using Barcode generator for ASP.NET Control to generate, create QR image in ASP.NET applications.
380px
Create Quick Response Code In VS .NET
Using Barcode printer for VS .NET Control to generate, create Denso QR Bar Code image in Visual Studio .NET applications.
184px
QR Code ISO/IEC18004 Creator In VB.NET
Using Barcode creator for Visual Studio .NET Control to generate, create Denso QR Bar Code image in VS .NET applications.
184px
GS1 - 13 Maker In Java
Using Barcode creation for Java Control to generate, create European Article Number 13 image in Java applications.
250px
Bar Code Creation In Java
Using Barcode maker for Java Control to generate, create bar code image in Java applications.
Size constraints of the different profile boxes
Make Barcode In Java
Using Barcode printer for Java Control to generate, create bar code image in Java applications.
Table 81
Draw Data Matrix 2d Barcode In Java
Using Barcode generation for Java Control to generate, create Data Matrix image in Java applications.
profile_setFBML() Parameters Type
Drawing Bar Code In Java
Using Barcode maker for Java Control to generate, create barcode image in Java applications.
string int string string string string
Encoding 4-State Customer Barcode In Java
Using Barcode maker for Java Control to generate, create OneCode image in Java applications.
Parameter Name
Bar Code Creator In .NET
Using Barcode creator for ASP.NET Control to generate, create bar code image in ASP.NET applications.
markup uid
Scanning Barcode In Java
Using Barcode scanner for Java Control to read, scan read, scan image in Java applications.
Details
Code 128 Code Set A Creator In VB.NET
Using Barcode drawer for Visual Studio .NET Control to generate, create Code 128B image in VS .NET applications.
Deprecated Always pass NULL The user ID for the user or Public Profile to update, defaulting to the current user The FBML for the profile box on the Boxes tab Deprecated Always pass NULL The FBML that appears on http://mfacebookcom The FBML that appears on the Wall tab, called the Main profile box
Painting Barcode In VB.NET
Using Barcode generation for VS .NET Control to generate, create barcode image in .NET framework applications.
profile profile_action mobile_profile profile_main
Code 128 Code Set C Drawer In C#.NET
Using Barcode creation for .NET Control to generate, create Code 128C image in .NET framework applications.
Profile Boxes
Making Bar Code In VB.NET
Using Barcode creation for .NET framework Control to generate, create bar code image in VS .NET applications.
Listing 81
Bar Code Printer In Visual C#
Using Barcode creation for .NET framework Control to generate, create bar code image in VS .NET applications.
Example of Setting the Profile FBML
$markup = NULL; $mainFBML = "Appears on Wall tab"; $profileFBML = " <fb:narrow>Appears on narrow side</fb:narrow> <fb:wide>Appears on wide side</fb:wide>"; $mobileFBML = " <fb:mobile>Appears on mfacebookcom</fb:mobile>"; $profileAction = NULL; $facebook = new Facebook(FB_API_KEY, FB_APP_SECRET); $facebook->api_client->profile_setFBML($markup, $appUserID, $profileFBML, $profileAction, $mobileFBML, $mainFBML);
Creating the Compliments Profile Boxes
We will update the Compliments application to use all the profile boxes and then go through each part of the changesThe Compliments profile boxes let viewers send the owner a complimentWhen the user clicks the Send button, he is taken to the application canvas page to see that his compliment has been sent Figures 82 and 83 show the Main profile and Wide profile boxes
Compliments Main profile box
The first step is to add a call to a new function, updateProfileBox(), to indexphp and index_iframephpAdd the following line just before renderPage():
updateProfileBox( $facebook->user );
8 Updating the Profile
Compliments Wide profile box
Defining the Profile Box Utility Functions Next, create a new file called profileinc in the inc directory, and add the source from Listing 82 into itThis file contains all the code relating to creating profile content and updating it on FacebookAdd the following line to the top of indexphp and index_iframephp to include this new file:
require_once 'inc/profileinc';
Listing 82
profileinc: Profile Box Utility Functions
< php /** Updates the profile box for a user with the latest content for that user **/ function updateProfileBox($appUserID){ $facebook = new Facebook(FB_API_KEY, FB_APP_SECRET); $generatedProfileFBML = generateProfileBoxFBML($appUserID); $profileFBML = $generatedProfileFBML['profile']; $mainFBML = $generatedProfileFBML['main']; try { $facebook->api_client->profile_setFBML(NULL, $appUserID, $profileFBML, NULL, NULL, $mainFBML); } catch (Exception $ex) { wr("<Exception: uid: $appUserID - " $ex->getMessage() ">" ); return false; } return true; } /** Generates the profile box FBML for a user */ function generateProfileBoxFBML($appUserID) { global $g_categories;