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 | |
if(!isset($_GET['f'])) die('You must specify which files to download'); | |
$f = $_GET['f']; | |
if(!endsWith($f, '.pdf')) die('File MUST have .pdf extension (' . $f . ')'); | |
$f_array = explode('/', $f); | |
$file_name = $f_array[count($f_array) - 1]; | |
$file_url = $f; | |
header('Content-Type: application/octet-stream'); |
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
<!-- Çok önemli 1. adım: Analytics üzerinden site mutlaka e-ticaret sitesi olarak ayarlanmalıdır. --> | |
<!-- Çok önemli 2. adım: i,s,o,g,r,a,m kodundan sonra e-commerce plugin çağrılmalıdır. --> | |
<script>ga('require', 'ecommerce', 'ecommerce.js');</script> | |
<!-- Sipariş conversion kodu --> | |
<script> | |
ga('ecommerce:addTransaction', { | |
'id': '{{ siparis.id }}', // Transaction ID. Required. | |
//********************************************************************************* |
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 | |
//htmlencode turkish | |
function htmlencode_tr($input) { | |
return str_replace( | |
array('ç', 'ğ', 'ı', 'ö', 'ş', 'ü', 'Ç', 'Ğ', 'İ', 'Ö', 'Ş', 'Ü'), | |
array('ç', 'ğ', 'ı', 'ö', 'ş', 'ü', 'Ç', 'Ğ', 'İ', 'Ö', 'Ş', 'Ü'), | |
$input); | |
} |
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
--Thanks to Muharrem Taç - http://www.muharremtac.com | |
SELECT * | |
FROM ( | |
SELECT ROW_NUMBER() OVER(ORDER BY UserId ASC) AS RNumber, * | |
FROM UserDetails | |
) AS [UserDetails] WHERE RNumber BETWEEN 100 AND 200 |
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
''' <summary> | |
''' Finds a Control recursively. Note finds the first match and exists | |
''' </summary> | |
''' <param name="ContainerCtl"></param> | |
''' <param name="IdToFind"></param> | |
''' <returns></returns> | |
Public Shared Function FindControlRecursive(Root As Control, Id As String) As Control | |
If Root.ID = Id Then | |
Return Root | |
End If |
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
-- Turkce isimler sozlugu twitter : http://twitter.com/tserpico | |
CREATE TABLE `isimler` ( | |
`id` int(11) NOT NULL AUTO_INCREMENT, | |
`isimler` varchar(255) DEFAULT NULL, | |
`cinsiyet` varchar(255) DEFAULT NULL COMMENT 'erkek : E , kadın : K , uniseks : U', | |
PRIMARY KEY (`id`) | |
) ENGINE=InnoDB; | |
-- ---------------------------- |
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
RewriteEngine on | |
RewriteBase /helicon-test | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule . ./helicon-test/index.php [NC,L,NS] |
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 code uses mobiledetect ( http://mobiledetect.net ) for detect mobile users | |
include dirname(__FILE__) . '/../mobile-detect/Mobile_Detect.php'; | |
$detect = new Mobile_Detect(); | |
if($detect->isiOS()) { | |
header('Location: instagram://user?username=instagram'); | |
} else { | |
header('Location: http://instagram.com/instagram'); | |
} |
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
window.info = function() { | |
var i = ''; | |
i += 'screen.width =' + screen.width + '\n'; | |
i += 'screen.height =' + screen.height + '\n'; | |
i += 'window.orientation =' + window.orientation + '\n'; | |
i += 'window.getWidth() =' + window.getWidth() + '\n'; | |
alert(i); | |
};//window.info | |
window.getWidth = function() { |
OlderNewer