Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- *
- * @ This file is created by deZender.Net
- * @ deZender (PHP5 Decoder for ionCube Encoder)
- *
- * @ Version : 1.1.5.0
- * @ Author : DeZender
- * @ Release on : 09.06.2012
- * @ Official site : http://DeZender.Net
- *
- */
- function uyeKontrol() {
- if (!$_SESSION['userID']) {
- @header( 'location:page.php?act=login&backto=' . @urlencode( $_SERVER['QUERY_STRING'] ) );
- exit( '<script>window.location = \'page.php?act=login&backto=' . urlencode( $_SERVER['QUERY_STRING'] ) . '\';</script>' );
- }
- }
- function slink($act, $op = '') {
- global $siteConfig;
- return ($siteConfig['seoURL'] ? $act . '_sp' . ($op ? '__op-' . $op : '') . '.html' : 'page.php?act=' . $act . ($op ? '&op=' . $op : ''));
- }
- function sepetGoster() {
- $sepet = str_replace( '<a ', '<xa ', showBasket( false ) );
- $sepet = str_replace( '</a>', '</xa> ', $sepet );
- $out = '<div id="sepetGoster">' . generateTableBox( '', $sepet, 'SepetBlock' ) . '</div>';
- return $out;
- }
- function alisverisSirasi() {
- global $tamamlandi;
- if ($_GET['act'] == 'sepet') {
- $out = 4;
- }
- if ($_GET['act'] == 'satinal') {
- if ($_GET['op'] == 'adres') {
- $out = 5;
- }
- if (( $_GET['op'] == 'adres' && $_POST['data_address'] )) {
- $out = 6;
- }
- if ($_GET['paytype']) {
- $out = 7;
- }
- if ($tamamlandi) {
- $out = 8;
- }
- }
- return $out;
- }
- function checkLogin() {
- if (function_exists( myCheckLogin )) {
- return myCheckLogin( );
- }
- global $siteConfig;
- if (basename( $_SERVER['PHP_SELF'] ) == 'update.php') {
- return null;
- }
- if (basename( $_SERVER['PHP_SELF'] ) == 'ajaxLib.php') {
- return null;
- }
- if (basename( $_SERVER['PHP_SELF'] ) == 'eposta.php') {
- return null;
- }
- if (( basename( $_SERVER['PHP_SELF'] ) == 'page.php' && $_GET['act'] == 'register' )) {
- return null;
- }
- if (basename( $_SERVER['PHP_SELF'] ) == 'login.php') {
- if (( $_SESSION['loginStatus'] || !$siteConfig['sadeceUye'] )) {
- header( 'location:index.php' );
- exit( '<script>window.location = \'index.php\';</script>' );
- }
- return null;
- }
- if (( !$_SESSION['loginStatus'] && $siteConfig['sadeceUye'] )) {
- header( 'location:login.php' );
- exit( '<script>window.location = \'login.php\';</script>' );
- }
- }
- function generateSlide($filter, $template = 'UrunListShow') {
- $q = my_mysql_query( 'select ID from urun ' . $filter );
- $out = '<div class="spSlides">' . '
- ';
- if ($d = mysql_fetch_array( $q )) {
- $out .= '<div class="spSlide">' . getUrun( $d['ID'], $template ) . '</div>' . '
- ';
- }
- $out .= '</div>';
- }
- function loginGoster() {
- if (function_exists( myLoginGoster )) {
- return myLoginGoster( );
- }
- global $login_message;
- $login = loginScreen( $login_message, false );
- $out = '<div id="loginGoster">' . generateTableBox( '', $login, 'LoginBlock' ) . '</div>';
- if ($login_message) {
- $out .= '' . '<script>$(document).ready(function() { $(\'#imgLoginGoster\').click(); });</script>';
- }
- return $out;
- }
- function insertToUserLog($key, $keyDetail, $value) {
- if ($_SESSION['userID']) {
- if (!( my_mysql_query( 'insert into userLog values(null,\'' . $_SESSION['userID'] . ( '' . '\',\'' . $key . '\',\'' . $keyDetail . '\',\'' . $value . '\',\'' ) . $_SERVER['REMOTE_ADDR'] . '\',now())' ))) {
- exit( mysql_error( ) );
- (bool)true;
- }
- }
- }
- function setStats($type) {
- switch ($type) {
- case 'updateKategori': {
- if (!( my_mysql_query( 'update kategori set hit=(hit + 1) where ID = \'' . $_GET['catID'] . '\'' ))) {
- exit( mysql_error( ) );
- (bool)true;
- }
- }
- }
- }
- function selfURL() {
- $s = ((empty( $_SERVER['HTTPS'] ) ? '' : $_SERVER['HTTPS'] == 'on') ? 's' : '');
- $protocol = strleft( strtolower( $_SERVER['SERVER_PROTOCOL'] ), '/' ) . $s;
- $port = ($_SERVER['SERVER_PORT'] == '80' ? '' : ':' . $_SERVER['SERVER_PORT']);
- return $protocol . '://' . $_SERVER['SERVER_NAME'] . $port . '/' . $_SERVER['REQUEST_URI'];
- }
- function strleft($s1, $s2) {
- return substr( $s1, 0, strpos( $s1, $s2 ) );
- }
- function alarmList($type) {
- global $currentAlarmList;
- $currentAlarmList = $type;
- return urunList( 'select urun.* from urun,alarmListe where urunID=urun.ID AND alarmListe.userID=\'' . $_SESSION['userID'] . '\' AND sent=0 AND type=\'' . $type . '\'', 'UrunListLite', 'UrunListLiteShow' );
- }
- function urunlerimList() {
- $userID = $_SESSION['userID'];
- $out .= urunList( 'select * from urun where userID=\'' . $userID . '\'', 'UrunListLite', 'UrunListLiteShow' );
- $maxUrun = hq( 'select maxUrun from user,userGroups,userGroupMembers where user.ID = userGroupMembers.userID AND user.ID = \'' . $userID . '\' AND userGroups.ID = userGroupMembers.userGroupID order by discount asc limit 0,1' );
- $toplamUrun = mysql_num_rows( my_mysql_query( 'select ID from urun where userID != 0 AND userID=\'' . $userID . '\'' ) );
- if ($toplamUrun < $maxUrun) {
- $out .= '<div class="urunEkle"><form action="page.php?act=urunlerim&op=urunEkle" method="post"><input type="submit" value="' . _lang_urunEkle . '"></form></div>';
- }
- return $out;
- }
- function seoURL($out) {
- return $out;
- }
- function jsBanner() {
- global $siteConfig;
- $out = '<script>
- ';
- $out .= 'var lastSelectedImage = 0;
- var timer;
- var web20Images = new Array();
- var web20ImageLine1 = new Array();
- var web20ImageLine2 = new Array();
- var web20ImageLink = new Array();';
- $q = my_mysql_query( 'select * from kampanyaJSBanner order by seq limit 0,5' );
- $i = 6;
- if ($d = mysql_fetch_array( $q )) {
- $out .= '' . 'web20Images[' . $i . '] = new Image();
- web20Images[' . $i . '].src = \'images/kampanya/' . $d['resimJS'] . ( '' . '\';
- web20ImageLine1[' . $i . '] = \'' ) . $d['info'] . ( '' . '\';
- web20ImageLine2[' . $i . '] = \'' ) . $d['info2'] . ( '' . '\'
- web20ImageLink[' . $i . '] = \'' ) . $d['link'] . '\'
- ';
- $title[$i] = $d['title'];
- $title2[$i] = $d['title2'];
- ++$i;
- }
- $out .= '</script>
- ';
- $out .= '<div style="width:695px; height:229px; overflow:hidden; position:relative;">
- <img id="c1" src="images/white.gif">
- <img id="c2" src="images/white.gif">
- <img id="c3" src="images/white.gif">
- <img id="c4" src="images/white.gif">
- <div style="float:left; width:486px; height:229px;overflow:hidden; position:absolute;"><img src="" id="picture" /><div id="infoLine" class="infoLine"></div><div class="infoMain" id="infoMain"><div id="infoLine1"></div><div id="infoLine2"></div>
- </div>
- </div>
- <div style="float:right; position:relative; width:215px;">';
- $i = 6;
- while ($i <= sizeof( $title )) {
- $out .= '<div class="button" id="button' . $i . '" onclick="change(' . $i . ')">
- <div class="line1">' . $title[$i] . '</div>
- <div class="line2">' . $title2[$i] . '</div>
- </div>';
- ++$i;
- }
- $out .= '</div>
- </div>
- <script>change(1)</script>';
- return $out;
- }
- function autoPaymentMerge($randStr, $body) {
- $q = my_mysql_query( '' . 'select * from siparis where randStr = \'' . $randStr . '\'' );
- $d = mysql_fetch_array( $q );
- if (mysql_num_rows( $q )) {
- $rplArray['siparisURL'] = '{%siteAdresiFull%}page.php?act=siparistakip&email=' . $d['email'] . '&sn=' . $d['randStr'];
- foreach ($d as $k => $v) {
- $rplArray[strtoupper( $k )] = $v;
- $rplArray[$k] = $v;
- }
- return (is_array( $body ) ? array_merge( $body, $rplArray ) : mergeText( $body, $rplArray ));
- }
- return $body;
- }
- function autoPaymentMergeArray($randStr, $body) {
- return autoPaymentMerge( $randStr, $body );
- }
- function anket($chartColor) {
- global $siteConfig;
- $anketID = hq( 'select ID from anketSoru where aktif=1 order by ID desc limit 0,1' );
- $oyKullanmismi = hq( 'select ID from anketIP where IP=\'' . $_SERVER['REMOTE_ADDR'] . '\' AND anketID = \'' . $anketID . '\'' );
- if (( $_POST['anketID'] && $_POST['t'][2] == $_GET['t4'][2] )) {
- if (!$oyKullanmismi) {
- if (!( my_mysql_query( 'insert into anketIP values(null,\'' . $_POST['anketID'] . '\',\'' . $_SERVER['REMOTE_ADDR'] . '\')' ))) {
- exit( mysql_error( ) );
- (bool)true;
- }
- $oy = hq( 'select Oy from anketCevap where ID=\'' . $_POST['oy'] . '\' limit 0,1' ) + 1;
- if (!( my_mysql_query( '' . 'update anketCevap set Oy=\'' . $oy . '\' where ID=\'' . $_POST['oy'] . '\'' ))) {
- exit( mysql_error( ) );
- (bool)true;
- }
- $oyKullanmismi = true;
- }
- }
- $out .= '<table cellspacing="0" cellpadding="0" class="anket"><form method="post">';
- $anketSoru = hq( 'select Soru from anketSoru where ID=\'' . $anketID . '\' limit 0,1' );
- $out .= '<input type="hidden" name="anketID" value="' . $anketID . '">';
- $out .= '<tr><td colspan=2 class="anketSoru">' . $anketSoru . '</td></tr>';
- $q = my_mysql_query( '' . 'select * from anketCevap where anketID=\'' . $anketID . '\' order by Seq' );
- if (!$oyKullanmismi) {
- if ($d = mysql_fetch_array( $q )) {
- $out .= '<tr><td class="anketCevap"><input id="anket_' . $d['ID'] . '" type="radio" name="oy" value="' . $d['ID'] . '"></td>';
- $out .= ' <td width=100%><label for="anket_' . $d['ID'] . '">' . $d['Cevap'] . '</label></td></tr>';
- }
- $out .= '<tr><td colspan=2><input class="anketGonder" type="image" src="templates/' . $siteConfig['templateName'] . '/images/form_Gonder.gif" style="cursor:pointer;"></td></tr>';
- } else {
- if ($d = mysql_fetch_array( $q )) {
- $chartArray[$d['Cevap']] = $d['Oy'];
- }
- $out .= '<tr><td valign="middle">' . generateChart( $chartArray, 'persentage', $chartColor ) . '</td></tr>';
- }
- $out .= '</form></table>';
- return $out;
- }
- ..................................................
- .........................
- ..........
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement