Hoşgeldin Misafir

Wpgurme Teması İndir

zeki35

4 Kas 2019
230 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:

zeki35

4 Kas 2019
230 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:
Warezm' Alıntı:
DevilDeep' Alıntı:
Functions İONCUBELİDİR Decode Size Kaldı.

DEMOYU GÖRMEK İÇİN TIKLA GİT



Merhaba İstek Üzerine şifreli iki dosyası kırıldı lisansı kaldırmak size düşüyor 
indi : https://disk.yandex.com.tr/d/RSzlKlJgL4g7yA

Hocam merhaba.

Lisansı kaldıranadım

lisans kaldırma yolunu tarif ederseniz çok makbule geçecektir.
şimdiden teşekkür ederim
selamlar
 

DevilDeep

27 Tem 2019
387 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:
zeki35' Alıntı:
DevilDeep' Alıntı:
functions.php Atarım Sizde Siteye Yüklerseniz Lisanssız Kullanırsınız...

Hocam Çoook sağolansın
teşekkürler
izmirden selamlar

PHP:
<?php
function lisans_yap()
{
	global $altinoktaonaltiwp;
	$site_adresi = get_bloginfo('url');
	$lisans_kodu_cek = $altinoktaonaltiwp['lisans-kodu'];
	$lisans_kod = trim($lisans_kodu_cek);
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			$cekilecek_text = 'http://www.altinoktaonalti.com/catchmeifyoucan.txt';
			$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			if (!function_exists('file')) {
				exit('<strong><a href=\'http://www.php.net/file\'>file</a></strong> fonksiyonu sunucuda yüklü olmalıdır<br /> function <strong><a href=\'http://www.php.net/file\'>file</a></strong> must be installed on the server');
			}
			function lisanskontrol()
			{
				if (substr($_SERVER['HTTP_HOST'], 0, 4) == 'www.') {
					$domainadi = substr($_SERVER['HTTP_HOST'], 4);
				}
				else {
					$domainadi = $_SERVER['HTTP_HOST'];
				}

				return $domainadi;
			}

			$alanadi = lisanskontrol();
			$lisanstext = file($cekilecek_text, FILE_IGNORE_NEW_LINES);
			$lisans = array();

			foreach ($lisanstext as $sayi => $cekveri) {
				$lisans[$sayi] = rtrim($cekveri, "\r\n");
			}

			if (in_array($alanadi, $lisans)) {

			}

			add_action('wp_head', 'lisanskontrol');
		}


function lang_setup()
{
	load_theme_textdomain('altinoktaonalti', get_template_directory() . '/languages');
}

function fonticon()
{
	$fonticon_url = get_template_directory_uri() . '/includes/css/font-awesome.css';
	echo "\r\n\t" . '<link rel="stylesheet" type="text/css" media="all" href="' . $fonticon_url . '" />' . "\r\n\t";
}

function shortcodespopup($hook)
{
	$thickboxcss = get_template_directory_uri() . '/includes/thickbox/thickbox.css';
	if (($hook == 'post.php') || ($hook == 'post-new.php')) {
		echo '<link rel="stylesheet" href="' . $thickboxcss . '" type="text/css" media="screen" />';
	}
}

function sitil_bilgileri()
{
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';
	$admin_colorpicker = get_template_directory_uri() . '/admin/js/colorpicker.js';
	$admin_ajaxupload = get_template_directory_uri() . '/admin/js/ajaxupload.js';
	echo '<link rel="stylesheet" type="text/css" media="all" href="' . $admin_style_url . '" /><script type="text/javascript" src="' . $admin_colorpicker . '"></script><script type="text/javascript" src="' . $admin_ajaxupload . '"></script>';
}

function theme_menus()
{
	register_nav_menus(array('headmenu' => __('Ana menu'), 'mobilmenu' => __('Mobil menu')));
}

function altionaltithumb($w, $h, $id, $type)
{
	global $altinoktaonaltiwp;
	global $post;

	if ($altinoktaonaltiwp['timthumb'] == '1') {
		if ($id != '') {
			if (has_post_thumbnail($id)) {
				$image = get_the_post_thumbnail($id, 'full');
				$image = explode('src="', $image);
				$image = explode('"', $image[1]);
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $image[0];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />';
			}
			else {
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $altinoktaonaltiwp['no-image'];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />' . "\r\n\t\t\t";
			}
		}
		else if (has_post_thumbnail()) {
			$image = get_the_post_thumbnail($post->ID, 'full');
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $image[0];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $altinoktaonaltiwp['no-image'];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if ($id != '') {
		if (has_post_thumbnail($id)) {
			$image = get_the_post_thumbnail($id, $type);
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			echo $image[0];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			echo $altinoktaonaltiwp['no-image'];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if (has_post_thumbnail()) {
		$image = get_the_post_thumbnail($post->ID, $type);
		$image = explode('src="', $image);
		$image = explode('"', $image[1]);
		echo "\t\t\t\t" . '<img src="';
		echo $image[0];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />';
	}
	else {
		echo "\t\t\t\t" . '<img src="';
		echo $altinoktaonaltiwp['no-image'];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />' . "\r\n\t\t\t";
	}
}

function hexToRGB($hex)
{
	$her_harf = str_split($hex);

	foreach ($her_harf as $key => $value) {
		if (($value == 'F') || ($value == 'f')) {
			$her_harf[$key] = 15;
		}
		else {
			if (($value == 'E') || ($value == 'e')) {
				$her_harf[$key] = 14;
			}
			else {
				if (($value == 'D') || ($value == 'd')) {
					$her_harf[$key] = 13;
				}
				else {
					if (($value == 'C') || ($value == 'c')) {
						$her_harf[$key] = 12;
					}
					else {
						if (($value == 'B') || ($value == 'b')) {
							$her_harf[$key] = 11;
						}
						else {
							if (($value == 'A') || ($value == 'a')) {
								$her_harf[$key] = 10;
							}
						}
					}
				}
			}
		}
	}

	$r = ($her_harf[1] * 16) + $her_harf[2];
	$g = ($her_harf[3] * 16) + $her_harf[4];
	$b = ($her_harf[5] * 16) + $her_harf[6];
	$color = $r . ',' . $g . ',' . $b;
	return $color;
}

function the_breadcrumb()
{
	if (!is_home()) {
		echo '<a href="';
		echo get_option('home');
		echo '"><i class="fa fa-home"></i></a> <i class="fa fa-angle-right"></i> ';
		if (is_category() || is_single()) {
			the_category(', ');

			if (is_single()) {
				echo ' <i class="fa fa-angle-right"></i> ';
				the_title();
			}
		}
		else if (is_page()) {
			echo the_title();
		}
	}
}

function getPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
		return '0';
	}

	return $count . '';
}

function setPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		$count = 0;
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
	}
	else {
		++$count;
		update_post_meta($postID, $count_key, $count);
	}
}

