|
|
|
อยากรู้วิธีการ login โดยใช้ account facebook ในการ login คับ |
|
|
|
|
|
|
|
มันบอกว่า มีปัญหาในการโหลดหน้าเว็ปคับป่ม
ช่วยทีคับ
|
|
|
|
|
Date :
2012-03-29 23:57:56 |
By :
ิbiggest59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
developers.facebook.com/docs/reference/plugins/login/
copy ไปวางครับ หรือไม่ก็ค้นหาคำว่า facebook login button
|
|
|
|
|
Date :
2012-03-30 00:13:42 |
By :
ikikkok |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
มันเเจ้งว่า รหัส API ไม่ถูกต้องครับ ควรทำอย่างไรดีคับป๋ม
|
|
|
|
|
Date :
2012-03-30 00:34:29 |
By :
ิbiggest59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Code (PHP)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<?php
$cryptinstall="crypt/cryptographp.fct.php";
include $cryptinstall;
// ถ้า user submit ฟอร์มมา
if( $_POST['ispostback'] ){
// ถ้าป้อน captcha มาถูกต้อง
if (chk_crypt($_POST['captcha'])){
echo "ถูกต้อง";
} else{
// ถ้าป้อน captcha ไม่ถูกต้อง
echo "ป้อน captcha ไม่ถูกต้อง ไม่ให้เก็บข้อมูลลงฐาน";
}
}
?>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<title>index</title>
<style type="text/css">
<!--
body {
background-image: url(images/Android_.jpg);
}
-->
</style>
<script src="SpryAssets/SpryValidationSelect.js" type="text/javascript"></script>
<script src="SpryAssets/SpryValidationTextField.js" type="text/javascript"></script>
<link href="SpryAssets/SpryValidationSelect.css" rel="stylesheet" type="text/css" />
<link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/th_TH/all.js#xfbml=1&appId=APP_ID";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<form id="form1" name="form1" method="post" action="check_log.php">
<table width="1052" border="0" align="center">
<tr>
<td width="549"> </td>
<td width="489">Email
<input type="text" name="txtUsername" id="txtUsername" />
Password
<input type="password" name="txtPassword" id="txtPassword" />
<input type="submit" name="button" id="button" value="LOGIN" />
<br />
<div class="fb-login-button" data-show-faces="true" data-width="200" data-max-rows="1"></div><br />
<br /></td>
</tr>
</table>
</form>
<form id="form2" name="form2" method="post" action="check_reg.php">
<table width="1052" border="จ" align="center">
<tr>
<td width="476"> </td>
<td width="162" align="right">ลงทะเบียน</td>
<td width="400"> </td>
</tr>
<tr>
<td> </td>
<td align="right">Sex</td>
<td>:
<label>
<select name="in_sex" size="1" id="in_sex">
<option>-Sex-</option>
<option>Male</option>
<option>Famale</option>
</select>
</label></td>
</tr>
<tr>
<td> </td>
<td align="right">Name</td>
<td>:
<label><span id="sprytextfield1">
<input type="text" name="in_name" id="in_name" />
* Please fill in English.
<span class="textfieldRequiredMsg">Please input Name.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Lastname</td>
<td>:
<label><span id="sprytextfield2">
<input type="text" name="in_last_n" id="in_last_n" />
* Please fill in English.
<span class="textfieldRequiredMsg">Please input Last Name.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Date</td>
<td>:
<select name="day">
<option>-DAY-</option>
<?
for($y=1;$y<=31;$y++) {
echo "<option value='$y'>$y</option>";
}
echo "</select>";
?>
</select>
<select name="mount">
<option>-MONTH-</option>
<?
$mount = array("1" => "January",
"2" => "February",
"3" => "March",
"4" => "April",
"5" => "May",
"6" => "June",
"7" => "July ",
"8" => "August",
"9" => "September",
"10" => "October",
"11" => "November",
"12" => "December");
for($im=1;$im<=12;++$im) echo "<option value='{$im}'>$mount[$im]</option>";
echo "selected=$mount ";
?>
</select>
<select name="year">
<option>-YEAR-</option>
<?
for($a=1890;$a<=2200;$a++) {
echo "<option value='$a'>$a</option>";
}
echo "</select>";
?>
</select></td>
</tr>
<tr>
<td> </td>
<td align="right">Email</td>
<td>:
<label><span id="sprytextfield4">
<input type="text" name="in_email" id="in_email" />
<span class="textfieldRequiredMsg">Please input Email.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Password</td>
<td>:
<label><span id="sprytextfield5">
<input type="password" name="in_pass" id="in_pass" />
<span class="textfieldRequiredMsg">Please input Password.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Confirm Password</td>
<td>:
<label><span id="sprytextfield6">
<input type="password" name="in_con_pass" id="in_con_pass" />
<span class="textfieldRequiredMsg">Please input Confirm Password.</span></span></label></td>
</tr>
<tr>
<td height="29"> </td>
<td align="right" valign="top">Captcha Verify </td>
<td align="left" valign="top"><label><?php dsp_crypt(0,1); ?> :
<span id="sprytextfield7">
<input type="text" name="in_captcha" id="in_captcha" />
<span class="textfieldRequiredMsg">Please input Confirm Captcha.</span></span><br />
</label></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td><label>
<input type="submit" name="button2" id="button2" value="ลงทะเบียน" />
<input type="reset" name="button3" id="button3" value="Reset" />
</label></td>
</tr>
</table>
<p> </p>
</form>
<script type="text/javascript">
<!--
var spryselect1 = new Spry.Widget.ValidationSelect("spryselect1");
var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1");
var sprytextfield2 = new Spry.Widget.ValidationTextField("sprytextfield2");
var sprytextfield3 = new Spry.Widget.ValidationTextField("sprytextfield3");
var sprytextfield4 = new Spry.Widget.ValidationTextField("sprytextfield4");
var sprytextfield5 = new Spry.Widget.ValidationTextField("sprytextfield5");
var sprytextfield6 = new Spry.Widget.ValidationTextField("sprytextfield6");
var sprytextfield7 = new Spry.Widget.ValidationTextField("sprytextfield7");
//-->
</script>
</body>
</html>
|
|
|
|
|
Date :
2012-03-30 00:40:17 |
By :
ิbiggest59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ต้องมี facebook app ก่อนนะครับ
appId=APP_ID
|
|
|
|
|
Date :
2012-03-30 00:54:17 |
By :
ikikkok |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ตอนนี้ใส่หมายเลข app id ไปเเว้ว
มันบอกว่า URL ที่ให้มาไม่ได้รับอนุญาตจากการกำหนดค่าของแอพพลิเคชัน
คือยังไงออคร้าฟ
|
|
|
|
|
Date :
2012-03-30 10:29:49 |
By :
ิbiggest59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
T_T! ผมงงไปหมดเเว้ว ช่วยทีครับ
Code (PHP)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<?php
$cryptinstall="crypt/cryptographp.fct.php";
include $cryptinstall;
// ถ้า user submit ฟอร์มมา
if( $_POST['ispostback'] ){
// ถ้าป้อน captcha มาถูกต้อง
if (chk_crypt($_POST['captcha'])){
echo "ถูกต้อง";
} else{
// ถ้าป้อน captcha ไม่ถูกต้อง
echo "ป้อน captcha ไม่ถูกต้อง ไม่ให้เก็บข้อมูลลงฐาน";
}
}
?>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<title>index</title>
<style type="text/css">
<!--
body {
background-image: url(images/Android_.jpg);
}
-->
</style>
<script src="SpryAssets/SpryValidationSelect.js" type="text/javascript"></script>
<script src="SpryAssets/SpryValidationTextField.js" type="text/javascript"></script>
<link href="SpryAssets/SpryValidationSelect.css" rel="stylesheet" type="text/css" />
<link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/th_TH/all.js#xfbml=1&appId=352883581413436";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<form id="form1" name="form1" method="post" action="check_log.php">
<table width="1052" border="0" align="center">
<tr>
<td width="549"> </td>
<td width="489">Email
<input type="text" name="txtUsername" id="txtUsername" />
Password
<input type="password" name="txtPassword" id="txtPassword" />
<input type="submit" name="button" id="button" value="LOGIN" />
<br />
<div class="fb-login-button" data-show-faces="true" data-width="200" data-max-rows="1"></div><br />
<br /></td>
</tr>
</table>
</form>
<form id="form2" name="form2" method="post" action="check_reg.php">
<table width="1052" border="จ" align="center">
<tr>
<td width="476"> </td>
<td width="162" align="right">ลงทะเบียน</td>
<td width="400"> </td>
</tr>
<tr>
<td> </td>
<td align="right">Sex</td>
<td>:
<label>
<select name="in_sex" size="1" id="in_sex">
<option>-Sex-</option>
<option>Male</option>
<option>Famale</option>
</select>
</label></td>
</tr>
<tr>
<td> </td>
<td align="right">Name</td>
<td>:
<label><span id="sprytextfield1">
<input type="text" name="in_name" id="in_name" />
* Please fill in English.
<span class="textfieldRequiredMsg">Please input Name.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Lastname</td>
<td>:
<label><span id="sprytextfield2">
<input type="text" name="in_last_n" id="in_last_n" />
* Please fill in English.
<span class="textfieldRequiredMsg">Please input Last Name.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Date</td>
<td>:
<select name="day">
<option>-DAY-</option>
<?
for($y=1;$y<=31;$y++) {
echo "<option value='$y'>$y</option>";
}
echo "</select>";
?>
</select>
<select name="mount">
<option>-MONTH-</option>
<?
$mount = array("1" => "January",
"2" => "February",
"3" => "March",
"4" => "April",
"5" => "May",
"6" => "June",
"7" => "July ",
"8" => "August",
"9" => "September",
"10" => "October",
"11" => "November",
"12" => "December");
for($im=1;$im<=12;++$im) echo "<option value='{$im}'>$mount[$im]</option>";
echo "selected=$mount ";
?>
</select>
<select name="year">
<option>-YEAR-</option>
<?
for($a=1890;$a<=2200;$a++) {
echo "<option value='$a'>$a</option>";
}
echo "</select>";
?>
</select></td>
</tr>
<tr>
<td> </td>
<td align="right">Email</td>
<td>:
<label><span id="sprytextfield4">
<input type="text" name="in_email" id="in_email" />
<span class="textfieldRequiredMsg">Please input Email.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Password</td>
<td>:
<label><span id="sprytextfield5">
<input type="password" name="in_pass" id="in_pass" />
<span class="textfieldRequiredMsg">Please input Password.</span></span></label></td>
</tr>
<tr>
<td> </td>
<td align="right">Confirm Password</td>
<td>:
<label><span id="sprytextfield6">
<input type="password" name="in_con_pass" id="in_con_pass" />
<span class="textfieldRequiredMsg">Please input Confirm Password.</span></span></label></td>
</tr>
<tr>
<td height="29"> </td>
<td align="right" valign="top">Captcha Verify </td>
<td align="left" valign="top"><label><?php dsp_crypt(0,1); ?> :
<span id="sprytextfield7">
<input type="text" name="in_captcha" id="in_captcha" />
<span class="textfieldRequiredMsg">Please input Confirm Captcha.</span></span><br />
</label></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td><label>
<input type="submit" name="button2" id="button2" value="ลงทะเบียน" />
<input type="reset" name="button3" id="button3" value="Reset" />
</label></td>
</tr>
</table>
<p> </p>
</form>
<script type="text/javascript">
<!--
var spryselect1 = new Spry.Widget.ValidationSelect("spryselect1");
var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1");
var sprytextfield2 = new Spry.Widget.ValidationTextField("sprytextfield2");
var sprytextfield3 = new Spry.Widget.ValidationTextField("sprytextfield3");
var sprytextfield4 = new Spry.Widget.ValidationTextField("sprytextfield4");
var sprytextfield5 = new Spry.Widget.ValidationTextField("sprytextfield5");
var sprytextfield6 = new Spry.Widget.ValidationTextField("sprytextfield6");
var sprytextfield7 = new Spry.Widget.ValidationTextField("sprytextfield7");
//-->
</script>
</body>
</html>
|
|
|
|
|
Date :
2012-03-30 11:15:59 |
By :
ิbiggest59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 03
|