This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
try | |
{ | |
$pdo = new PDO('mysql:host=localhost;dbname=ijdb', 'ijdbuser', 'mypassword'); | |
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); | |
$pdo->exec('SET NAMES "utf8"'); | |
} | |
catch (PDOException $e) | |
{ | |
$error = 'Unable to connect to the database server.'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class classname { | |
function __construct($param) { | |
echo "Конструктор вызван с параметром " . $param . "<br />"; | |
} | |
} | |
$a = new classname("Первый"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form action="?edit" method="post"> | |
<div> | |
<label for="name">Name: <input type="text" name="name" | |
id="name" value="Joan Smith"></label> | |
</div> | |
<div> | |
<label for="email">Email: <input type="text" name="email" | |
id="email" value="[email protected]"></label> | |
</div> | |
<div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT joke.id, joketext, email, category.name, author.name | |
FROM joke | |
INNER JOIN author ON authorid = author.id | |
INNER JOIN jokecategory ON joke.id = jokeid | |
INNER JOIN category ON categoryid = category.id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"joke": [ | |
{ | |
"id": 1, | |
"joketext": "Цыплята ...", | |
"jokedate": "2014-01-12", | |
"authorId": "1" | |
}, | |
{ | |
"id": 2, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
header('Location: http://www.mail-plus.ru/balance.pdf'); | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html ng-app> | |
<head> | |
<title>AngularJs Post Example: DevZone.co.in </title> | |
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/angularjs/1.0.7/angular.min.js"></script> | |
<style> | |
#dv1{ | |
border:1px solid #DBDCE9; margin-left:auto; | |
margin-right:auto;width:220px; | |
border-radius:7px;padding: 25px; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Form Example</title> | |
</head> | |
<body> | |
<form action="name.php" method="post"> | |
<div><label for="name">Name: | |
<input type="text" name="name" id="name"></label> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Form Example</title> | |
</head> | |
<body> | |
<form action="" method="post"> | |
<div><label for="firstname">Enter ID: | |
<input type="text" name="id" id="firstname"></label> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
try | |
{ | |
$pdo = new PDO('mysql:host=localhost;dbname=ijdb', 'ijdbuser', 'mypassword'); | |
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); | |
$pdo->exec('SET NAMES "utf8"'); | |
} | |
catch (PDOException $e) | |
{ | |
$output = 'Unable to connect to the database server.'; |
NewerOlder