function posts_column_views($defaults)
{
	$defaults['post_views'] = __('Views');
	return $defaults;
}

function posts_custom_column_views($column_name, $id)
{
	if ($column_name === 'post_views') {
		echo getpostviews(get_the_ID());
	}
}

function yeni_baslik($sinir)
{
	$title = get_the_title();
	$limit = $sinir;
	$pad = '...';

	if (strlen($title) <= $limit) {
		echo $title;
	}
	else {
		$title = substr($title, 0, $limit) . $pad;
		echo $title;
	}
}

function excerpt($limit)
{
	$excerpt = explode(' ', get_the_excerpt(), $limit);

	if ($limit <= count($excerpt)) {
		array_pop($excerpt);
		$excerpt = implode(' ', $excerpt) . '...';
	}
	else {
		$excerpt = implode(' ', $excerpt);
	}

	$excerpt = preg_replace('`\\[[^\\]]*\\]`', '', $excerpt);
	return $excerpt;
}

function custom_comments($comment, $args, $depth)
{
	$GLOBALS['comment'] = $comment;
	echo "\t" . '<li id="comment-';
	comment_ID();
	echo '">' . "\r\n\t\t" . '<article  ';
	comment_class('comment-wrap');
	echo ' >' . "\r\n" . '        ' . "\t" . '<div class="fn">';
	printf(__('%s ', 'altinoktaonalti'), sprintf('%s', get_comment_author_link()));
	echo '                        ';
	comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
	echo "\r\n" . '            ' . "\t" . '<a class="diskadate" href="';
	echo esc_url(get_comment_link($comment->comment_ID));
	echo '">' . "\t";
	printf(__('%1$s - %2$s', 'altinoktaonalti'), get_comment_date(), get_comment_time());
	echo '</a>';
	edit_comment_link(__('(Düzenle)', 'altinoktaonalti'), ' ');
	echo '            ' . "\r\n" . '            </div>' . "\r\n\t\t\t" . '<div class="comment-avatar">';
	echo get_avatar($comment, 55);
	echo '</div>' . "\r\n\t\t\t" . '<div class="diskacontent">' . "\r\n\t\t\t\t";

	if ($comment->comment_approved == '0') {
		echo "\t\t\t\t\t" . '<em class="comment-awaiting-moderation">';
		_e('Yorumunuz onay bekliyor. Onaylandıktan sonra yayınlanacaktır.', 'altinoktaonalti');
		echo '</em>' . "\r\n\t\t\t\t\t" . '<br />' . "\r\n\t\t\t\t";
	}

	echo "\t\t\t\t";
	comment_text();
	echo "\t\t\t" . '</div>' . "\r\n\t\t" . '</article>' . "\r\n\r\n\t";
}

