Original Letter | Look-Alike(s) |
---|---|
a | а ạ ą ä à á ą |
c | с ƈ ċ |
d | ԁ ɗ |
e | е ẹ ė é è |
g | ġ |
h | һ |
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 | |
session_start(); | |
$_SESSION["A"] = "Some New Value"; // set new value | |
print_r($_SESSION); | |
$_SESSION["B"] = "Some New Value"; // set new value | |
$_SESSION["C"] = "Some New Value"; // set new value | |
print_r($_SESSION); | |
session_reset(); // old session value restored | |
print_r($_SESSION); |
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 | |
function getBrowser() | |
{ | |
$u_agent = $_SERVER['HTTP_USER_AGENT']; | |
$bname = 'Unknown'; | |
$platform = 'Unknown'; | |
$version= ""; | |
//First get the platform? | |
if (preg_match('/linux/i', $u_agent)) { |
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 | |
/** | |
* | |
* Author: Mahmut Can | |
* Date: 20.07.2018 | |
* # Instagram Photo Downloader # | |
* | |
**/ | |
We want to upload file to a server with POST HTTP request. We will use curl functions.
// data fields for POST request
$fields = array("f1"=>"value1", "another_field2"=>"anothervalue");
// files to upload
$filenames = array("/tmp/1.jpg", "/tmp/2.png");
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
import React, { Component } from 'react'; | |
import { TextInput } from 'react-native'; | |
class Input extends Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
text: '' | |
}; | |
} |
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
# FORCE PORT 80 (insecure / regular traffic) | |
RewriteEngine On | |
RewriteCond %{HTTPS} on | |
RewriteRule ^ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] | |
########################################################### | |
#FORCE PORT 443 && REMOVE WWW. (secure / SSL) | |
RewriteCond %{SERVER_PORT} 80 | |
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R,L] |
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 | |
// This is a very noddy script to do 302 redirects to load balance between servers | |
// as listeners connect. It does no caching, supports a single stream only and requires | |
// Icecast 2.4 or above (because it uses the status-json.xsl page). | |
// The server, the minimum users before load balancing, the maximum users, the servers | |
// are considered in order from top to bottom | |
$servers = array( | |
array("http://server1:8000/", 10, 100), |
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 | |
$url = 'http://google.com'; | |
if ($argc > 1){ | |
$url = $argv[1]; | |
} | |
$ch=curl_init(); | |
// user credencial |
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
var arr = [{id:3,title:"Ali"},{id:3,title:"Veli"},{id:3,title:"Vehbi"}]; | |
arr.sort(turkcesiralama); | |
function turkcesiralama(a, b){ | |
var atitle = a.title; | |
var btitle = b.title; | |
var alfabe = "AaBbCcÇçDdEeFfGgĞğHhIıİiJjKkLlMmNnOoÖöPpQqRrSsŞşTtUuÜüVvWwXxYyZz0123456789"; | |
if (atitle.length === 0 || btitle.length === 0) { | |
return atitle.length - btitle.length; | |
} |
NewerOlder