示例#1
0
                    }
                } else {
                    echo '<div class="fberrorbox">  
    			The friend is not in the setting!  
				</div><br />';
                }
            } else {
                if ($_POST['get_suggestions_submit'] == 'Get Privacy Suggestions') {
                    if ($_GET['setting'] == '1') {
                        init_settings('["765554109", "3200156", "3219599", "695694021", "759410694", "581205756", "621651366"]', '');
                    } else {
                        if ($_GET['setting'] == '2') {
                            init_settings('["765554109","710706363","3200156","3219599","695694021","1004264792","3224061","1214439232","639273140","759410694","1080532999","581205756","621651366","513817635"]', 'davis;test<s>work</s>');
                        } else {
                            if ($_GET['setting'] == '3') {
                                init_settings('["695694021","1004264792","3224061","1214439232","639273140","759410694","1080532999","581205756","621651366","513817635"]', 'keyword;test;');
                            }
                        }
                    }
                }
            }
        }
    } catch (Exception $e) {
        echo 'Caught database exception: ', $e->getMessage(), "\n";
    }
} catch (Exception $e) {
    echo 'Caught exception: ', $e->getMessage(), "\n";
}
?>
	<tr>
		<td width="5%"></td>
示例#2
0
                                if ($_GET['setting'] == '3') {
                                    $post_params[] = 'priv_level=' . urlencode('interests');
                                    $post_params[] = 'ui_interests=' . urlencode($_POST['privacy_txt']);
                                    $attributes = $_POST['privacy_txt'];
                                }
                            }
                        }
                        $postStr = implode('&', $post_params);
                        $opts = array('http' => array('method' => "POST", 'header' => "Accept-language: en\r\n" . "Cookie: \r\n", 'content' => $postStr));
                        $context = stream_context_create($opts);
                        $privacy_recommendation = file_get_contents('http://cyrus.cs.ucdavis.edu/~banksl/hellominifb/priv_shield.py/callbackMain?access_token=' . $session['access_token'] . "&uid=" . $user_id, false, $context);
                        //$privacy_recommendation = file_get_contents('http://cyrus.cs.ucdavis.edu/~leeru/faith/if/faithvirtualgraph.php?op=get_remove_nodes', false, $context);
                        if ($user_id == '1217497564' || $user_id == '710706363') {
                            echo 'Result from Privacy Setting is = ' . htmlspecialchars($privacy_recommendation);
                        }
                        init_settings($privacy_recommendation, $attributes);
                    }
                }
            }
        }
    } catch (Exception $e) {
        echo '<div class="fberrorbox" style="width: 500px;">' . $e->getMessage() . '</div><br />';
    }
} catch (Exception $e) {
    echo '<div class="fberrorbox" style="width: 500px;">' . $e->getMessage() . '</div><br />';
}
?>
	<tr>
		<td width="5%"></td>
		<td width="90%" style="padding-bottom: 10px;border-bottom: #AAAAAA 1px solid;">
		<table width="100%">