function sayfalama($pages = '', $range = 3)
{
	$showitems = ($range * 2) + 1;
	global $paged;

	if (empty($paged)) {
		$paged = 1;
	}

	if ($pages == '') {
		global $wp_query;
		$pages = $wp_query->max_num_pages;

		if (!$pages) {
			$pages = 1;
		}
	}

	if (1 != $pages) {
		echo '<div class=\'page-nav\'>';

		if ((2 < $paged) && (($range + 1) < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link(1) . '\'><i class=\'fa fa-angle-double-left\'></i></a>';
		}

		if ((1 < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged - 1) . '\'><i class=\'fa fa-angle-left\'></i></a>';
		}

		$i = 1;

		while ($i <= $pages) {
			if ((1 != $pages) && (!((($paged + $range + 1) <= $i) || ($i <= $paged - $range - 1)) || ($pages <= $showitems))) {
				echo $paged == $i ? '<span class=\'current\'>' . $i . '</span>' : '<a href=\'' . get_pagenum_link($i) . '\' class=\'inactive\' >' . $i . '</a>';
			}

			++$i;
		}

		if (($paged < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged + 1) . '\'><i class=\'fa fa-angle-right\'></i></a>';
		}

		if (($paged < ($pages - 1)) && ((($paged + $range) - 1) < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($pages) . '\'><i class=\'fa fa-angle-double-right\'></i></a>';
		}

		echo '</div>' . "\n";
	}
}

function en_begenilen($limit = 5)
{
	global $wpdb;
	$query = 'SELECT post_id, meta_value, post_status FROM ' . $wpdb->postmeta;
	$query .= ' LEFT JOIN ' . $wpdb->posts . ' ON post_id=' . $wpdb->posts . '.ID';
	$query .= ' WHERE post_status=\'publish\' AND meta_key=\'' . WPFP_META_KEY . '\' AND meta_value > 0 ORDER BY ROUND(meta_value) DESC LIMIT 0, ' . $limit;
	$results = $wpdb->get_results($query);

	if ($results) {
		echo '<ul class=\'defterdekiler\'>';

		foreach ($results as $o) {
			$p = get_post($o->post_id);
			$timthumb = get_template_directory_uri() . '/includes/timthumb.php?src=';
			$resim_link = wp_get_attachment_url(get_post_thumbnail_id($o->post_id));

			if ($resim_link == '') {
				$resim_link = get_template_directory_uri() . '/img/no-image.png';
			}

			echo "\t\t\t" . '<li>' . "\r\n\t\t\t\t" . '<div class="post-img"><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			altionaltithumb(310, 200, $o->post_id, 'grid');
			echo '</a></div>' . "\r\n\t\t\t\t" . '<span><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			echo $p->post_title;
			echo '</a></span>' . "\r\n\t\t\t\t" . '<span class="yazar">';
			echo $o->meta_value;
			echo ' ';
			echo __('kiÅŸinin defterinde', 'altinoktaonalti');
			echo '</span>' . "\r\n" . '            </li>' . "\r\n" . '        ';
		}

		echo '</ul>';
	}
}

function insert_attachment($file_handler, $post_id, $setthumb = 'false')
{
	if ($_FILES[$file_handler]['error'] !== UPLOAD_ERR_OK) {
		__return_false();
	}

	require_once ABSPATH . 'wp-admin' . '/includes/image.php';
	require_once ABSPATH . 'wp-admin' . '/includes/file.php';
	require_once ABSPATH . 'wp-admin' . '/includes/media.php';
	$attach_id = media_handle_upload($file_handler, $post_id);

	if ($setthumb) {
		update_post_meta($post_id, '_thumbnail_id', $attach_id);
	}

	return $attach_id;
}

require get_template_directory() . '/admin/admin-init.php';
add_action('wp_head', 'lisans_yap');
require_once 'widgets/kategori.php';
require_once 'widgets/coklukategori.php';
require_once 'widgets/gunun-tarifi.php';
require_once 'widgets/en-begenilen-tarifler.php';
require_once 'widgets/yazarlar.php';
require_once 'widgets/video.php';
include_once 'includes/metabox.php';
include_once 'includes/categories-images.php';
add_action('admin_enqueue_scripts', 'ss_framework_admin_scripts');

if (!function_exists('ss_framework_admin_scripts')) {
	function ss_framework_admin_scripts($hook)
	{
		if (($hook == 'post.php') || ($hook == 'post-new.php')) {
			wp_register_script('tinymce_scripts', get_template_directory_uri() . '/includes/tinymce/js/scripts.js', array('jquery'), false, true);
			wp_enqueue_script('tinymce_scripts');
		}
	}
}

add_action('after_setup_theme', 'lang_setup');
add_action('admin_head', 'fonticon');
add_action('admin_enqueue_scripts', 'shortcodespopup');
add_action('admin_head', 'sitil_bilgileri');
add_action('init', 'theme_menus');
add_theme_support('post-thumbnails');
add_image_size('slider', 640, 350, true);
add_image_size('single', 500, 300, true);
add_image_size('category', 310, 175, true);
add_image_size('author', 60, 60, true);
add_image_size('favorite', 160, 120, true);
add_image_size('pratik', 100, 80, true);
add_image_size('singlefull', 630, 350, true);
add_image_size('benzer', 150, 150, true);
add_image_size('slidermini', 48, 41, true);
add_filter('manage_posts_columns', 'posts_column_views');
add_action('manage_posts_custom_column', 'posts_custom_column_views', 5, 2);

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Anasayfa'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Footer', 'before_widget' => '<div class="widget-footer">', 'after_widget' => '</div>', 'before_title' => '<div class="widget-title"><h2>', 'after_title' => '</h2></div>'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Sidebar', 'before_widget' => '<div class="sidebar-alan">', 'after_widget' => '</div>', 'before_title' => '<div class="title"><h2><i class="fa fa-bars"></i>', 'after_title' => '</h2></div>'));
}

?>

Sizdeki functions.php İçeriğini Bununla Değiştirin Kolay Gelsin :)


Zimbabve'den Selamlar ;)
 

zeki35

4 Kas 2019
230 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:
DevilDeep' Alıntı:
zeki35' Alıntı:
DevilDeep' Alıntı:
functions.php Atarım Sizde Siteye Yüklerseniz Lisanssız Kullanırsınız...

Hocam Çoook sağolansın
teşekkürler
izmirden selamlar

PHP:
<?php
function lisans_yap()
{
	global $altinoktaonaltiwp;
	$site_adresi = get_bloginfo('url');
	$lisans_kodu_cek = $altinoktaonaltiwp['lisans-kodu'];
	$lisans_kod = trim($lisans_kodu_cek);
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			$cekilecek_text = 'http://www.altinoktaonalti.com/catchmeifyoucan.txt';
			$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			if (!function_exists('file')) {
				exit('<strong><a href=\'http://www.php.net/file\'>file</a></strong> fonksiyonu sunucuda yüklü olmalıdır<br /> function <strong><a href=\'http://www.php.net/file\'>file</a></strong> must be installed on the server');
			}
			function lisanskontrol()
			{
				if (substr($_SERVER['HTTP_HOST'], 0, 4) == 'www.') {
					$domainadi = substr($_SERVER['HTTP_HOST'], 4);
				}
				else {
					$domainadi = $_SERVER['HTTP_HOST'];
				}

				return $domainadi;
			}

			$alanadi = lisanskontrol();
			$lisanstext = file($cekilecek_text, FILE_IGNORE_NEW_LINES);
			$lisans = array();

			foreach ($lisanstext as $sayi => $cekveri) {
				$lisans[$sayi] = rtrim($cekveri, "\r\n");
			}

			if (in_array($alanadi, $lisans)) {

			}

			add_action('wp_head', 'lisanskontrol');
		}


function lang_setup()
{
	load_theme_textdomain('altinoktaonalti', get_template_directory() . '/languages');
}

function fonticon()
{
	$fonticon_url = get_template_directory_uri() . '/includes/css/font-awesome.css';
	echo "\r\n\t" . '<link rel="stylesheet" type="text/css" media="all" href="' . $fonticon_url . '" />' . "\r\n\t";
}

