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 | |
$content = $_POST['editor1']; | |
if(empty($content)){ | |
$response= array('status'=>'danger','msg'=>'İçerik Boş'); | |
header('Content-Type: application/json'); | |
echo json_encode($response); | |
}else{ | |
$response= array('status'=>'success','msg'=>$content); | |
header('Content-Type: application/json'); |
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
<div class="the-return"> | |
[HTML is replaced when successful.] | |
</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
<?php // veri tabanı bağlantısı | |
$ip = "localhost"; //host | |
$user = "root"; // host id | |
$password = ""; // password local olduğu için varsayılan şifre boş | |
$db = "dbtest"; // db adı | |
//bağlantı | |
try{ | |
$db = new PDO("mysql:host=$ip;dbname=$db",$user,$password); | |
// türkçe karakter için utf8 |
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 | |
ob_start(); | |
session_start(); | |
$db = @new mysqli('localhost', 'root', '1234', 'uygulama'); | |
if ($db->connect_errno) die('Bağlantı Hatası:' . $db->connect_error); | |
/* Tablo veri karakter yapısı */ | |
$db->set_charset("utf8"); | |
//üye giriş yapmış mı? ve üye admin değilse, yönlendirelim |