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 | |
// crontab ile bu dosyayı 1 2 dakikada bir çalıştırarak eğer sunucu 502 gateway hatası vermişse o anki bazı çıktıları kaydedip | |
// php-cgi'ye reset atacağız. | |
// test edilecek site | |
$adres="http://www.tesedileceksite.com/"; | |
$kaynak=file_get_contents($adres); | |
$desen="@502@"; | |
$komutlar=array( |
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
#/bin/sh | |
killall -9 php-cgi | |
/etc/init.d/php-fcgi start |
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
#!/bin/bash | |
#BIND=127.0.0.1:9000 | |
BIND=/tmp/php.socket | |
USER=www-data | |
ulimit -v 512000 | |
PHP_FCGI_CHILDREN=15 | |
PHP_FCGI_MAX_REQUESTS=50000 | |
PHP_CGI=/usr/bin/php-cgi | |
PHP_CGI_NAME=`basename $PHP_CGI` |
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
#/bin/sh | |
total=0; for i in `ps -C php-cgi -o rss=`; do total=$(($total+$i)); done; echo "php-cgi memory usage: $total kb"; |
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
#/bin/sh | |
total=0; for i in `ps -C nginx -o rss=`; do total=$(($total+$i)); done; echo "Nginx memory usage: $total kb"; |
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 | |
/** | |
* Örnek Kullanım | |
* | |
$detay="<h1>Test</h1>"; | |
$dosya="test.pdf"; | |
$wkPdf= new WkPdf(); | |
$wkPdf->setWkPath('/usr/bin/wkhtmltopdf'); | |
$wkPdf->setHtml($detay); |
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> | |
<head> | |
<script src="http://code.jquery.com/jquery-1.7.2.min.js"></script> | |
<script> | |
$(document).ready(function() { | |
function temizle(veri) { | |
var temiz = veri.replace(/[^a-zA-ZığüşöçİĞÜŞÖÇîêûÎÊÛ1234567890"' ]+/g, " "); | |
temiz = temiz.replace(/^\s+|\s+$/g, ""); |
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
#!/bin/bash | |
BIND=/tmp/php.socket | |
USER=www-data | |
PHP_FCGI_CHILDREN=30 | |
PHP_FCGI_MAX_REQUESTS=100000 | |
PHP_CGI=/usr/bin/php-cgi | |
PHP_CGI_NAME=`basename $PHP_CGI` | |
#echo $PHP_CGI_NAME | |
PHP_CGI_ARGS="- USER=$USER PATH=/usr/bin PHP_FCGI_CHILDREN=$PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS=$PHP_FCGI_MAX_REQUESTS $PHP_CGI -b $BIND" |
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] | |
;;;;;;;;;;;;;;;;;;; | |
; About php.ini ; | |
;;;;;;;;;;;;;;;;;;; | |
; PHP's initialization file, generally called php.ini, is responsible for | |
; configuring many of the aspects of PHP's behavior. | |
; PHP attempts to find and load this configuration from a number of locations. | |
; The following is a summary of its search order: |
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] | |
;;;;;;;;;;;;;;;;;;; | |
; About php.ini ; | |
;;;;;;;;;;;;;;;;;;; | |
; PHP's initialization file, generally called php.ini, is responsible for | |
; configuring many of the aspects of PHP's behavior. | |
; PHP attempts to find and load this configuration from a number of locations. | |
; The following is a summary of its search order: |