function shortcodespopup($hook)
{
	$thickboxcss = get_template_directory_uri() . '/includes/thickbox/thickbox.css';
	if (($hook == 'post.php') || ($hook == 'post-new.php')) {
		echo '<link rel="stylesheet" href="' . $thickboxcss . '" type="text/css" media="screen" />';
	}
}

function sitil_bilgileri()
{
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';
	$admin_colorpicker = get_template_directory_uri() . '/admin/js/colorpicker.js';
	$admin_ajaxupload = get_template_directory_uri() . '/admin/js/ajaxupload.js';
	echo '<link rel="stylesheet" type="text/css" media="all" href="' . $admin_style_url . '" /><script type="text/javascript" src="' . $admin_colorpicker . '"></script><script type="text/javascript" src="' . $admin_ajaxupload . '"></script>';
}

function theme_menus()
{
	register_nav_menus(array('headmenu' => __('Ana menu'), 'mobilmenu' => __('Mobil menu')));
}

function altionaltithumb($w, $h, $id, $type)
{
	global $altinoktaonaltiwp;
	global $post;

	if ($altinoktaonaltiwp['timthumb'] == '1') {
		if ($id != '') {
			if (has_post_thumbnail($id)) {
				$image = get_the_post_thumbnail($id, 'full');
				$image = explode('src="', $image);
				$image = explode('"', $image[1]);
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $image[0];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />';
			}
			else {
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $altinoktaonaltiwp['no-image'];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />' . "\r\n\t\t\t";
			}
		}
		else if (has_post_thumbnail()) {
			$image = get_the_post_thumbnail($post->ID, 'full');
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $image[0];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $altinoktaonaltiwp['no-image'];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if ($id != '') {
		if (has_post_thumbnail($id)) {
			$image = get_the_post_thumbnail($id, $type);
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			echo $image[0];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			echo $altinoktaonaltiwp['no-image'];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if (has_post_thumbnail()) {
		$image = get_the_post_thumbnail($post->ID, $type);
		$image = explode('src="', $image);
		$image = explode('"', $image[1]);
		echo "\t\t\t\t" . '<img src="';
		echo $image[0];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />';
	}
	else {
		echo "\t\t\t\t" . '<img src="';
		echo $altinoktaonaltiwp['no-image'];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />' . "\r\n\t\t\t";
	}
}

function hexToRGB($hex)
{
	$her_harf = str_split($hex);

	foreach ($her_harf as $key => $value) {
		if (($value == 'F') || ($value == 'f')) {
			$her_harf[$key] = 15;
		}
		else {
			if (($value == 'E') || ($value == 'e')) {
				$her_harf[$key] = 14;
			}
			else {
				if (($value == 'D') || ($value == 'd')) {
					$her_harf[$key] = 13;
				}
				else {
					if (($value == 'C') || ($value == 'c')) {
						$her_harf[$key] = 12;
					}
					else {
						if (($value == 'B') || ($value == 'b')) {
							$her_harf[$key] = 11;
						}
						else {
							if (($value == 'A') || ($value == 'a')) {
								$her_harf[$key] = 10;
							}
						}
					}
				}
			}
		}
	}

	$r = ($her_harf[1] * 16) + $her_harf[2];
	$g = ($her_harf[3] * 16) + $her_harf[4];
	$b = ($her_harf[5] * 16) + $her_harf[6];
	$color = $r . ',' . $g . ',' . $b;
	return $color;
}

function the_breadcrumb()
{
	if (!is_home()) {
		echo '<a href="';
		echo get_option('home');
		echo '"><i class="fa fa-home"></i></a> <i class="fa fa-angle-right"></i> ';
		if (is_category() || is_single()) {
			the_category(', ');

			if (is_single()) {
				echo ' <i class="fa fa-angle-right"></i> ';
				the_title();
			}
		}
		else if (is_page()) {
			echo the_title();
		}
	}
}

function getPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
		return '0';
	}

	return $count . '';
}

function setPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		$count = 0;
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
	}
	else {
		++$count;
		update_post_meta($postID, $count_key, $count);
	}
}

function posts_column_views($defaults)
{
	$defaults['post_views'] = __('Views');
	return $defaults;
}

function posts_custom_column_views($column_name, $id)
{
	if ($column_name === 'post_views') {
		echo getpostviews(get_the_ID());
	}
}

function yeni_baslik($sinir)
{
	$title = get_the_title();
	$limit = $sinir;
	$pad = '...';

	if (strlen($title) <= $limit) {
		echo $title;
	}
	else {
		$title = substr($title, 0, $limit) . $pad;
		echo $title;
	}
}

function excerpt($limit)
{
	$excerpt = explode(' ', get_the_excerpt(), $limit);

	if ($limit <= count($excerpt)) {
		array_pop($excerpt);
		$excerpt = implode(' ', $excerpt) . '...';
	}
	else {
		$excerpt = implode(' ', $excerpt);
	}

	$excerpt = preg_replace('`\\[[^\\]]*\\]`', '', $excerpt);
	return $excerpt;
}

function custom_comments($comment, $args, $depth)
{
	$GLOBALS['comment'] = $comment;
	echo "\t" . '<li id="comment-';
	comment_ID();
	echo '">' . "\r\n\t\t" . '<article  ';
	comment_class('comment-wrap');
	echo ' >' . "\r\n" . '        ' . "\t" . '<div class="fn">';
	printf(__('%s ', 'altinoktaonalti'), sprintf('%s', get_comment_author_link()));
	echo '                        ';
	comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
	echo "\r\n" . '            ' . "\t" . '<a class="diskadate" href="';
	echo esc_url(get_comment_link($comment->comment_ID));
	echo '">' . "\t";
	printf(__('%1$s - %2$s', 'altinoktaonalti'), get_comment_date(), get_comment_time());
	echo '</a>';
	edit_comment_link(__('(Düzenle)', 'altinoktaonalti'), ' ');
	echo '            ' . "\r\n" . '            </div>' . "\r\n\t\t\t" . '<div class="comment-avatar">';
	echo get_avatar($comment, 55);
	echo '</div>' . "\r\n\t\t\t" . '<div class="diskacontent">' . "\r\n\t\t\t\t";

	if ($comment->comment_approved == '0') {
		echo "\t\t\t\t\t" . '<em class="comment-awaiting-moderation">';
		_e('Yorumunuz onay bekliyor. Onaylandıktan sonra yayınlanacaktır.', 'altinoktaonalti');
		echo '</em>' . "\r\n\t\t\t\t\t" . '<br />' . "\r\n\t\t\t\t";
	}

	echo "\t\t\t\t";
	comment_text();
	echo "\t\t\t" . '</div>' . "\r\n\t\t" . '</article>' . "\r\n\r\n\t";
}

