Xem bài viết đơn
  #1  
09-07-2010, 12:42 PM
adminbao adminbao is offline
Đầy Tớ Của Nhân Dân
Facebook: https://www.facebook.com/tuthienbaocom

Default [php] Code Clone của KyUcTinhYeu




Demo:



Chức năng:
Chẳng thiếu thứ gì từ NCT cả, List thành viên cũng nghe được hết.
Đặc biệt còn linh hoạt hơn là cho phép "Nghe theo danh sách tìm kiếm" ( Tìm Ca sĩ hoặc Bài hát ).

Skin: XanhHồng ( Cứ load trang 1 lần là lại change skin 1 lần )

Đọc kỹ hướng dẫn sử dụng trước khi dùng:

Mở file "functions.php" lên, tìm dòng:
Code:
$folder  = 'php/project/search';  
đây là folder chứa code, bạn sửa thành của bạn nhé.

File "kuty.js"
Tìm dòng:
Code:
function TitleSong(title)
{
  document.title =''+Replaces(title)+' | wWw.ChiaSeVn.Tk';
}
Thay thành của bạn là ok,

Quan trọng nhất là mỗi file "functions.php" kia thôi.

Còn bạn nào ko mún dùng 2 Css mỗi khi load trang ( tức là chỉ dùng 1 cái thui á, hoặc là tự dùng theo ý mình. Thì mở file "index.php" ra, tìm dòng:
Code:
<LINK href="<?php include('css.txt'); ?>" type=text/css rel=stylesheet>
thay
Code:
 <?php include('css.txt'); ?> 
thành file css của bạn.

Sau đó tìm đoạn này xóa đi nếu muốn:
Code:
 <?php 
//variable declarations 
$counter_data = "css.txt"; //counter data file 
$image_dir = "img/7"; //image directory 
$style = "text"; //enter text for text.Anything else for graphics 
//check if file exists 
if(!($fp = fopen($counter_data,"r+"))) die ("cannot open counter file"); 
//read in the current count from the file 
$count = fread($fp, 20); 
//close the file 
fclose($fp); 
//increment count 
if($count == 'xanh.css') 
{ $ghi = 'style.css' ; } 
elseif($count == 'style.css') 
{ 
$ghi = 'xanh.css'; 
} 
//echo $count; 
$fp = fopen($counter_data, "w"); 
fwrite($fp , $ghi); 
//close the file 
fclose($fp); 
?> 
Đoạn đó là đoạn để mình change Css, mình ghi nội dung vào file "css.txt"

Phần quảng cáo bên phải, là đoạn này trong file Index.php
Code:
<div id="adv"> 
<!-- begin: adv_nct --> 
<a target="_blank" href="http://kyuctinhyeu.oni.cc/huongdantainhac.html"><img src="http://img267.imageshack.us/img267/428/hddownload4ngaa.jpg" border="0"></a> 
<?php 
// echo $box_right 
?> 
        <div class="nct-adv"> 
  <div class="item"><div class="item-qc" id="qc-182" style="width: 300px; height: 100px;"></div><script type="text/javascript">    NCTQC2('182', '300', '100', 'http://img1.nhaccuatui.com/htmlQC/NCT_Home_Right3.htm');</script></div>    
        <div class="item"><div class="item-qc" id="qc-125" style="width: 300px; height: 250px;"></div><script type="text/javascript">    NCTQC2('125', '300', '250', 'http://img1.nhaccuatui.com/htmlQC/NCT_Music_Right3.htm');</script></div>    
  <div class="item"><div class="item-qc" id="qc-127" style="width: 300px; height: 820px;"></div><script type="text/javascript">    NCTQC2('127', '300', '820', 'http://kyuctinhyeu.oni.cc/nhac/video.php');</script></div>    
  </div> 
 </div>
Bật mí thêm 1 điều nữa, nhiều bạn ko biết cái Random ảnh trong Player của mình, trong code mình cũng có cả đấy, FuLL mà.
Cái đó là file "imgran_love.php":
Code:
 <?php  
// Code by Http://ChiaseVn.Tk - Y!m: nongdanbaclieu15 
$folder = 'bgplay/'; //tên thu muc chua hinh anh của bạn nhé, hj                     
$exts = 'JPG jpg jpeg png gif';  
$files = array(); $i = -1;  
if ('' == $folder) $folder = './';  
$handle = opendir($folder);  
$exts = explode(' ', $exts);  
while (false !== ($file = readdir($handle))) {  
    foreach($exts as $ext) {   
        if (preg_match('/\.'.$ext.'$/i', $file, $test)) {   
            $files[] = $file;  
            ++$i;  
            }  
        }  
    }  
closedir($handle);   
mt_srand((double)microtime()*1000000);   
$rand = mt_rand(0, $i);   
header('Location: '.$folder.$files[$rand]);  
?> 
Download:http://www.mediafire.com/?jkwgmdonytd
Pass: it-vn.org
TÌM BÀI VIẾT KHÁC SEARCH TRÊN THANH TIM KIẾM PHÍA TRÊN WEB
ĐÃ CẬP NHẬT HẾT SÁCH GIẢI CÁC MÔN CÁC LỚP VUI LÒNG ĐÁNH TÊN BÀI KÈM LỚP PHÍA TRÊN TÌM KIẾM

Trả Lời Với Trích Dẫn