S J miniblogs
- 0
S J 12.11.2012. 16:54
Tātad, atkal es ar savu php.
$loggedin = $auth->id;
if ($loggedin) {
echo '<div id="small"><center>Čau, <a href="/blog/user?id=' . $auth->id .'">' . $auth->username . '</a>!<br />';
echo 'Pēdējo reizi manīts: <br />' . $auth->accessed . '!<br />';
echo '<a href="?logout">Izlogoties?</a><br />';
echo '<a href="/blog/me/edit">Labot profilu?</a><br />';
echo '</center></div>';
$ip = $_SERVER["REMOTE_ADDR"];
$id = $auth->id;
$db = new mysqli('');
$setip = $db->query("UPDATE users SET ip = '$ip' WHERE id = '$id'");
}
else {
if (isset($_POST['username']) && isset($_POST['password']))
$auth->login($_POST['username'], $_POST['password']);
?>
<center><form action="" method="post">
<?php
if ($auth->error == 1) {
echo '<p>Nepareizs lietotājvārds un/vai parole!</p>';
}
?>
Lietotājvārds:<br /><input type="text" name="username" /><br />
Parole:<br /> <input type="password" name="password" />
<input type="submit" value="Ielogoties" /><br /><div id="small"><a href="/blog/register">Reģistrēties?</a></div></center>
</form>
<?php
}
Auto-logout es tā kā salaboju, bet tagad ir jauna problēma. Lai ielogotos, poga "Ielogoties" ir jāspiež divreiz. How to fix? - +2
S J 12.11.2012. 00:05
Es vienmēr nespēlēju karātavas, bet kad es to daru, es kļūstu par dienas uzvarētāju.
- 0
Earthquake 12.11.2012. 00:07
Es ar
vienreiz spēleju un dabuju medaļu,jo kad sāc spelet nevar vairs apstaties..
- 0
S J 10.11.2012. 00:00
[FEATURE] @Styrnucis dzied!!!
https://exs.lv/say/16261/2067045-naciet-catot-plsEDIT: SELĒNA PIEVIENOJĀS!
« - 1 - 2 - 3 - ... - 53 - 54 - 55 - ... - 160 - 161 - 162 - »