function sayfalama($pages = '', $range = 3)
{
	$showitems = ($range * 2) + 1;
	global $paged;

	if (empty($paged)) {
		$paged = 1;
	}

	if ($pages == '') {
		global $wp_query;
		$pages = $wp_query->max_num_pages;

		if (!$pages) {
			$pages = 1;
		}
	}

	if (1 != $pages) {
		echo '<div class=\'page-nav\'>';

		if ((2 < $paged) && (($range + 1) < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link(1) . '\'><i class=\'fa fa-angle-double-left\'></i></a>';
		}

		if ((1 < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged - 1) . '\'><i class=\'fa fa-angle-left\'></i></a>';
		}

		$i = 1;

		while ($i <= $pages) {
			if ((1 != $pages) && (!((($paged + $range + 1) <= $i) || ($i <= $paged - $range - 1)) || ($pages <= $showitems))) {
				echo $paged == $i ? '<span class=\'current\'>' . $i . '</span>' : '<a href=\'' . get_pagenum_link($i) . '\' class=\'inactive\' >' . $i . '</a>';
			}

			++$i;
		}

		if (($paged < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged + 1) . '\'><i class=\'fa fa-angle-right\'></i></a>';
		}

		if (($paged < ($pages - 1)) && ((($paged + $range) - 1) < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($pages) . '\'><i class=\'fa fa-angle-double-right\'></i></a>';
		}

		echo '</div>' . "\n";
	}
}

function en_begenilen($limit = 5)
{
	global $wpdb;
	$query = 'SELECT post_id, meta_value, post_status FROM ' . $wpdb->postmeta;
	$query .= ' LEFT JOIN ' . $wpdb->posts . ' ON post_id=' . $wpdb->posts . '.ID';
	$query .= ' WHERE post_status=\'publish\' AND meta_key=\'' . WPFP_META_KEY . '\' AND meta_value > 0 ORDER BY ROUND(meta_value) DESC LIMIT 0, ' . $limit;
	$results = $wpdb->get_results($query);

	if ($results) {
		echo '<ul class=\'defterdekiler\'>';

		foreach ($results as $o) {
			$p = get_post($o->post_id);
			$timthumb = get_template_directory_uri() . '/includes/timthumb.php?src=';
			$resim_link = wp_get_attachment_url(get_post_thumbnail_id($o->post_id));

			if ($resim_link == '') {
				$resim_link = get_template_directory_uri() . '/img/no-image.png';
			}

			echo "\t\t\t" . '<li>' . "\r\n\t\t\t\t" . '<div class="post-img"><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			altionaltithumb(310, 200, $o->post_id, 'grid');
			echo '</a></div>' . "\r\n\t\t\t\t" . '<span><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			echo $p->post_title;
			echo '</a></span>' . "\r\n\t\t\t\t" . '<span class="yazar">';
			echo $o->meta_value;
			echo ' ';
			echo __('kiÅŸinin defterinde', 'altinoktaonalti');
			echo '</span>' . "\r\n" . '            </li>' . "\r\n" . '        ';
		}

		echo '</ul>';
	}
}

function insert_attachment($file_handler, $post_id, $setthumb = 'false')
{
	if ($_FILES[$file_handler]['error'] !== UPLOAD_ERR_OK) {
		__return_false();
	}

	require_once ABSPATH . 'wp-admin' . '/includes/image.php';
	require_once ABSPATH . 'wp-admin' . '/includes/file.php';
	require_once ABSPATH . 'wp-admin' . '/includes/media.php';
	$attach_id = media_handle_upload($file_handler, $post_id);

	if ($setthumb) {
		update_post_meta($post_id, '_thumbnail_id', $attach_id);
	}

	return $attach_id;
}

require get_template_directory() . '/admin/admin-init.php';
add_action('wp_head', 'lisans_yap');
require_once 'widgets/kategori.php';
require_once 'widgets/coklukategori.php';
require_once 'widgets/gunun-tarifi.php';
require_once 'widgets/en-begenilen-tarifler.php';
require_once 'widgets/yazarlar.php';
require_once 'widgets/video.php';
include_once 'includes/metabox.php';
include_once 'includes/categories-images.php';
add_action('admin_enqueue_scripts', 'ss_framework_admin_scripts');

if (!function_exists('ss_framework_admin_scripts')) {
	function ss_framework_admin_scripts($hook)
	{
		if (($hook == 'post.php') || ($hook == 'post-new.php')) {
			wp_register_script('tinymce_scripts', get_template_directory_uri() . '/includes/tinymce/js/scripts.js', array('jquery'), false, true);
			wp_enqueue_script('tinymce_scripts');
		}
	}
}

add_action('after_setup_theme', 'lang_setup');
add_action('admin_head', 'fonticon');
add_action('admin_enqueue_scripts', 'shortcodespopup');
add_action('admin_head', 'sitil_bilgileri');
add_action('init', 'theme_menus');
add_theme_support('post-thumbnails');
add_image_size('slider', 640, 350, true);
add_image_size('single', 500, 300, true);
add_image_size('category', 310, 175, true);
add_image_size('author', 60, 60, true);
add_image_size('favorite', 160, 120, true);
add_image_size('pratik', 100, 80, true);
add_image_size('singlefull', 630, 350, true);
add_image_size('benzer', 150, 150, true);
add_image_size('slidermini', 48, 41, true);
add_filter('manage_posts_columns', 'posts_column_views');
add_action('manage_posts_custom_column', 'posts_custom_column_views', 5, 2);

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Anasayfa'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Footer', 'before_widget' => '<div class="widget-footer">', 'after_widget' => '</div>', 'before_title' => '<div class="widget-title"><h2>', 'after_title' => '</h2></div>'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Sidebar', 'before_widget' => '<div class="sidebar-alan">', 'after_widget' => '</div>', 'before_title' => '<div class="title"><h2><i class="fa fa-bars"></i>', 'after_title' => '</h2></div>'));
}

?>

Sizdeki functions.php İçeriğini Bununla Değiştirin Kolay Gelsin :)

