コード例 #1
0
     switch ($layout_id) {
         case 1:
             $layout = new normal($image_array);
             fwrite($fh, "Loaded normal profile\n");
             break;
         case 2:
             $layout = new block($image_array);
             fwrite($fh, "Loaded block profile\n");
             break;
         default:
             $layout = new normal($image_array);
             fwrite($fh, "Loaded normal profile\n");
             break;
     }
     fwrite($fh, "Drawing profile\n");
     $profile_fbml = $layout->draw_profile($fb_id);
     fwrite($fh, "Drawn profile\n");
 } else {
     $profile_fbml = "Unknown Zooomr ID '" . $zooomr_id . "'<br> Maybe you need some <a href='http://apps.facebook.com/zooomr_rss_reader/help.php5'>help?</a>";
 }
 $return_code;
 try {
     //if ($facebook->api_client->users_isAppAdded())
     //{
     // Now you can update FBML pages, update your fb:ref tags, etc.
     //$return_code = $facebook->api_client->profile_setFBML($profile_fbml, $fb_id);
     $return_code = $facebook->api_client->profile_setFBML(null, $fb_id, $profile_fbml);
     $temp_code = print_r($return_code, TRUE);
     //$return_code = $facebook->api_client->profile_setFBML(, microtime(true), 'profile FBML here', 'profile action fbml here', 'mobile fbml here');
     //}
     //else
コード例 #2
0
            $image = new zooomr_image($item['description'] . "<br />" . $item['title']);
            array_push($image_array, $image);
        }
        $layout;
        switch ($layout_id) {
            case 1:
                $layout = new normal($image_array);
                break;
            case 2:
                $layout = new block($image_array);
                break;
            default:
                $layout = new normal($image_array);
                break;
        }
        $profile_fbml = $layout->draw_profile($page_viewer);
        $full_page_fbml = '<fb:header>Zooomr RSS Feed Reader: <a href="http://www.zooomr.com/photos/' . $zooomr_id . '">' . $rss->channel['title'] . '</a></fb:header><div style="margin:0 10px 0 10px;">';
        //$full_page_fbml .= $layout->draw_app($user) . '</div>';
        if ($user == $page_viewer) {
            $full_page_fbml .= $layout->draw_app($page_viewer, 0) . '</div>';
        } else {
            $full_page_fbml .= $layout->draw_app($page_viewer, 1) . '</div>';
        }
    } else {
        $full_page_fbml = show_app_error("Unknown Zooomr ID " . $zooomr_id . ".  Maybe you need some <a href='http://apps.facebook.com/zooomr_rss_reader/help.php5'>help?</a>");
        if ($user == $page_viewer) {
            $full_page_fbml .= draw_form($user);
        }
        $profile_fbml = show_profile_error("Unknown Zooomr ID " . $zooomr_id . ".  Maybe you need some <a href='http://apps.facebook.com/zooomr_rss_reader/help.php5'>help?</a>");
    }
}