
06-02-2012, 03:33:37
|
| |
Basit Radyo Script [Admin Panelli] | | Forumda bir arkadaşımız kişisel sayfa tasarımı paylaşmıştı. Onu biraz editleyerek birşeyler ekleyerek bu hale getirdim arkadaşlar.
Demo adresi: www.bozukradyo.com/yeni
İndir: www.bozukradyo.com/ucretsiz.rar
Admin panelide öyle bi düzenledim yayın akışını felan yazmak için. Neyse kuruluma geçelim arkadaşlar.
Öncelikle radyo.sql'yi mysql'den okutalım ve ayarlar.php'de aşağıdaki alanı kendimize göre düzenleyelim. Alıntı:
$database_host = "localhost"; // veritabani host adresi (genellikle: localhost)
$database_name = "bozukradyo"; // veritabani adi
$database_user = "bozukradyo"; // veritabani kullanici adi
$database_pass = "sifre"; // veritabani kullanici sifresi
| Sonrasında medya klasörünün içine girelim. Orda dinle.php dosyasını açalım ve Alıntı:
<div id="container"><a href="http://www.macromedia.com/go/getflashplayer">radyo dinleye bilmeniz icin Flash Player gereklidir</a> to see this player.</div>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
var s1 = new SWFObject("player.swf","ply","260","30","9","#0000 00");
s1.addParam("allowfullscreen","true");
s1.addParam("allowscriptaccess","always");
s1.addParam("flashvars","file=http://www2.bozukradyo.com:8448/;stream.nsv&type=sound&backcolor=000000&frontcolor =efefef&lightcolor=efefef&autostart=mp3&volume=70& autostart=true&skin=modieus.swf");
s1.write("container");
</script>
| ip adresimiz ile portumuzu yazalım. burda da işimiz bittikden sonra durum.php'yi açalım Alıntı:
<?php
include("stats/tr.php");
include('config_radio.php');
$ctx = stream_context_create(array(
'http' => array(
'timeout' => 10
)
)
);
@ini_set('user_agent', 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.10) Gecko/2009042316 WHMSonic/2.0.1');
$d = file_get_contents("http://www2.bozukradyo.com:8448/admin.cgi?mode=viewxml&pass=yayinsifresi");
if (!$d) {
echo "<font color=66CCFF><b>$GLOBALS[lang9]<br>$GLOBALS[lang8]</b></font>"; exit; } else {
$shoutcast_xml = new SimpleXMLElement($d);
$bitrate = utf8_decode($shoutcast_xml->BITRATE);
$streamstatus = utf8_decode($shoutcast_xml->STREAMSTATUS);
$currentlisteners = utf8_decode($shoutcast_xml->CURRENTLISTENERS);
$servertitle = utf8_decode($shoutcast_xml->SERVERTITLE);
$songtitle = utf8_decode($shoutcast_xml->SONGTITLE);
?>
<html>
<head>
<META HTTP-EQUIV="Refresh" CONTENT="25; URL=durum.php">
<link type="text/css" rel="stylesheet" href="stats/stats.css">
</head>
<body style="margin:0px;">
<div align="center">
<?php if($streamstatus == "1"){ echo ""; } else { echo "<font color=66CCFF><b>$GLOBALS[lang7]<br>$GLOBALS[lang8]</b></font>"; exit;} ?>
<br>
</div><br>
<table width="90%" border="0" cellspacing="2" cellpadding="0" align="center">
<tr>
<td width="25%">
<div align="right"><b><font color="#999999">BozukRADYO:</font></b><font color="#999999"></font>
</div>
</td>
<td width="75%">
<?php echo "<font color=green><b>Online</b></font>"; ?>
</td>
</tr>
<tr>
<td width="25%">
<div align="right"><b><font color="#999999"><?php echo $GLOBALS['lang3'];?>:</font></b></div>
</td>
<td width="75%">
<?php echo "<font color=black><b>$GLOBALS[servertitle]</b></font>"; ?>
</td>
</tr>
<tr>
<td width="25%">
<div align="right"><b><font color="#999999"><?php echo$GLOBALS['servertitle'];?>:</font></b>
</div>
</td>
<td width="75%">
<?php echo "<font color=black><b>$GLOBALS[songtitle]</b></font>"; ?>
</td>
</tr>
<tr>
<td width="25%">
<div align="right"><b><font color="#999999"><?php echo$GLOBALS['lang5'];?>:</font></b></div>
</td>
<td width="75%">
<?php echo "<font color=black><b>$GLOBALS[bitrate] KBPS</b></font>"; ?>
</td>
</tr>
</table>
</body>
</html>
<?php } ?>
| burda sadece www2.bozukradyo.com yazan yere ip adresiniz 8448 yazan yerede portunuzu yazın, yayinsifresi yazan yerede yayın şifrenizi yazın.
durum.php'de işimiz bittikden sonra şimdi istek.php'yi açalım. istek@bozukradyo.com yazan yere kendi email adresinizi yazın. Alıntı:
<title>BozukRADYO.COM | istek yolla</title>
<head>
</head>
<link rel="shortcut icon" href="br.ico">
<body background="http://www.bozukradyo.com/images/body-bg1.JPG" style="background-repeat:no-repeat;">
<center><?php
if(isset($_POST['submit'])){
$isim = $_POST['isim'];
$gon_email = $_POST['gon_email'];
$message = $_POST['message'];
if (empty($isim)) {
echo "<br><b style='color:#ff0000;'>Adiniz/Soyadiniz alanini bos biraktiniz!</b><br><a href='javascript:history.go(-1)'>Geri Dönün</a>\n";
}
elseif (empty($gon_email)) {
echo "<br><b style='color:#ff0000;'>Email Adresiniz alanini bos biraktiniz!</b><br><a href='javascript:history.go(-1)'>Geri Dönün</a>\n";
}
elseif (!eregi("^[_\.0-9a-z-]+@([0-9a-z][0-9a-z-]+\.)+[a-z]{2,3}$", $gon_email)) {
echo "<br><b style='color:#ff0000;'>Geçersiz <b>E-Mail Adresi</b> yazdiniz!<br><a href='javascript:history.go(-1)'>Geri Dönün</a>\n";
}
elseif (empty($message)) {
echo "<br><b style='color:#ff0000;'>Mesajiniz alanini bos biraktiniz!</b><br><a href='javascript:history.go(-1)'>Geri Dönün</a>\n";
}
else {
$to = "istek@bozukradyo.com"; // buraya email adresinizi yazin
$subject = "Radyo'dan istek veya mesaj";
$message = "
$isim ($gon_email) isimli bir kullanici iletisim formu ile asagidaki mesaji gönderdi;
$message
";
mail($to, $subject, $message, "From: $isim <$gon_email>");
echo "<br><br><br><br>Mesajiniz gönderildi. Ilginize tesekkür ederiz.";
}
}
// Mesaj formu
else {
echo "
<form name='form' action='".$_SERVER[PHP_SELF]."' method='post'>
<br><br><br><br><b> Adiniz - Soyadiniz </b> <br><input type='text' name='isim' size='25'><br>
<b> <br>Email Adresiniz </b> <br> <input type='text' name='gon_email' size='25'><br>
<br><b> Mesajiniz</b> <br> <textarea name='message' rows='5' cols='20'></textarea><br>
<input type='submit' name='submit' value='Mesaji Gönder'>
<input type='reset' name='reset' value='Temizle'>
</form>
";
}
?></center></body>
| şimdide js klasörünün içinde custom.js'yi düzenleyelim twitterdaki mesajlar için.
alifurkanyilmaz yazan yere twitter kullanıcı adınızı yazın. Alıntı:
$(document).ready(function() {
//REMOVES DISABLED JAVASCRIPT FIX CLASSES
$('#portfolio_slider').removeClass("slider_no_js") ;
$('#gallery_nav').removeClass("gallery_nav_no_js") ;
//INITIALIZES PRETTYPHOTO PLUGIN
$("a[rel^='prettyPhoto']").prettyPhoto({theme:'light_square'}); //choose between different styles / dark_rounded / light_rounded / dark_square / light_square / facebook /
//INITIALIZES TWITTER FEED PLUGIN
$("#twitter_feed").tweet({
username: "alifurkanyilmaz", //just enter your twitter username
join_text: "auto",
avatar_size: null,
count: 1, //number of tweets showing (to avoid any issues with the design leave at 1)
auto_join_text_default: "",
loading_text: "son tweetler yukleniyor.." //text displayed while loading tweets
});
//qTip TOOLTIPS
$.fn.qtip.styles.custom = {
fontSize: 10,
padding: 5,
background: '#d0d0d0',
color: '#606060',
border: {
width: 0,
radius: 0,
color: '#d0d0d0'
}
};
$('.click_box').qtip({
content: 'Click to see the popup panel...',
style: 'custom',
position: {
corner: {
target: 'topLeft',
tooltip: 'bottomLeft'
}
},
show: 'mouseover',
hide: 'mouseout'
});
//NAVIGATION
$('#navigation').each(function () {
var $links = $(this).find('a'),
panelIds = $links.map(function() { return this.hash; }).get().join(","),
$panels = $(panelIds),
$panelwrapper = $panels.filter(':first').parent(),
delay = 600,
heightOffset = 40; // we could add margin-top + margin-bottom + padding-top + padding-bottom of $panelwrapper
$panels.hide();
$links.click(function () {
$('.boxes').animate({opacity : 0}, 300, function () {
$('.boxes').hide();
});
var link = this,
$link = $(this);
var nextPage = $link.attr('href');
var newHeight = $(nextPage).outerHeight(true);
// ignore if already visible
if ($link.is('.selected')) {
return false;
}
$links.removeClass('selected');
$link.addClass('selected');
$panels.stop().animate({opacity: 0 }, delay);
$('.gallery img, .project').animate({opacity: 0 }, 600);
$('html, body').animate( {scrollTop: 0}, function () {
$panelwrapper.stop().animate({
height: newHeight
}, delay, function () {
var height = $panels.hide().filter(link.hash).animate({opacity: 1}).show().height() + heightOffset;
$('.gallery img, .project').animate({opacity: 1 }, 400);
$panelwrapper.animate({
height: height
}, delay);
});
});
});
$links.filter(window.location.hash ? '[hash=' + window.location.hash + ']' : ':first').click();
});
// CONTACT FORM
$('#contact_form').ajaxForm({
target: '#message_outcome',
beforeSubmit: function() {
$('#message_outcome').addClass('visible');
},
success: function() {
$('#message_outcome').show();
}
});
$('.textbox, #message').focus(function (){
$(this).css({borderColor : '#a9a9a9'});
$(this).blur(function (){
$(this).css({borderColor : '#cacaca'});
});
});
// SOCIAL LINKS FX
$('ul.social_links li').hover(function () {
$(this).css('backgroundColor' , '#dddddd');
}, function () {
$(this).css('backgroundColor' , '#e4e4e4');
});
//PORTFOLIO NAVIGATION
$('#portfolio_slider').cycle({
fx: 'fade',
speed: 500,
timeout: 0,
cleartype: false, // Fixes the issue with IE6+
startingSlide: 0,
next: '#next',
prev: '#prev'
});
$('#latest_projects_slider').cycle({
fx: 'fade',
speed: 500,
timeout: 5000,
cleartype: false, // Fixes the issue with IE6+
startingSlide: 0,
next: '',
prev: ''
});
// PORTFOLIO IMAGE OPACITY
$(function() {
$('.gallery img').animate({"opacity": 1 }); // sets the opacity to 100% to all images inside the div with the class of .gallery
$('.gallery img').hover(function() {
$(this).stop().animate({ "opacity": .5 }); // on mouse hover sets the opacity to 30% to all images inside the div with the class of .gallery
},
function() {
$(this).stop().animate({ "opacity": 1 });
});
});
// POPUP BOXES FUNCTIONS
$('boxes').css('opacity', 0);
$('.close_box').click(function () {
$('.boxes').animate({opacity : 0}, 600, function () {
$('.boxes').hide();
});
});
$('.click_box').click(function () {
if ( $('.boxes').is(':visible')) {
$('.boxes').animate({opacity : 0}).hide();
}
$($(this).attr('href')).show().animate({opacity : 1}, 600);
});
}); | Son olarak yonetim klasörünün içinde login.php'yi açalım admin kullanıcı adı ve şifreyi değiştirelim. Alıntı:
<?php
$user = 0;
$pass1 = 0;
$user = $_POST['yonetici'];
$pass1 = $_POST['ysifre'];
if ( $user == "admin" and $pass1 == "sifre")
{
ob_start();
session_start();
$_SESSION["admin"] = $user;
setcookie("cook", $ranx, time()+3600);
header('location:yonetim.php');
}
else {
header('location:index.php?kontrol=hata');
}
?>
| Arkadaşlar ilk defa script paylaşıyorum. Konuda bir yanlışlık varsa şimdiden kusura bakmayın.
Konu AFYILMAZ tarafından (04-03-2012 Saat 01:00:29 ) değiştirilmiştir..
|