sağol hocam
teşekkürler deneyecem
 

zeki35

4 Kas 2019
230 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:
DevilDeep' Alıntı:
zeki35' Alıntı:
DevilDeep' Alıntı:
functions.php Atarım Sizde Siteye Yüklerseniz Lisanssız Kullanırsınız...

Hocam Çoook sağolansın
teşekkürler
izmirden selamlar

PHP:
<?php
function lisans_yap()
{
	global $altinoktaonaltiwp;
	$site_adresi = get_bloginfo('url');
	$lisans_kodu_cek = $altinoktaonaltiwp['lisans-kodu'];
	$lisans_kod = trim($lisans_kodu_cek);
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			$cekilecek_text = 'http://www.altinoktaonalti.com/catchmeifyoucan.txt';
			$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';

			if (!function_exists('file')) {
				exit('<strong><a href=\'http://www.php.net/file\'>file</a></strong> fonksiyonu sunucuda yüklü olmalıdır<br /> function <strong><a href=\'http://www.php.net/file\'>file</a></strong> must be installed on the server');
			}
			function lisanskontrol()
			{
				if (substr($_SERVER['HTTP_HOST'], 0, 4) == 'www.') {
					$domainadi = substr($_SERVER['HTTP_HOST'], 4);
				}
				else {
					$domainadi = $_SERVER['HTTP_HOST'];
				}

				return $domainadi;
			}

			$alanadi = lisanskontrol();
			$lisanstext = file($cekilecek_text, FILE_IGNORE_NEW_LINES);
			$lisans = array();

			foreach ($lisanstext as $sayi => $cekveri) {
				$lisans[$sayi] = rtrim($cekveri, "\r\n");
			}

			if (in_array($alanadi, $lisans)) {

			}

			add_action('wp_head', 'lisanskontrol');
		}


function lang_setup()
{
	load_theme_textdomain('altinoktaonalti', get_template_directory() . '/languages');
}

function fonticon()
{
	$fonticon_url = get_template_directory_uri() . '/includes/css/font-awesome.css';
	echo "\r\n\t" . '<link rel="stylesheet" type="text/css" media="all" href="' . $fonticon_url . '" />' . "\r\n\t";
}

function shortcodespopup($hook)
{
	$thickboxcss = get_template_directory_uri() . '/includes/thickbox/thickbox.css';
	if (($hook == 'post.php') || ($hook == 'post-new.php')) {
		echo '<link rel="stylesheet" href="' . $thickboxcss . '" type="text/css" media="screen" />';
	}
}

function sitil_bilgileri()
{
	$admin_style_url = get_template_directory_uri() . '/admin/tema-admin-style.css';
	$admin_colorpicker = get_template_directory_uri() . '/admin/js/colorpicker.js';
	$admin_ajaxupload = get_template_directory_uri() . '/admin/js/ajaxupload.js';
	echo '<link rel="stylesheet" type="text/css" media="all" href="' . $admin_style_url . '" /><script type="text/javascript" src="' . $admin_colorpicker . '"></script><script type="text/javascript" src="' . $admin_ajaxupload . '"></script>';
}

function theme_menus()
{
	register_nav_menus(array('headmenu' => __('Ana menu'), 'mobilmenu' => __('Mobil menu')));
}

function altionaltithumb($w, $h, $id, $type)
{
	global $altinoktaonaltiwp;
	global $post;

	if ($altinoktaonaltiwp['timthumb'] == '1') {
		if ($id != '') {
			if (has_post_thumbnail($id)) {
				$image = get_the_post_thumbnail($id, 'full');
				$image = explode('src="', $image);
				$image = explode('"', $image[1]);
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $image[0];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />';
			}
			else {
				echo "\t\t\t\t" . '<img src="';
				bloginfo('template_url');
				echo '/includes/timthumb.php?zc=1&amp;src=';
				echo $altinoktaonaltiwp['no-image'];
				echo '&amp;w=';
				echo $w;
				echo '&amp;h=';
				echo $h;
				echo '" alt="';
				echo get_the_title($id);
				echo '" width="';
				echo $w;
				echo '" height="';
				echo $h;
				echo '" />' . "\r\n\t\t\t";
			}
		}
		else if (has_post_thumbnail()) {
			$image = get_the_post_thumbnail($post->ID, 'full');
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $image[0];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			bloginfo('template_url');
			echo '/includes/timthumb.php?zc=1&amp;src=';
			echo $altinoktaonaltiwp['no-image'];
			echo '&amp;w=';
			echo $w;
			echo '&amp;h=';
			echo $h;
			echo '" alt="';
			the_title();
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if ($id != '') {
		if (has_post_thumbnail($id)) {
			$image = get_the_post_thumbnail($id, $type);
			$image = explode('src="', $image);
			$image = explode('"', $image[1]);
			echo "\t\t\t\t" . '<img src="';
			echo $image[0];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />';
		}
		else {
			echo "\t\t\t\t" . '<img src="';
			echo $altinoktaonaltiwp['no-image'];
			echo '" alt="';
			echo get_the_title($id);
			echo '" width="';
			echo $w;
			echo '" height="';
			echo $h;
			echo '" />' . "\r\n\t\t\t";
		}
	}
	else if (has_post_thumbnail()) {
		$image = get_the_post_thumbnail($post->ID, $type);
		$image = explode('src="', $image);
		$image = explode('"', $image[1]);
		echo "\t\t\t\t" . '<img src="';
		echo $image[0];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />';
	}
	else {
		echo "\t\t\t\t" . '<img src="';
		echo $altinoktaonaltiwp['no-image'];
		echo '" alt="';
		the_title();
		echo '" width="';
		echo $w;
		echo '" height="';
		echo $h;
		echo '" />' . "\r\n\t\t\t";
	}
}

function hexToRGB($hex)
{
	$her_harf = str_split($hex);

	foreach ($her_harf as $key => $value) {
		if (($value == 'F') || ($value == 'f')) {
			$her_harf[$key] = 15;
		}
		else {
			if (($value == 'E') || ($value == 'e')) {
				$her_harf[$key] = 14;
			}
			else {
				if (($value == 'D') || ($value == 'd')) {
					$her_harf[$key] = 13;
				}
				else {
					if (($value == 'C') || ($value == 'c')) {
						$her_harf[$key] = 12;
					}
					else {
						if (($value == 'B') || ($value == 'b')) {
							$her_harf[$key] = 11;
						}
						else {
							if (($value == 'A') || ($value == 'a')) {
								$her_harf[$key] = 10;
							}
						}
					}
				}
			}
		}
	}

	$r = ($her_harf[1] * 16) + $her_harf[2];
	$g = ($her_harf[3] * 16) + $her_harf[4];
	$b = ($her_harf[5] * 16) + $her_harf[6];
	$color = $r . ',' . $g . ',' . $b;
	return $color;
}

function the_breadcrumb()
{
	if (!is_home()) {
		echo '<a href="';
		echo get_option('home');
		echo '"><i class="fa fa-home"></i></a> <i class="fa fa-angle-right"></i> ';
		if (is_category() || is_single()) {
			the_category(', ');

			if (is_single()) {
				echo ' <i class="fa fa-angle-right"></i> ';
				the_title();
			}
		}
		else if (is_page()) {
			echo the_title();
		}
	}
}

function getPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
		return '0';
	}

	return $count . '';
}

function setPostViews($postID)
{
	$count_key = 'post_views_count';
	$count = get_post_meta($postID, $count_key, true);

	if ($count == '') {
		$count = 0;
		delete_post_meta($postID, $count_key);
		add_post_meta($postID, $count_key, '0');
	}
	else {
		++$count;
		update_post_meta($postID, $count_key, $count);
	}
}

function posts_column_views($defaults)
{
	$defaults['post_views'] = __('Views');
	return $defaults;
}

function posts_custom_column_views($column_name, $id)
{
	if ($column_name === 'post_views') {
		echo getpostviews(get_the_ID());
	}
}

function yeni_baslik($sinir)
{
	$title = get_the_title();
	$limit = $sinir;
	$pad = '...';

	if (strlen($title) <= $limit) {
		echo $title;
	}
	else {
		$title = substr($title, 0, $limit) . $pad;
		echo $title;
	}
}

function excerpt($limit)
{
	$excerpt = explode(' ', get_the_excerpt(), $limit);

	if ($limit <= count($excerpt)) {
		array_pop($excerpt);
		$excerpt = implode(' ', $excerpt) . '...';
	}
	else {
		$excerpt = implode(' ', $excerpt);
	}

	$excerpt = preg_replace('`\\[[^\\]]*\\]`', '', $excerpt);
	return $excerpt;
}

function custom_comments($comment, $args, $depth)
{
	$GLOBALS['comment'] = $comment;
	echo "\t" . '<li id="comment-';
	comment_ID();
	echo '">' . "\r\n\t\t" . '<article  ';
	comment_class('comment-wrap');
	echo ' >' . "\r\n" . '        ' . "\t" . '<div class="fn">';
	printf(__('%s ', 'altinoktaonalti'), sprintf('%s', get_comment_author_link()));
	echo '                        ';
	comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
	echo "\r\n" . '            ' . "\t" . '<a class="diskadate" href="';
	echo esc_url(get_comment_link($comment->comment_ID));
	echo '">' . "\t";
	printf(__('%1$s - %2$s', 'altinoktaonalti'), get_comment_date(), get_comment_time());
	echo '</a>';
	edit_comment_link(__('(Düzenle)', 'altinoktaonalti'), ' ');
	echo '            ' . "\r\n" . '            </div>' . "\r\n\t\t\t" . '<div class="comment-avatar">';
	echo get_avatar($comment, 55);
	echo '</div>' . "\r\n\t\t\t" . '<div class="diskacontent">' . "\r\n\t\t\t\t";

	if ($comment->comment_approved == '0') {
		echo "\t\t\t\t\t" . '<em class="comment-awaiting-moderation">';
		_e('Yorumunuz onay bekliyor. Onaylandıktan sonra yayınlanacaktır.', 'altinoktaonalti');
		echo '</em>' . "\r\n\t\t\t\t\t" . '<br />' . "\r\n\t\t\t\t";
	}

	echo "\t\t\t\t";
	comment_text();
	echo "\t\t\t" . '</div>' . "\r\n\t\t" . '</article>' . "\r\n\r\n\t";
}

function sayfalama($pages = '', $range = 3)
{
	$showitems = ($range * 2) + 1;
	global $paged;

	if (empty($paged)) {
		$paged = 1;
	}

	if ($pages == '') {
		global $wp_query;
		$pages = $wp_query->max_num_pages;

		if (!$pages) {
			$pages = 1;
		}
	}

	if (1 != $pages) {
		echo '<div class=\'page-nav\'>';

		if ((2 < $paged) && (($range + 1) < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link(1) . '\'><i class=\'fa fa-angle-double-left\'></i></a>';
		}

		if ((1 < $paged) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged - 1) . '\'><i class=\'fa fa-angle-left\'></i></a>';
		}

		$i = 1;

		while ($i <= $pages) {
			if ((1 != $pages) && (!((($paged + $range + 1) <= $i) || ($i <= $paged - $range - 1)) || ($pages <= $showitems))) {
				echo $paged == $i ? '<span class=\'current\'>' . $i . '</span>' : '<a href=\'' . get_pagenum_link($i) . '\' class=\'inactive\' >' . $i . '</a>';
			}

			++$i;
		}

		if (($paged < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($paged + 1) . '\'><i class=\'fa fa-angle-right\'></i></a>';
		}

		if (($paged < ($pages - 1)) && ((($paged + $range) - 1) < $pages) && ($showitems < $pages)) {
			echo '<a href=\'' . get_pagenum_link($pages) . '\'><i class=\'fa fa-angle-double-right\'></i></a>';
		}

		echo '</div>' . "\n";
	}
}

function en_begenilen($limit = 5)
{
	global $wpdb;
	$query = 'SELECT post_id, meta_value, post_status FROM ' . $wpdb->postmeta;
	$query .= ' LEFT JOIN ' . $wpdb->posts . ' ON post_id=' . $wpdb->posts . '.ID';
	$query .= ' WHERE post_status=\'publish\' AND meta_key=\'' . WPFP_META_KEY . '\' AND meta_value > 0 ORDER BY ROUND(meta_value) DESC LIMIT 0, ' . $limit;
	$results = $wpdb->get_results($query);

	if ($results) {
		echo '<ul class=\'defterdekiler\'>';

		foreach ($results as $o) {
			$p = get_post($o->post_id);
			$timthumb = get_template_directory_uri() . '/includes/timthumb.php?src=';
			$resim_link = wp_get_attachment_url(get_post_thumbnail_id($o->post_id));

			if ($resim_link == '') {
				$resim_link = get_template_directory_uri() . '/img/no-image.png';
			}

			echo "\t\t\t" . '<li>' . "\r\n\t\t\t\t" . '<div class="post-img"><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			altionaltithumb(310, 200, $o->post_id, 'grid');
			echo '</a></div>' . "\r\n\t\t\t\t" . '<span><a href="';
			echo get_permalink($o->post_id);
			echo '" title="';
			echo $p->post_title;
			echo '">';
			echo $p->post_title;
			echo '</a></span>' . "\r\n\t\t\t\t" . '<span class="yazar">';
			echo $o->meta_value;
			echo ' ';
			echo __('kiÅŸinin defterinde', 'altinoktaonalti');
			echo '</span>' . "\r\n" . '            </li>' . "\r\n" . '        ';
		}

		echo '</ul>';
	}
}

function insert_attachment($file_handler, $post_id, $setthumb = 'false')
{
	if ($_FILES[$file_handler]['error'] !== UPLOAD_ERR_OK) {
		__return_false();
	}

	require_once ABSPATH . 'wp-admin' . '/includes/image.php';
	require_once ABSPATH . 'wp-admin' . '/includes/file.php';
	require_once ABSPATH . 'wp-admin' . '/includes/media.php';
	$attach_id = media_handle_upload($file_handler, $post_id);

	if ($setthumb) {
		update_post_meta($post_id, '_thumbnail_id', $attach_id);
	}

	return $attach_id;
}

require get_template_directory() . '/admin/admin-init.php';
add_action('wp_head', 'lisans_yap');
require_once 'widgets/kategori.php';
require_once 'widgets/coklukategori.php';
require_once 'widgets/gunun-tarifi.php';
require_once 'widgets/en-begenilen-tarifler.php';
require_once 'widgets/yazarlar.php';
require_once 'widgets/video.php';
include_once 'includes/metabox.php';
include_once 'includes/categories-images.php';
add_action('admin_enqueue_scripts', 'ss_framework_admin_scripts');

if (!function_exists('ss_framework_admin_scripts')) {
	function ss_framework_admin_scripts($hook)
	{
		if (($hook == 'post.php') || ($hook == 'post-new.php')) {
			wp_register_script('tinymce_scripts', get_template_directory_uri() . '/includes/tinymce/js/scripts.js', array('jquery'), false, true);
			wp_enqueue_script('tinymce_scripts');
		}
	}
}

add_action('after_setup_theme', 'lang_setup');
add_action('admin_head', 'fonticon');
add_action('admin_enqueue_scripts', 'shortcodespopup');
add_action('admin_head', 'sitil_bilgileri');
add_action('init', 'theme_menus');
add_theme_support('post-thumbnails');
add_image_size('slider', 640, 350, true);
add_image_size('single', 500, 300, true);
add_image_size('category', 310, 175, true);
add_image_size('author', 60, 60, true);
add_image_size('favorite', 160, 120, true);
add_image_size('pratik', 100, 80, true);
add_image_size('singlefull', 630, 350, true);
add_image_size('benzer', 150, 150, true);
add_image_size('slidermini', 48, 41, true);
add_filter('manage_posts_columns', 'posts_column_views');
add_action('manage_posts_custom_column', 'posts_custom_column_views', 5, 2);

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Anasayfa'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Footer', 'before_widget' => '<div class="widget-footer">', 'after_widget' => '</div>', 'before_title' => '<div class="widget-title"><h2>', 'after_title' => '</h2></div>'));
}

if (function_exists('register_sidebar')) {
	register_sidebar(array('name' => 'Sidebar', 'before_widget' => '<div class="sidebar-alan">', 'after_widget' => '</div>', 'before_title' => '<div class="title"><h2><i class="fa fa-bars"></i>', 'after_title' => '</h2></div>'));
}

?>

Sizdeki functions.php İçeriğini Bununla Değiştirin Kolay Gelsin :)


Zimbabve'den Selamlar ;)

Zimbabve Hocam işlem tamamdır
Tekrar sağol ellerin dert görmesin

yolun açık olsun