一、因特网地址

  InetAddress类:实现主机名和因特网地址之间的转换。

    InetAddress address=InetAddress.getByName(String);返回一个InetAddress实例

    InetAddress[] address=InetAddress.getAllByName(host);获取所有主机的地址。

    InetAddress address=InetAddress.getLocalHost();获取本地主机的地址。

  1.  

结果为:

一、Socket(套接字)

  连接原理:

  

1、Socket客户端:

  Socket s=new Socket(ip,port);打开一个套接字,它是网络编程中的一个抽象概念,负责启动该程序内部和外部之间的通信。如果连接失败,将会抛出一个UnknownHostException异常;如果存才其他问题,将会抛出IOException异常。

  1.   InputStream inStream=s.getInputStream();用于接收数据。
  2.   OutputStream outStream=s.getOutputStream();用于发送数据。

2、套接字超时

  有两种超时情况:

    1):从套接字读取信息时,在有数据可供访问之前,读操作将会被堵塞。如类似in.nextLine();

      解决办法:调用setSoTimeout方法设置一个超时值。即调用s.setSoTimeout(1000);

    2):Socket(String host,int port)会一直堵塞,直到建立了到达机主的初始连接为止。(实例化Socket时会堵塞)

      解决办法:先构建一个无连接的套接字,然后再使用一个超时来进行连接的方法。即s.connect(new InetSocketAddress(host,port),timeout);

3、Socket服务器:

  它可以向客户端发送消息,一旦启动服务器程序,它便等待某个客户端连接到它的端口。ServerSocket用于建立套接字。

  1.   ServerSocket s=new ServerSocket(port);创建一个端口
  2.   Socket incoming=s.accept();告诉服务器不停等待,直到有客户端连接到这个端口,该方法会返回一个Socket对象,用这个对象得到输入、输出流。
  3.   InputStream inStream=incoming.getInputStream();接收数据
  4.   OutputStream outStream=incoming.getOutputStream();发送数据

  如果通过套接字发送文本,可以将流转换成扫描器和写入器。

  1. Scanner in=new Scanner(inStream);
  2.   PrintWriter out=new PrintWriter(outStream,true);
  3.   System.out.println("hello....");向客户端发送消息

  最后要关闭连接进来的套接字。

  1. incoming.close();关闭套接字 

 一个简单的服务器向客户端发送数据报的例子1:

  1. package socket;
  2. import java.net.*;
  3. public class server {
  4. public static void main(String[] args)throws Exception{
  5. DatagramSocket server=new DatagramSocket(3000);
  6. String str="hello";
  7. DatagramPacket packet=new DatagramPacket(str.getBytes(),str.length(),InetAddress.getLocalHost(),9000);
  8. server.send(packet);
  9. server.close();
  10. }
  11. }
  1. package socket;
  2. import java.net.*;
  3. import java.io.*;
  4. public class client {
  5. public static void main(String[] args)throws IOException{
  6. byte[] buf=new byte[1024];
  7. DatagramPacket packet=new DatagramPacket(buf,1024);
  8. DatagramSocket client=new DatagramSocket(9000);
  9. client.receive(packet);
  10. String str=new String(buf,0,packet.getLength());
  11. System.out.println(packet.getAddress().getHostName()+":"+str);
  12. client.close();
  13. }
  14. }

结果为:Feng:hello

例子2:简单的聊天设计

  服务器端:

  1. package socket;
  2.  
  3. import java.awt.BorderLayout;
  4. import java.awt.event.ActionEvent;
  5. import java.awt.event.ActionListener;
  6. import java.io.BufferedReader;
  7. import java.io.InputStreamReader;
  8. import java.io.PrintStream;
  9. import java.net.InetAddress;
  10. import java.net.ServerSocket;
  11. import java.net.Socket;
  12.  
  13. import javax.swing.JButton;
  14. import javax.swing.JFrame;
  15. import javax.swing.JPanel;
  16. import javax.swing.JScrollPane;
  17. import javax.swing.JTextArea;
  18. import javax.swing.JTextField;
  19.  
  20. @SuppressWarnings("serial")
  21. public class Server3 extends JFrame{
  22. static JTextArea area;
  23. JTextField field;
  24. JButton button;
  25. static PrintStream writer;
  26. public Server3(){
  27. this.setTitle("服务器");
  28. this.setSize(400,500);
  29. area = new JTextArea(25,30);
  30. area.setEditable(false);
  31. field = new JTextField(20);
  32. button = new JButton("提交");
  33. JPanel panel = new JPanel();
  34. JScrollPane sp = new JScrollPane(area);
  35. this.add(sp,BorderLayout.CENTER);
  36. panel.add(field);
  37. panel.add(button);
  38. this.add(panel,BorderLayout.SOUTH);
  39. this.setVisible(true);
  40. this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  41.  
  42. button.addActionListener(new ActionListener(){
  43.  
  44. @Override
  45. public void actionPerformed(ActionEvent e) {
  46. String text = field.getText();
  47. writer.println(text);
  48. area.append("我:"+text+"\n");
  49. field.setText("");
  50. }
  51. });
  52. }
  53. public static void main(String[] args) throws Exception {
  54. Server3 s = new Server3();
  55. ServerSocket server = new ServerSocket(8899);
  56. System.out.println("开始监听...");
  57. Socket socket = server.accept();
  58. InetAddress address = socket.getInetAddress();
  59. String name = address.getLocalHost().getHostName();
  60. System.out.println(name+"已连接");
  61. BufferedReader reader = new BufferedReader(new InputStreamReader(socket.getInputStream()));
  62. writer = new PrintStream(socket.getOutputStream(), true);
  63. while (true) {
  64. String line = null;
  65. line = reader.readLine();
  66. if (line != null) {
  67. area.append("客户端:"+line+"\n");
  68. }
  69.  
  70. }
  71. }
  72.  
  73. }

  客户端:

  1. package socket;
  2. import java.awt.BorderLayout;
  3. import java.awt.event.ActionEvent;
  4. import java.awt.event.ActionListener;
  5. import java.io.BufferedReader;
  6. import java.io.InputStreamReader;
  7. import java.io.OutputStream;
  8. import java.io.PrintStream;
  9. import java.io.PrintWriter;
  10. import java.net.Socket;
  11.  
  12. import javax.swing.JButton;
  13. import javax.swing.JFrame;
  14. import javax.swing.JPanel;
  15. import javax.swing.JScrollPane;
  16. import javax.swing.JTextArea;
  17. import javax.swing.JTextField;
  18.  
  19. public class Client3 extends JFrame{
  20.  
  21. static JTextArea area;
  22. JTextField field;
  23. JButton button;
  24. static PrintWriter writer;
  25. public Client3(){
  26. this.setTitle("客户端");
  27. this.setSize(400,500);
  28. area = new JTextArea(25,30);
  29. area.setEditable(false);
  30. field = new JTextField(20);
  31. button = new JButton("提交");
  32. JScrollPane sp = new JScrollPane(area);
  33. JPanel panel = new JPanel();
  34. this.add(sp,BorderLayout.CENTER);
  35. panel.add(field);
  36. panel.add(button);
  37. this.add(panel,BorderLayout.SOUTH);
  38. this.setVisible(true);
  39. this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  40.  
  41. button.addActionListener(new ActionListener(){
  42.  
  43. @Override
  44. public void actionPerformed(ActionEvent e) {
  45. String text = field.getText();
  46. writer.println(text);
  47. area.append("我:"+text+"\n");
  48. field.setText("");
  49. }
  50.  
  51. });
  52. }
  53. public static void main(String[] args) throws Exception{
  54. Client3 c = new Client3();
  55. Socket socket = new Socket("127.0.0.1",8899);
  56. OutputStream out = socket.getOutputStream();
  57. BufferedReader reader1 = new BufferedReader(new InputStreamReader(socket.getInputStream()));
  58. writer = new PrintWriter(out,true);
  59. System.out.println("已经成功和服务器连接...");
  60. while(true){
  61. String line = reader1.readLine();
  62. area.append("服务器:"+line+"\n");
  63. }
  64. }
  65.  
  66. }

4、为多个客户端服务

  当多个客户端连接到服务器时,要用到线程机制。每当程序建立一个新的套接字连接,也就是当调用accept时,将启动一个新的线程来处理服务器和该客户端之间的连接(一个服务器一个线程),而主程序将返回并等待下一个连接。即执行如下命令:

  1. while(true){
  2.       Socket incoming=s.accpet();
  3.       Runnable r=new ThreadEchoHandler(incoming);   
  4.  
  5.       Thread t=new Thread(r);
  6.       t.start();
  7.     }

例子:

  1. package socket;
  2. import java.net.*;
  3. import java.io.*;
  4. import java.util.*;
  5. public class server1 {
  6. public static void main(String[] args)throws Exception{
  7. try{int i=1;
  8. ServerSocket s=new ServerSocket(9000);
  9. while(true){
  10. Socket incoming=s.accept();
  11. PrintWriter out=new PrintWriter(incoming.getOutputStream(),true);
  12. Runnable r=new ThreadedEchoHandler(incoming);
  13. Thread t=new Thread(r);
  14. t.start();
  15. i++;
  16. Scanner in=new Scanner(System.in);
  17. while(in.hasNextLine()){
  18. System.out.println(in.nextLine());
  19. }
  20. }
  21. }catch(Exception e){e.printStackTrace();}
  22. }
  23. }
  24. class ThreadedEchoHandler implements Runnable{
  25. private Socket s;
  26. public ThreadedEchoHandler(Socket i){
  27. s=i;
  28. }
  29. public void run(){
  30. try{
  31. try{
  32. Scanner in=new Scanner(s.getInputStream());
  33. String str=null;
  34. while(true){
  35. str=in.nextLine();
  36. System.out.println("客户端说:"+str);
  37. }
  38. }
  39. finally{s.close();}
  40. }
  41. catch(Exception e){e.printStackTrace();}
  42. }
  43. }
  1. package socket;
  2. import java.net.*;
  3. import java.io.*;
  4. import java.util.*;
  5. public class clent1 {
  6. public static void main(String[] args)throws Exception{
  7. try{int i=1;Socket s=new Socket("localhost",9000);
  8. while(true){
  9. PrintWriter out=new PrintWriter(s.getOutputStream(),true);
  10. Runnable r=new ThreadedEchoHandler1(s);
  11. Thread t=new Thread(r);
  12. t.start();
  13. i++;
  14. Scanner in=new Scanner(System.in);
  15. while(in.hasNextLine()){
  16. System.out.println(in.nextLine());
  17. }
  18. }
  19. }catch(Exception e){e.printStackTrace();}
  20. }
  21. }
  22. class ThreadedEchoHandler1 implements Runnable{
  23. private Socket s;
  24. public ThreadedEchoHandler1(Socket i){
  25. s=i;
  26. }
  27. public void run(){
  28. try{
  29. try{
  30. Scanner in=new Scanner(s.getInputStream());
  31. String str=null;
  32. while(true){
  33. str=in.nextLine();
  34. System.out.println("客户端"+s+"说:"+str);
  35. }
  36. }
  37. finally{s.close();}
  38. }
  39. catch(Exception e){e.printStackTrace();}
  40. }
  41. }

5、半关闭

  当我们在向服务器发送数据时,但并不知道要传输多少数据。在向文件写数据时,我们需要在写入后关闭文件即可。但是,如果关闭了一个套接字,那么与服务器就立刻断开了,因而无法读取服务器响应了。用半关闭的方法解决上述问题。可以通过关闭一个套接字的输出流来表示发送给服务器的请求数据已经结束,但是必须保持输入流处于打开状态。

socket.shutdownOutput();关闭输出流。

  例如:客户端发送hello给服务器后,关闭输出流,服务器收到后,关闭输入流,等待5秒后,向客户端发送ECHO hello。

  1. package socket;
  2. import java.io.PrintWriter;
  3. import java.net.*;
  4. import java.util.Scanner;
  5.  
  6. public class server {
  7. public static void main(String[] args)throws Exception{
  8. ServerSocket server=new ServerSocket(9000);
  9. Socket s=server.accept();
  10. Scanner in=new Scanner(s.getInputStream());
  11. PrintWriter out=new PrintWriter(s.getOutputStream());
  12. String str=in.nextLine();
  13. System.out.println(str);
  14. s.shutdownInput();
  15. System.out.println("关闭输入流");
  16. Thread.sleep(5000);
  17. out.println("ECHO"+str);
  18. s.close();
  19. }
  20. }
  1. package socket;
  2. import java.net.*;
  3. import java.util.Scanner;
  4. import java.io.*;
  5. public class client {
  6. public static void main(String[] args)throws IOException{
  7. Socket s=new Socket("localhost",9000);
  8. Scanner in=new Scanner(s.getInputStream());
  9. PrintWriter out=new PrintWriter(s.getOutputStream());
  10. out.println("hello");
  11. s.shutdownOutput();
  12. System.out.println("关闭连接");
  13. while(in.hasNextLine()){
  14. System.out.println(in.nextLine());
  15. }
  16. s.close();
  17. }
  18. }

6、可中断套接字

  用户希望在任何时刻都可以中断套接字连接,可以考虑可中断套接字连接机制。java.nio包提供了SocketChannel类。

    Socket(Channel channel)=SocketChanne.open(new InetSocketAddress(host,port));打开SocketChannel:

  通道(channel)并没有与之关联的流。实际上,它所拥有的read和write方法都是通过使用Bufffer对象实现的。如果不想处理缓冲区,可以使用Scanner类从SocketChannel中读取信息。即:

    Scanner in=new Scanner(channel);

  通过调用静态方法Channels.newOutputStream,可以将通道转换成输出流。

    OutputStream outStream=Channels.newOutputStream(channel);   

 三、获取Web数

1、URI

  1):URI:统一资源标识符,用于标识一个web资源,包含了两个部分。

    (1)URL:统一资源定位符。能够精确的定位数据的URI

    (2)URN:统一资源名称。除了URL的URI

  在java中URI和URL是分开的两个类,URI类专门用于解析,URL用于通信。

  2):URI的分类

    绝对和相对:

      (1)绝对URI是指有确定的协议。比如http,ftp。后面以/进行分隔

      (2)相对URI是没有scheme的。

    透明和不透明:

      不透明URI是不能够被解析的URI。不透明URI是绝对URI。scheme后面的部分不是以/进行分割。

    分层和不分层:

      分层是绝对透明URI或相对URI。所有的网页端口都是80;

  3):URI的作用

    (1)解析:解析标识符并将它分解成各种不同的组成部分。

       URI的格式:[scheme:]scheme-specific-part[#fragment]

        scheme表示用的协议,可以是http\https\ftp\file等。

        scheme-specific-part是其余部分

      常用的方法:

        getScheme()获得scheme;

        getSchemeSpecificPart();

        getPath()

        getAuthority()

    (2)转换:处理绝对标识符和相对标识符,实现转换。

      URI类同时支持以下两个操作:relative和combined

  示例代码:

    任务1:取得特定网址的html代码。

    任务2:分析地址信息。

    任务3:绝对地址和相对地址转换

  1. package socket;
  2. import java.net.*;
  3. import java.util.Scanner;
  4. public class URItest {
  5. public static void main(String[] args)throws Exception{
  6. URL url=new URL("http://www.yinyuetai.com");
  7. Scanner in=new Scanner(url.openStream());
  8. while(in.hasNextLine()){
  9. String str=in.nextLine();
  10. System.out.println(str);
  11. }
  12.  
  13. URI uri=new URI("http://www.cnblogs.com/liuzhongfeng");
  14. System.out.println(uri.getScheme());
  15. System.out.println(uri.getSchemeSpecificPart());
  16. System.out.println(uri.getAuthority());
  17. System.out.println(uri.getUserInfo());
  18. System.out.println(uri.getHost());
  19. System.out.println(uri.getPort());
  20. System.out.println(uri.getPath());
  21. System.out.println(uri.getQuery());
  22. System.out.println(uri.getFragment());
  23. String str="/p/5084309";
  24. URI combined=uri.resolve(str);
  25. System.out.println(combined.getScheme()+combined.getSchemeSpecificPart());
  26. URI relative=uri.relativize(new URI(str));
  27. System.out.println(relative.getSchemeSpecificPart());
  28.  
  29. }
  30. }
  1. <!DOCTYPE HTML>
  2. <html lang="zh-cmn-Hans">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="keywords" content="MV,MTV,楂樻竻MV,MV涓嬭浇,楂樻竻MTV涓嬭浇,MV鍏嶈垂涓嬭浇,楂樻竻MV鍏嶈垂涓嬭浇,MV瑙嗛,闊充箰MV,鍦ㄧ嚎瑙傜湅,MV鎵嬫満鍏嶈垂涓嬭浇,瑙嗛,鍦ㄧ嚎瑙嗛MTV,鍙h路FAN"/>
  6. <meta name="description" content="闊虫偊Tai-鍏ㄧ悆鏈?澶х殑楂樻竻MV缃戠珯锛屾彁渚涢珮鍝佽川闊充箰瑙嗛鍦ㄧ嚎瑙傜湅鏈嶅姟銆傚悓鏃朵篃鏄浗鍐呮渶澶х殑绮変笣绀惧尯锛岃秴杩?2000涓囬煶涔愮埍濂借?呭湪杩欓噷鑱氶泦銆?"/>
  7. <meta name="viewport" content="width=1002">
  8. <meta name="baidu-site-verification" content="d23b76SBuk"/>
  9. <meta name="baidu-tc-cerfication" content="ffb166fcdf37d755dda2b0bd0e707808"/>
  10. <meta property="qc:admins" content="647506777761161554116375"/>
  11. <link rel="search" type="application/opensearchdescription+xml" title="闊虫偊鍙癕V鎼滅储" href="/glossary/yyt_glossary.xml"/>
  12. <title>闊虫偊Tai-鍙h路FAN-鐪嬪ソ闊充箰</title>
  13. <link href="http://s.yytcdn.com/201512221437/css/common.css" rel="stylesheet" type="text/css">
  14. <link href="http://s.yytcdn.com/201512221437/css/app/main/index.css" rel="stylesheet" type="text/css">
  15.  
  16. <meta name="apple-itunes-app" content="app-id=767238876"/>
  17. <script src="http://s.yytcdn.com/v2/js/require.2.1.9-jquery.1.10.2-underscore.1.5.2-backbone.1.0.0.js"></script>
  18. <script>
  19. var _hmt = [];
  20. var Y = Y || {}, config = config || {};
  21. Y.jsBaseUrl = "http://s.yytcdn.com/201512221437/js/";
  22. Y.domains = {
  23. urlStatic : "http://s.yytcdn.com",
  24. loginSite : "http://login.yinyuetai.com",
  25. mainSite : "http://www.yinyuetai.com",
  26. mvSite : "http://mv.yinyuetai.com",
  27. homeSite : "http://i.yinyuetai.com",
  28. vchartSite : "http://vchart.yinyuetai.com",
  29. commentSite : "http://comment.yinyuetai.com",
  30. playlistSite : "http://pl.yinyuetai.com",
  31. searcresiehSite : "http://so.yinyuetai.com",
  32. vSite : "http://v.yinyuetai.com",
  33. fanSite : "",
  34. paySite : "",
  35. tradeSite : "",
  36. shopSite : "",
  37. vipSite : ""
  38. };
  39. Y.swfs = {
  40. mvplayer : "http://s.yytcdn.com/swf/common/mvplayer.swf?t=2015110713",
  41. playerloader : "http://s.yytcdn.com/swf/common/playerloader.swf?rev",
  42. explayer : "http://s.yytcdn.com/swf/common/explayer.swf?rev",
  43. markerlocation : 'http://s.yytcdn.com/swf/common/marker.swf?rev'
  44. };
  45. Y.comment = {};
  46. flashObj = {};
  47. </script>
  48. <script src="http://s.yytcdn.com/201512221437/js/common.js"></script>
  49. <script src="https://api.geetest.com/get.php"></script>
  50. <script type="text/javascript">
  51. Y.pcpusher = typeof Y.pcpusher === "undefined" ? true : Y.pcpusher; //榛樿鏄剧ず
  52. Y.returntop = true;
  53. $(function() {
  54. if (!Y.isLoadByPartner) {
  55. require(["prober"], function(prober) {
  56. setTimeout(function() {
  57. var n = "pc, mac";
  58. if (n.indexOf(prober.device.name) !== -1) {
  59. if (Y.returntop) {
  60. require(['modules/yinyuetai/returntop']);
  61. }
  62. if (Y.pcpusher) {
  63. require(['modules/yinyuetai/pcpusher']);
  64. }
  65. }
  66. }, 1500)
  67. });
  68. }
  69. })
  70. </script>
  71. <script>
  72. require(['juicer', 'uri'], function(juicer, Uri) {
  73. var uri = new Uri(location.href);
  74.  
  75. juicer.register('tongji_link', function(link, index) {
  76. if (uri.getQueryParamValue('f')) {
  77. return link + '?f=' + uri.getQueryParamValue('f') + '-' + (parseInt(index) + 1);
  78. } else {
  79. return link;
  80. }
  81. });
  82. });
  83. </script>
  84. <script type="text/javascript">
  85. if (!window.UA_Opt) {
  86. var UA_Opt = new Object;
  87. UA_Opt.SendMethod = 1;
  88. UA_Opt.FormId = "loginBoxForm";
  89. UA_Opt.ExTarget = ['password'];
  90. window[UA_Opt.LogVal] = "";
  91. UA_Opt.Token = new Date().getTime() + ":" + Math.random();
  92. UA_Opt.MaxMCLog = 50;
  93. UA_Opt.MaxKSLog = 50;
  94. UA_Opt.MaxMPLog = 50;
  95. UA_Opt.MaxTCLog = 50;
  96. UA_Opt.MaxFocusLog = 50;
  97. UA_Opt.Flag = 1965567;
  98. }
  99. </script>
  100. <script type='text/javascript' src='//uaction.alicdn.com/js/uab.js'></script>
  101. <script>
  102. //闃叉鍔犺浇澶辫触锛屽紓姝ヤ竴娆?
  103. (function() {
  104. if (typeof(window.acjs) == 'undefined') {
  105. var _script = document.createElement('script');
  106. _script.src = '//acjs.aliyun.com/js/uab.js';
  107. document.body.appendChild(_script);
  108. }
  109. })();
  110. </script>
  111.  
  112. <script type="text/javascript">
  113. Y.siteName = "www";
  114. </script>
  115. </head>
  116. <body>
  117.  
  118. <script type="text/javascript">
  119. var ua = window.navigator.userAgent.toLowerCase();
  120.  
  121. if (ua.indexOf("iphone") > 0 || ua.indexOf("android") > 0) {
  122. window.location.href = "http://m.yinyuetai.com" + window.location.search;
  123. }
  124. </script>
  125.  
  126. <script text="text/javaScript">
  127. if (!TRACK_SHOW || TRACK_SHOW.length < 1) {
  128. var TRACK_SHOW = new Array();
  129. }
  130.  
  131. TRACK_SHOW.push("http://t.collect.yinyuetai.com/v?a=104086&t=1451479895973");
  132.  
  133. (function() {
  134. if (TRACK_SHOW.length && (window != window.parent)) {
  135. for (var i = 0; i < TRACK_SHOW.length; i++) {
  136. var img = document.createElement('img');
  137. img.src = TRACK_SHOW[i] + '&t=' + new Date().getTime();
  138. document.body.appendChild(img);
  139. }
  140.  
  141. window.stop ? window.stop() : document.execCommand("Stop");
  142. }
  143. })();
  144. </script>
  145.  
  146. <!-- Start topbar -->
  147.  
  148. <div class="topbar">
  149. <div class="content">
  150. <h1 class="fl">
  151. <a href="http://www.yinyuetai.com" class="logo" title="闊虫偊Tai">闊虫偊Tai - Logo</a>
  152. </h1>
  153. <ul class="menus fl">
  154. <li class="menu hoverhandler">
  155.  
  156. <ul class="dropdownmenu fillet">
  157. <li>
  158. <a href="http://i.yinyuetai.com/myhome/mv" class="">鎴戠殑MV</a>
  159. </li>
  160. <li>
  161. <a href="http://i.yinyuetai.com/myhome/pl" class="">鎴戠殑鎮﹀崟</a>
  162. </li>
  163. <li>
  164. <a href="http://i.yinyuetai.com/myhome/blog" class="">鎴戠殑鏃ュ織</a>
  165. </li>
  166. <li>
  167. <a href="http://i.yinyuetai.com/myhome/album" class="">鎴戠殑鐩稿唽</a>
  168. </li>
  169. <li>
  170. <a href="http://i.yinyuetai.com/myhome/fan" class="">鎴戠殑楗洟</a>
  171. </li>
  172. <li>
  173. <a href="http://i.yinyuetai.com/myhome/friend" class="">鎴戠殑鎮﹀弸</a>
  174. </li>
  175. <li>
  176. <a href="http://i.yinyuetai.com/myhome/preview" class="fillet ">鎴戠殑灞曠ず椤?</a>
  177. </li>
  178. </ul>
  179. </li>
  180.  
  181. <li class="menu">
  182. <a href="http://www.yinyuetai.com" class="link current">棣栭〉</a>
  183. </li>
  184. <li class="menu hoverhandler">
  185. <a href="http://mv.yinyuetai.com" class="link "><span class="fl"
  186. style="*margin-top:-1px;">MV</span><b
  187. class="fl"></b></a>
  188. <ul class="dropdownmenu fillet">
  189. <li>
  190. <a href="http://mv.yinyuetai.com" class="fillet ">MV棰戦亾</a>
  191. </li>
  192. <li>
  193. <a href="http://mv.yinyuetai.com/recommend" class="">鎺ㄨ崘MV</a>
  194. </li>
  195.  
  196. <li>
  197. <a href="http://mv.yinyuetai.com/all?sort=weekViews" class="fillet ">鍏ㄩ儴MV</a>
  198. </li>
  199.  
  200. </ul>
  201. </li>
  202. <li class="menu hoverhandler">
  203. <a href="http://pl.yinyuetai.com" class="link " title="鎮﹀崟"><span class="fl">鎮﹀崟</span><b class="fl"></b></a>
  204. <ul class="dropdownmenu fillet">
  205. <li>
  206. <a href="http://pl.yinyuetai.com/" class="">鎺ㄨ崘鎮﹀崟</a>
  207. </li>
  208. <li>
  209. <a href="http://pl.yinyuetai.com/person_recommend" class="">鎮﹀崟杈句汉</a>
  210. </li>
  211. <li>
  212. <a href="http://pl.yinyuetai.com/playlist_newRecommend"
  213. class="fillet ">鍏ㄩ儴鎮﹀崟</a>
  214. </li>
  215. </ul>
  216. </li>
  217. <li class="menu hoverhandler">
  218. <a href="http://vchart.yinyuetai.com/vchart" class="link "><span
  219. class="fl">V姒?</span><b class="fl"></b></a>
  220. <ul class="dropdownmenu fillet">
  221. <li>
  222. <a href="http://vchart.yinyuetai.com/vchart" class="">鑱氱劍</a>
  223. </li>
  224. <li>
  225. <a href="http://vchart.yinyuetai.com/vchart/trends" class="fillet ">鎵撴鍔ㄦ??</a>
  226. </li>
  227. <li>
  228. <a href="http://vchart.yinyuetai.com/vchart/v" class="fillet ">鍛ㄦtop20</a>
  229. </li>
  230. <li>
  231. <a href="http://vchart.yinyuetai.com/vchart/month" class="fillet ">鏈堟top10</a>
  232. </li>
  233. </ul>
  234. </li>
  235. <li class="menu">
  236. <a href="http://fan.yinyuetai.com" class="link ">绮変笣鑱氱劍</a>
  237. </li>
  238. <li class="menu">
  239. <a href="http://shop.yinyuetai.com" class="link ">鍟嗗煄</a>
  240. </li>
  241.  
  242. <li class="menu">
  243. <a href="http://news.yinyuetai.com" class="link ">璧勮</a>
  244. </li>
  245. <li class="menu hoverhandler">
  246. <a href="http://www.yinyuetai.com/apps/mobile/tian" target="_blank" class="link"><span class="fl ">搴旂敤</span><b
  247. class="fl"></b></a>
  248. <ul class="dropdownmenu fillet">
  249. <li>
  250. <a href="http://www.yinyuetai.com/apps/mobile" target="_blank" class="">绉诲姩瀹㈡埛绔?</a>
  251. </li>
  252. <li>
  253. <a href="http://www.yinyuetai.com/apps/mobile/tian" target="_blank" class="" title="鑸?">鑸?</a>
  254. </li>
  255. <li>
  256. <a href="http://tv.yinyuetai.com" class="">闊虫偊TV</a>
  257. </li>
  258. <li>
  259. <a href="http://www.yinyuetai.com/apps/yinyue_mini" target="_blank" class="fillet ">妗岄潰瀹㈡埛绔?</a>
  260. </li>
  261. </ul>
  262. </li>
  263. <li class="menu hoverhandler">
  264. <a href="http://program.yinyuetai.com" class="link "><span
  265. class="fl">鑺傜洰</span><b class="fl"></b></a>
  266. <ul class="dropdownmenu fillet">
  267. <li>
  268. <a href="http://program.yinyuetai.com" class="">鐐规挱鑺傜洰</a>
  269. </li>
  270. <li>
  271. <a href="http://www.yinyuetai.com/show" class="">鐩存挱鑺傜洰</a>
  272. </li>
  273. </ul>
  274. </li>
  275. <li class="menu hoverhandler">
  276.  
  277. <a href="http://vip.yinyuetai.com/fanclub" class="link "><span
  278. class="fl">Fan Club</span><b class="fl"></b></a>
  279. <ul class="dropdownmenu fillet">
  280. <li>
  281. <a href="http://vip.yinyuetai.com/fanclub" class="" title="Fan Club">Fan Club</a>
  282. </li>
  283. <li>
  284. <a href="http://www.yinyuetai.com/apps/fanapp" class="fillet " title="鍙h路FAN">鍙h路FAN</a>
  285. </li>
  286. </ul>
  287. </li>
  288. <li class="menu hoverhandler">
  289.  
  290. <a href="http://stage.yinyuetai.com" class="link "><span
  291. class="fl">闊虫偊Stage</span></a>
  292. </li>
  293.  
  294. <li class="menu hoverhandler">
  295. <span class="new-tian"></span>
  296. <a href="http://tian.web.yinyuetai.com/" class="link "><span
  297. class="fl">鑸?</span></a>
  298. </li>
  299. </ul>
  300. <ul class="userinfo fr hide">
  301. <li class="user fr hoverhandler">
  302. <a class="link" href="http://i.yinyuetai.com"><span class="fl username"></span><b class="fl"></b></a>
  303. <ul class="dropdownmenu fillet">
  304. <li>
  305. <a href="http://i.yinyuetai.com/userId?preview&setskin=1" class="decoration">瑁呮壆鎴戠殑瀹?</a>
  306. </li>
  307. <li>
  308. <a href="http://i.yinyuetai.com/settings/profile">涓汉璁剧疆</a>
  309. </li>
  310. <li>
  311. <a href="http://trade.yinyuetai.com?r=1451479894035">鎴戠殑璁㈠崟</a>
  312. </li>
  313. <li>
  314. <a href="http://i.yinyuetai.com/authen/index">璁よ瘉涓績</a>
  315. </li>
  316. <li>
  317. <a href="http://login.yinyuetai.com/logout" class="fillet">閫?鍑?</a>
  318. </li>
  319. </ul>
  320. </li>
  321. <li class="notification fr hoverhandler">
  322. <a href="http://i.yinyuetai.com/news/index" class="messenger">閫氱煡</a>
  323. <span class="number hide"></span>
  324. <ul class="dropdownmenu fillet hide">
  325. </ul>
  326. </li>
  327. <li class="msg_close_li">
  328. <a href="javascript:void(0);" class="msg_close hide"></a>
  329. </li>
  330. </ul>
  331. <div class="login fr">
  332. <a class="loginBtn J_login" href="http://login.yinyuetai.com/login">鐧诲綍</a>
  333. <a href="http://login.yinyuetai.com/register">娉ㄥ唽</a>
  334. </div>
  335. <div class="login fr" style="width: 50px;">
  336. <a class="loginBtn" href="http://vip.yinyuetai.com" style="border-right: 0;padding-right: 0;margin-right: 0;">VIP浼氬憳</a>
  337. </div>
  338. <div class="search hide fr">
  339. <div class="left_park_side"></div>
  340. <div class="right_park_side"></div>
  341. <form action="http://so.yinyuetai.com" target="_blank">
  342. <div class="searchbody">
  343.  
  344. <input type="text" name="keyword" autocomplete="off" data-url="http://v.yinyuetai.com/video/2449042"
  345. placeholder="鏉庢椽鍩轰笓璁胯牏钀屾寫鎴樼數鍙癉J"/>
  346.  
  347. </div>
  348. <button type="submit">鎼滅储</button>
  349. </form>
  350. <ul class="autocomplete autocompletehide">
  351. </ul>
  352. </div>
  353. </div>
  354. <script type="text/tmp" id="autocompleteTpl">
  355. <li class="h39"></li>
  356. {@each videos as items}
  357. {@each items as item, index}
  358. {@if item.type == 'key'}
  359. <li>
  360. <a href="http://so.yinyuetai.com/mv?keyword={{item.word|encodeURIComponent}}" class="h30 t9 l26"
  361. target="_blank"><strong>{{{item.word}}}</strong></a>
  362. </li>
  363. {@if index == items.length - 1}
  364.  
  365. <li class="dotted"></li>
  366. {@/if}
  367. {@/if}
  368.  
  369. {@/each}
  370. {@/each}
  371.  
  372. {@each videos as items}
  373. {@each items as item, index}
  374. {@if item.type == 'video'}
  375. {@if index == 0}
  376. <li>
  377. <a href="http://so.yinyuetai.com/mv?keyword={{keyword|encodeURIComponent}}" class="h30 t9 l26 head video"
  378. target="_blank">鎼滅储<strong>{{keyword}}</strong>鐨勭浉鍏宠棰?</a>
  379. </li>
  380. {@/if}
  381. <li>
  382. <a href="http://v.yinyuetai.com/video/{{item.id}}" target="_blank" class="h30 t25 l26">{{{item.word}}}</a>
  383. </li>
  384. {@if index == items.length - 1}
  385. <li class="dotted"></li>
  386. {@/if}
  387. {@/if}
  388.  
  389. {@/each}
  390. {@/each}
  391. {@each videos as items}
  392. {@each items as item, index}
  393.  
  394. {@if item.type == 'artist'}
  395. {@if index == 0}
  396. <li>
  397. <a href="http://so.yinyuetai.com/artist?keyword={{keyword|encodeURIComponent}}" class="h30 t9 l26 head fans"
  398. target="_blank">鎼滅储<strong>{{keyword}}</strong>鐨勭浉鍏抽キ鍥?</a>
  399. </li>
  400. {@/if}
  401. <li>
  402. <a href="http://www.yinyuetai.com/fanclub/{{item.id}}" class="h57" target="_blank">
  403. <img class="avatar" src={{item.headImg}}>
  404. <span class="title">{{{item.word}}}</span>
  405. </a>
  406. </li>
  407. {@if index == items.length - 1}
  408. <li class="dotted"></li>
  409. {@/if}
  410. {@/if}
  411. {@if item.type == 'person'}
  412. {@if index == 0}
  413. <li>
  414. <a href="http://i.yinyuetai.com/s/u?keyword={{keyword|encodeURIComponent}}" class="h30 t9 l26 head firend"
  415. target="_blank">鎼滅储<strong>{{keyword}}</strong>鐨勭浉鍏虫偊鍙?</a>
  416. </li>
  417. {@/if}
  418. <li>
  419. <a href="http://i.yinyuetai.com/{{item.id}}/friend" class="h57" target="_blank">
  420. <img class="avatar" src={{item.headImg}}>
  421. <span class="title">{{{item.word}}}</span>
  422. </a>
  423. </li>
  424. {@if index == items.length - 1}
  425. <li class="dotted"></li>
  426. {@/if}
  427. {@/if}
  428. {@/each}
  429. {@/each}
  430. <li>
  431. <a href="http://so.yinyuetai.com/article?keyword={{keyword|encodeURIComponent}}"
  432. class="h30 t9 l26 head other last" target="_blank">鎼滅储<strong>{{keyword}}</strong>鐨勫叾浠栦俊鎭?</a>
  433. </li>
  434.  
  435. </script>
  436. <script type="text/tmp" id="autocompletenormalTpl">
  437.  
  438. <li class="h39"></li>
  439.  
  440. <li>
  441. <a href="http://v.yinyuetai.com/video/2457684" target="_blank"
  442. class='h30 t25 l26 '>VIXX鎴愬憳璐ㄧ枒"榛戝箷" 澶氭缃㈠綍</a>
  443. </li>
  444.  
  445. <li>
  446. <a href="http://v.yinyuetai.com/video/2439306" target="_blank"
  447. class='h30 t25 l26 '>鐢靛奖銆婇鍚圭伅涔嬪榫欒瘈銆嬩富棰樻洸</a>
  448. </li>
  449.  
  450. <li>
  451. <a href="http://v.yinyuetai.com/video/2452608" target="_blank"
  452. class='h30 t25 l26 '>UNIQ澶ц亰鎴愬勾璇濋 鎰忓BOBO</a>
  453. </li>
  454.  
  455. <li>
  456. <a href="http://v.yinyuetai.com/video/2416868" target="_blank"
  457. class='h30 t25 l26 '>涓囦竾娌℃兂鍒帮細澶х帇鍙垜鏉ュ贰灞?</a>
  458. </li>
  459.  
  460. <li>
  461. <a href="http://v.yinyuetai.com/video/2449042" target="_blank"
  462. class='h30 t25 l26 '>鏉庢椽鍩轰笓璁胯牏钀屾寫鎴樼數鍙癉J</a>
  463. </li>
  464.  
  465. <li>
  466. <a href="http://v.yinyuetai.com/video/2446190" target="_blank"
  467. class='h30 t25 l26 '>灏规鎸戞垬娴佽璇?"鍢垮樋鍢?"琚帺鍧?</a>
  468. </li>
  469.  
  470. <li>
  471. <a href="http://v.yinyuetai.com/video/2442052" target="_blank"
  472. class='h30 t25 l26 '>鏉庢槗宄扮涓嬭亰澶╀細鐢ㄨ嚜宸辩殑琛ㄦ儏鍖咃紒</a>
  473. </li>
  474.  
  475. <li>
  476. <a href="http://v.yinyuetai.com/video/2440118" target="_blank"
  477. class='h30 t25 l26 '>鏋椾繆鏉般?婁笉涓鸿皝鑰屼綔鐨勬瓕銆?</a>
  478. </li>
  479.  
  480. <li>
  481. <a href="http://v.yinyuetai.com/video/2440146" target="_blank"
  482. class='h30 t25 l26 '>SpeXial鐜╂父鎴? 鑺傛搷鎺夊厜鍏?</a>
  483. </li>
  484.  
  485. <li>
  486. <a href="http://v.yinyuetai.com/video/2439059 " target="_blank"
  487. class='h30 t25 l26 last'>瀹炲姏灏忛粍鍥nfinite鐨勮瘹瀹為棶绛?</a>
  488. </li>
  489.  
  490. </script>
  491. <script type="text/javascript">
  492. if (!Y.isLoadByPartner) {
  493. require(['modules/yinyuetai/topbar']);
  494. }
  495.  
  496. </script>
  497.  
  498. </div>
  499.  
  500. <!-- End topbar -->
  501. <div class="index_auto">
  502. <!-- Start 鐒︾偣鍥? -->
  503. <div class="index_focus">
  504. <a href="javascript:;" class="index_focus_pre J_toggle" data-direction="prev" title="涓婁竴寮?">涓婁竴寮?</a>
  505. <a href="javascript:;" class="index_focus_next J_toggle" data-direction="next" title="涓嬩竴寮?">涓嬩竴寮?</a>
  506. <ul>
  507.  
  508. <li>
  509. <a href="http://v.yinyuetai.com/video/2462853?f=SY-JDT-MV-1" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘0', '0'])">
  510.  
  511. <div class="index_focus_info J_focus_info"
  512. style="left: 62%; width: 600px;
  513. ">
  514. <h3>钀ф暚鑵俱?婅鎵嬫梺瑙傘??</h3>
  515.  
  516. <p class="text">钀ф暚鑵炬柊涓撹緫绗簩娉富鎵撱?婅鎵嬫梺瑙傘?婱V鍏紑锛佽繖棣栨瓕鐢遍粍鍥戒鸡鑰佸笀浣滄洸銆佸璋︿綔璇嶃?侀綈绉﹀師鍞憋紒姝ゆ閲嶆柊缈诲敱鏀圭紪锛屽姞鍏ヤ簡寮︿箰缁靛瘑鐨勭紪鏇诧紝鍏呮弧浜嗏?滆惂姘忛鏍尖?濓紝娓╂煍娣辨儏鐨勫棑闊冲湪鍚屾褰曢煶鐨勭幆澧冧笅one take 瀹炲湪璁╀汉璧炲徆锛?</p>
  517. </div>
  518.  
  519. <img class="pic" src="http://img0.yytcdn.com/others/admin/151230/0/-M-f05705dd8168fccae7b04b1a188f6ed0_0x0.jpg" width="1600" height="600" alt=""/>
  520. </a>
  521. </li>
  522.  
  523. <li>
  524. <a href="http://www.yinyuetai.com/apps/fanapp/bigbang?f=SY-JDT-YDM-2" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘1', '1'])">
  525.  
  526. <img class="pic" src="http://img4.yytcdn.com/others/admin/151230/0/-M-43f42687966d8f7ffb51091a4a40c53d_0x0.png" width="1600" height="600" alt=""/>
  527. </a>
  528. </li>
  529.  
  530. <li>
  531. <a href="http://v.yinyuetai.com/video/2462759?f=SY-JDT-MV-3" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘2', '2'])">
  532.  
  533. <img class="pic" src="http://img0.yytcdn.com/others/admin/151230/0/-M-04651eb164f9ae9f6d86f3baa8d9be7d_0x0.jpg" width="1600" height="600" alt=""/>
  534. </a>
  535. </li>
  536.  
  537. <li>
  538. <a href="http://feature.yinyuetai.com/inventory2?id=65&f=SY-JDT-YDM-4" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘3', '3'])">
  539.  
  540. <div class="index_focus_info J_focus_info"
  541. style="
  542. ">
  543. <h3>鐧惧悎鎯呯紭鈥斾笘鐣屼笂鐨勫彟涓?涓垜</h3>
  544.  
  545. <p class="text">濂冲瓙鐨勬儏璋婁翰瀵嗘椂缁嗚吇鑰屽井濡?,涓?涓編甯呮敾姘斿崄瓒?,瀹犳汉鎾╁鎶?鑳界偣婊″垎,涓?涓蒋钀屽彈姘旀弧婊?,鎾掑▏鍗栬悓鍔熷姏娣卞帤,榛樺鏈夌埍鐨勪簰鍔ㄦ暎鍙戠潃鎭嬬埍鐨勭敎鑵绘皵鎭?(澶ч浘),濂逛箣浜庡ス,鏄笘鐣屼笂鍙︿竴涓嚜宸辩殑瀛樺湪,鐪嬬潃濂崇闂寸櫨鍚堝ぇ鎴?,鐖卞ス浠殑浣犲噯澶囧ソ琚幇寮簡涔??</p>
  546. </div>
  547.  
  548. <img class="pic" src="http://img3.yytcdn.com/others/admin/151229/0/-M-2a343c3f9ff1a98389b92d6ae95e9118_0x0.jpg" width="1600" height="600" alt=""/>
  549. </a>
  550. </li>
  551.  
  552. <li>
  553. <a href="http://v.yinyuetai.com/video/2462011?f=SY-JDT-MV-5" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘4', '4'])">
  554.  
  555. <div class="index_focus_info J_focus_info"
  556. style="
  557. left: 32%;">
  558. <h3>鏋椾繆鏉般?婂叧閿瘝銆?</h3>
  559.  
  560. <p class="text">鏋椾繆鏉伴寮犲疄楠屼笓杈戙?婂拰鑷繁瀵硅瘽銆嬬涓夋尝涓绘墦銆婂叧閿瘝銆婱V棣栨挱锛佹瓕鏇叉灄淇婃澃璋辨洸锛屾灄鎬″嚖濉瘝銆侻V鐢遍粍涓钩瀵兼紨鎿嶅垁锛岄檲濡嶅笇鐗瑰埆婕斿嚭銆傛灄淇婃澃鐨勬洸灏嗚瘝浣滅殑浼樼編璋变笂娴撴祿涓浗椋庯紝娲楁钉瀵圭埍鎯呯殑杩锋儤锛屽甫缁欎汉骞哥鐨勫姏閲忋??</p>
  561. </div>
  562.  
  563. <img class="pic" src="http://img4.yytcdn.com/others/admin/151229/0/-M-cbc2fb9e36fdc83d49db2fbbdfb16939_0x0.jpg" width="1600" height="600" alt=""/>
  564. </a>
  565. </li>
  566.  
  567. <li>
  568. <a href="http://feature.yinyuetai.com/tianping?f=SY-JDT-YDM-6" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘5', '5'])">
  569.  
  570. <img class="pic" src="http://img1.yytcdn.com/others/admin/151225/0/-M-1f8e9a491d78ec6ae0c232b8191c6818_0x0.jpg" width="1600" height="600" alt=""/>
  571. </a>
  572. </li>
  573.  
  574. <li>
  575. <a href="http://v.yinyuetai.com/video/2459321?f=SY-JDT-MV-7" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘6', '6'])">
  576.  
  577. <div class="index_focus_info J_focus_info"
  578. style="
  579. ">
  580. <h3>EP120 鍋跺儚鍖呰⒈绮夌鏈虹鍥涘脊鈥斺?擲peXial鐗硅緫</h3>
  581.  
  582. <p class="text">鍋跺儚鍖呰⒈绮夌鏈虹鍥涘脊鏉ュ柦锛佸皬鎳靛摂浠繖娆en鐨勭帺寰堝ぇ鍝︼紒蹇偣鐪嬭妭鐩惂锛佽妭鐩腑鍑虹幇鐨勫悕鐢婚兘鍙互閫佺粰浣犱滑鍠忥紝鍓嶆彁鏄挱鏀鹃噺杩囦簡100涓囷紝鍏蜂綋鍏虫敞@闊虫偊V姒滃畼鍗?</p>
  583. </div>
  584.  
  585. <img class="pic" src="http://img2.yytcdn.com/others/admin/151226/0/-M-9682e66d564978eb8fe864e4c43c64c0_0x0.jpg" width="1600" height="600" alt=""/>
  586. </a>
  587. </li>
  588.  
  589. <li>
  590. <a href="http://t.collect.yinyuetai.com/c?a=104086" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘7', '7'])">
  591.  
  592. <div class="index_focus_info J_focus_info"
  593. style="
  594. ">
  595. <h3>San E 銆奃o It For Fun銆?</h3>
  596.  
  597. <p class="text"></p>
  598. </div>
  599.  
  600. <img class="pic" src="http://img2.yytcdn.com/others/admin/151230/0/1451457790619_1600x600.jpg" width="1600" height="600" alt=""/>
  601. </a>
  602. </li>
  603.  
  604. <li>
  605. <a href="http://shop.yinyuetai.com/theme?shoujiao&f=SY-JDT-YDM-8" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘8', '8'])">
  606.  
  607. <img class="pic" src="http://img4.yytcdn.com/others/admin/151225/0/-M-df24a23e71ef8da273a2d93371f4ad0c_0x0.jpg" width="1600" height="600" alt=""/>
  608. </a>
  609. </li>
  610.  
  611. <li>
  612. <a href="http://v.yinyuetai.com/video/2458554?f=SY-JDT-MV-9" class="pic" target="_blank" onclick="_hmt.push(['_trackEvent', '棣栭〉澶у浘9', '9'])">
  613.  
  614. <img class="pic" src="http://img1.yytcdn.com/others/admin/151225/0/-M-d172cc01f922c203cf183409cb280198_0x0.jpg" width="1600" height="600" alt=""/>
  615. </a>
  616. </li>
  617.  
  618. </ul>
  619. <div class="slide_nav J_nav">
  620. </div>
  621. </div>
  622. <!-- End 鐒︾偣鍥? -->
  623.  
  624. <script type="text/javascript">
  625. if (!Y.isLoadByPartner) {
  626. $.getJSON('/api/directional/get-directional-result?json=true', function(result) {
  627. if (result.directionalResult) {
  628. $.getJSON('/partner/get-partner-code?json=true&placeIds=index_push', function(result) {
  629. if (result.index_push) {
  630. var object = $(".index_focus").find("ul li").eq(1);
  631. var index_bottom = $.parseJSON(result.index_push.replace(/'/ig, '"'));
  632. object.find('a').attr('href', index_bottom.url);
  633. object.find('h3').text(index_bottom.title);
  634. object.find('.text').text(index_bottom.content);
  635. object.find('img').attr('src', index_bottom.img);
  636. var imp = index_bottom.imp + '&t=' + new Date();
  637. $('<img src="' + imp + '" style="display:none;" />').appendTo(document.body);
  638. }
  639.  
  640. });
  641. }
  642. });
  643. }
  644. </script>
  645.  
  646. <!-- Start 鍐呭 -->
  647. <div class="index_content">
  648. <!-- Start 骞垮憡浣? -->
  649. <div class="focus_bottom_banner" style="overflow: hidden; text-align: center;">
  650. <div class="banner_container" style="margin: 10px auto; display: block;">
  651.  
  652. </div>
  653. </div>
  654. <!-- End 骞垮憡浣? -->
  655.  
  656. <!-- Start MV棣栨挱 -->
  657. <div class="index_box clearfix" id="shoubo">
  658. <div class="index_title">
  659. <h3 class="fl ico_index_premiere01">MV棣栨挱1</h3>
  660.  
  661. <div class="fr group_tab">
  662. <a href="javascript:;" class="J_area cur" data-area="all" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鍏ㄩ儴', '鍏ㄩ儴']);">鍏ㄩ儴</a>
  663. <span class="ico_line"></span>
  664. <a href="javascript:;" class="J_area" data-area="ml" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鍐呭湴', '鍐呭湴']);">鍐呭湴</a>
  665. <span class="ico_line"></span>
  666. <a href="javascript:;" class="J_area" data-area="ht" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*娓彴', '娓彴']);">娓彴</a>
  667. <span class="ico_line"></span>
  668. <a href="javascript:;" class="J_area" data-area="us" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*娆х編', '娆х編']);">娆х編</a>
  669. <span class="ico_line"></span>
  670. <a href="javascript:;" class="J_area" data-area="kr" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*闊╁浗', '闊╁浗']);">闊╁浗</a>
  671. <span class="ico_line"></span>
  672. <a href="javascript:;" class="J_area" data-area="jp" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鏃ユ湰', '鏃ユ湰']);">鏃ユ湰</a>
  673. </div>
  674.  
  675. </div>
  676. <a href="javascript:;" class="group_pre1 J_prev" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*涓婁竴椤?', '涓婁竴椤?'])"></a>
  677. <a href="javascript:;" class="group_next1 J_next" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*涓嬩竴椤?', '涓嬩竴椤?'])"></a>
  678. <span class="ico_loading"></span>
  679.  
  680. <div class="index_list_auto">
  681. <ul class="index_list_w">
  682. <li class="index_list">
  683.  
  684. <div class="J_add_convenient_container mv_pic mr_r22 shadow">
  685.  
  686. <a href="http://v.yinyuetai.com/video/2462863?f=SY-MKDT-MVSB-1"
  687. class="pic play_pic1" target="_blank" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*澶у浘*宸?', '澶у浘', '宸?'])">
  688. <img src="http://img4.yytcdn.com/others/admin/151230/0/-M-475c1462bd103d9f79050630d8752db5_0x0.jpg" width="468" height="273" alt="涓嶈鍐嶈"/>
  689.  
  690. <div class="play_name" style="display: block;">
  691. <h4 class="text fb14 mr_t75">涓嶈鍐嶈</h4>
  692.  
  693. <p class="text c_cf9">
  694.  
  695. 濂藉濡逛箰闃?
  696.  
  697. </p>
  698.  
  699. </div>
  700. <span class="ico_play">鎾斁</span>
  701. </a>
  702.  
  703. </div>
  704.  
  705. </li>
  706. </ul>
  707. <div class="clearfloat"></div>
  708. </div>
  709.  
  710. </div>
  711.  
  712. <!-- End MV棣栨挱 -->
  713.  
  714. <!-- Start 姝f祦琛? -->
  715. <div class="index_box clearfix" id="zhengliuxing">
  716. <div class="index_title">
  717. <h3 class="fl ico_index_popular">姝f祦琛?</h3>
  718.  
  719. <div class="fr group_tab">
  720. <a href="javascript:;" class="J_area cur" data-area="all" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鍏ㄩ儴', '鍏ㄩ儴']);">鍏ㄩ儴</a>
  721. <span class="ico_line"></span>
  722. <a href="javascript:;" class="J_area" data-area="ml" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鍐呭湴', '鍐呭湴']);">鍐呭湴</a>
  723. <span class="ico_line"></span>
  724. <a href="javascript:;" class="J_area" data-area="ht" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*娓彴', '娓彴']);">娓彴</a>
  725. <span class="ico_line"></span>
  726. <a href="javascript:;" class="J_area" data-area="us" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*娆х編', '娆х編']);">娆х編</a>
  727. <span class="ico_line"></span>
  728. <a href="javascript:;" class="J_area" data-area="kr" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*闊╁浗', '闊╁浗']);">闊╁浗</a>
  729. <span class="ico_line"></span>
  730. <a href="javascript:;" class="J_area" data-area="jp" onclick="_hmt.push(['_trackEvent', 'MV棣栨挱*鏃ユ湰', '鏃ユ湰']);">鏃ユ湰</a>
  731. </div>
  732.  
  733. </div>
  734. <a href="javascript:;" class="group_pre1 J_prev" onclick="_hmt.push(['_trackEvent', '姝e湪娴佽*涓婁竴椤?', '涓婁竴椤?'])"></a>
  735. <a href="javascript:;" class="group_next1 J_next" onclick="_hmt.push(['_trackEvent', '姝e湪娴佽*涓嬩竴椤?', '涓嬩竴椤?'])"></a>
  736. <span class="ico_loading"></span>
  737.  
  738. <div class="index_list_auto">
  739. <ul class="index_list_w">
  740. <li class="index_list">
  741. <div class="mv_pic shadow index_w716">
  742.  
  743. <div class="J_add_convenient_container fl">
  744.  
  745. <a href="http://v.yinyuetai.com/video/2461180?f=SY-MKDT-ZZLX-1"
  746. class="fl pic play_pic1" target="_blank" onclick="_hmt.push(['_trackEvent', '姝e湪娴佽*澶у浘*宸?', '澶у浘', '宸?'])">
  747. <img src="http://img4.yytcdn.com/others/admin/151228/0/-M-5adfce3aacfa4261e445a913bf420295_0x0.jpg" width="468" height="273" alt=""/>
  748. <span class="ico_play">鎾斁</span>
  749. </a>
  750.  
  751. </div>
  752.  
  753. <div class="fl index_info">
  754. <h4 class="title">
  755. <a href="http://v.yinyuetai.com/video/2461180?f=SY-MKDT-ZZLX-1"
  756. target="_blank">
  757. 鐖遍?犻楦? 绁炵鐣绡?
  758. </a>
  759. </h4>
  760.  
  761. <p class="name">
  762.  
  763. <a href="http://www.yinyuetai.com/fanclub/171" class="special"
  764. target="_blank">閮噰娲?</a>
  765.  
  766. </p>
  767.  
  768. <p class="info">閮噰娲佸叏鏂版蹇典笓杈戙?婄埍閫犻楦°?婱V绁炵鐣绡囧叕寮?锛佹娆$壒鍒個鏉ラ噸閲忕骇璧勬繁鍓т綔瀹堕噾澹澃涓庨噰娲佸叡鍚屾紨缁庡繕骞翠箣鎯咃紝鏃剁┖杞崲鍒颁簡70骞翠唬鐨勫彴婀撅紝鑰屾垙涓?佸ご鐨勬渶鍚庝竴鍙ュ拰鏈?鍚庝竴鏀垶涔熻鎵?鏈変汉鍔ㄥ锛岄儹閲囨磥绮炬箾鐨勬紨鎶?澶х垎鍙戯紝闀胯揪鍗佷簲鍒嗛挓鐨勭暘澶栫瘒璁╀綘涓?娆$湅杩囩樉</p>
  769. </div>
  770. </div>
  771. </li>
  772. </ul>
  773. </div>
  774. </div>
  775. <!-- End 姝f祦琛? -->
  776.  
  777. <!-- Start 闊虫偊V姒? -->
  778. <div class="index_box index_vchart clearfix" id="vchart">
  779. <div class="index_title">
  780. <h3 class="fl ico_index_vchart">闊虫偊V姒?</h3>
  781. <a href="http://vchart.yinyuetai.com/vchart/v" target="_blank" class="date">52</a>
  782. <a href="http://vchart.yinyuetai.com/vchart/v" target="-_blank" class="fl time">2015骞? 绗?52鏈?
  783. 锛?12.21~12.27锛?</a>
  784.  
  785. <div class="fr group_tab">
  786. <a href="javascript:;" class="J_area cur" data-area="ml">鍐呭湴</a>
  787. <span class="ico_line"></span>
  788. <a href="javascript:;" class="J_area" data-area="ht">娓彴</a>
  789. <span class="ico_line"></span>
  790. <a href="javascript:;" class="J_area" data-area="us">娆х編</a>
  791. <span class="ico_line"></span>
  792. <a href="javascript:;" class="J_area" data-area="kr">闊╁浗</a>
  793. <span class="ico_line"></span>
  794. <a href="javascript:;" class="J_area" data-area="jp">鏃ユ湰</a>
  795. </div>
  796. </div>
  797. <a href="javascript:;" class="group_pre1 J_prev" onclick="_hmt.push(['_trackEvent','闊虫偊V姒?*涓婁竴椤?','涓婁竴椤?'])"></a>
  798. <a href="javascript:;" class="group_next1 J_next" onclick="_hmt.push(['_trackEvent','闊虫偊V姒?*涓嬩竴椤?','涓嬩竴椤?'])"></a>
  799. <span class="ico_loading"></span>
  800.  
  801. <div class="index_list_auto">
  802. <ul class="index_list_w">
  803. <li class="index_list">
  804. <div class="mv_pic shadow index_w716">
  805.  
  806. <div class="J_add_convenient_container fl">
  807.  
  808. <a href="http://v.yinyuetai.com/video/2457525?f=SY-MKDT-YYVB-1"
  809. class="fl pic play_pic1" title="2015骞撮煶鎮姒滅51鏈? - 鍐呭湴绡?" target="_blank" onclick="_hmt.push(['_trackEvent','闊虫偊V姒?*澶у浘ml*宸?','澶у浘ml','宸?'])">
  810. <img src="http://img4.yytcdn.com/others/admin/151224/0/-M-de88bc3bb8fb31c7c220b0fb3d45da62_0x0.jpg" width="468" height="273" alt=""/>
  811. <span class="ico_play">鎾斁</span>
  812. </a>
  813.  
  814. </div>
  815.  
  816. <div class="fl index_info">
  817. <h4 class="title">
  818. <a href="http://v.yinyuetai.com/video/2457525?f=SY-MKDT-YYVB-1"
  819. title="2015骞撮煶鎮姒滅51鏈? - 鍐呭湴绡?" target="_blank">2015骞撮煶鎮姒滅51鏈? - 鍐呭湴绡?</a>
  820. </h4>
  821.  
  822. <p class="info">鏈懆鍐呭湴V姒滐紝瀹嬭寽棣栨敮鍥借鍗曟洸锛屽彉韬揩閫掑コ绁炵尞涓婃殩蹇冩瓕鏇诧紱鍚翠害鍑℃敼缂栫粡鍏革紝楗版紨鍙嶆淳鎺ュ彈鎸戞垬锛涙潕鏄撳嘲鐗垫墜鍏佸効锛屽綋鐢风閬囧埌濂崇浼氭摝鍑烘?庢牱鐨勭伀鑺便?傛湰鍛ㄥ唴鍦癡姒滐紝鐢风濂崇澶ц仛浼氾紝閭g敾闈㈠お缇庯紝浣犳?庝箞鑸嶅緱涓嶇湅锛伮?</p>
  823. </div>
  824. </div>
  825.  
  826. </li>
  827. </ul>
  828. </div>
  829. </div>
  830. <!-- End 闊虫偊V姒? -->
  831.  
  832. <script type="text/tpl" id="video_list_tpl">
  833.  
  834. {@each videos as video,index}
  835. {@if index%2==0}
  836. <div class="mv_1x2">
  837. {@/if}
  838. {@if video.videoId >= 0}
  839. <div class="{@if video.videoId>0}J_add_convenient_container {@/if} mv_pic shadow{@if video.videoId>0} J_mv{@/if}" data-video-id="{{video.videoId}}">
  840. <a href="{@if video.url}{{video.url}}{@else}http://v.yinyuetai.com/video/{{video.videoId}}?f={{video.from}}{@/if}" class="pic play_pic2"
  841. target="_blank" onclick="_hmt.push(['_trackEvent', '{{_hmt.channel}}*灏忓浘{{_hmt.areas}}*{{+_hmt.start + +index}}', '{{_hmt.channel}}', '{{+_hmt.start + +index}}'])">
  842. <img src="{{video.image}}" width="220" height="124" alt="灏忓浘"/>
  843.  
  844. <div class="play_name">
  845. <h4 class="text fb12 {@if video.artists.length>0}mr_t80{@else}mr_t100{@/if}">{{video.title}}</h4>
  846.  
  847. {@if video.artists&&video.artists.length > 0}
  848. <p class="text c_cf9">
  849. {@each video.artists as artist,index}
  850. {@if index>0} & {@/if}
  851. {{artist.artistName}}
  852. {@/each}
  853. </p>
  854. {@/if}
  855. </div>
  856. {@if video.videoId>0}<span class="ico_play">鎾斁</span>{@/if}
  857. {@if video.rank}
  858. <span class="play_vchart_num"><em>{{video.rank}}</em><i
  859. class="cor{@if video.rank<4}{{video.rank}}{@/if}"></i></span>
  860. {@/if}
  861. </a>
  862. {@if video.partner}<span class="clear_special"></span>{@/if}
  863. </div>
  864. {@else if video.type=="trends"}
  865. <div class="mv_pic shadow">
  866. <a href="http://vchart.yinyuetai.com/vchart/trends?f={{video.from}}}" class="index_vchart_dynamic" target="_blank">
  867. 鏌ョ湅鎵撴鍔ㄦ??<span class="ico20_vchart_dynamic"></span>
  868. </a>
  869. </div>
  870. {@else if video.type=="v"}
  871. <div class="mv_pic shadow">
  872. <a href="http://vchart.yinyuetai.com/vchart/v?f={{video.from}}}" class="index_vchart_dynamic" target="_blank">
  873. 鏌ョ湅寰?鏈熸鍗?<span class="ico20_vchart_time"></span>
  874. </a>
  875. </div>
  876. {@/if}
  877. {@if index%2==1||index==videos.length-1}
  878. </div>
  879. {@/if}
  880. {@/each}
  881. </script>
  882. <script type="text/tpl" id="video_info_tpl">
  883. {@if customTitle}<p class="title">
  884. <span class="fl ico20_comma_l"></span>{{customTitle}}<i class="ico20_comma_r"></i></p>
  885. {@/if}
  886.  
  887. <p class="num">
  888. <span class="ico20_play">{{totalViews}}</span>
  889. <span class="ico20_comment">{{totalComments}}</span>
  890. {@if rank!=0}
  891. <a href="http://vchart.yinyuetai.com/vchart/trends" class="ico20_vchart" target="_blank">{{rank}}<i
  892. class="{@if up}ico20_rise{@else}ico20_decline{@/if}"></i></a>
  893. {@/if}
  894. </p>
  895.  
  896. <p class="info">{{content}}</p>
  897. </script>
  898. <script type="text/tpl" id="vchart_rec_tpl">
  899.  
  900. <div class="mv_pic shadow index_w716">
  901. {@if videoId}
  902. <div class="J_add_convenient_container fl">
  903. {@/if}
  904. <a href="{@if videoId}http://v.yinyuetai.com/video/{{videoId}}?f=SY-MKDT-YYVB-1{@else}{@/if}" class="fl pic play_pic1" title="{{title}}"
  905. target="_blank">
  906. <div class="pic">
  907. <img src="{{image}}" width="468" height="273" alt="" onclick="_hmt.push(['_trackEvent','闊虫偊V姒?*澶у浘{{area}}*宸?','澶у浘{{area}}','宸?'])"/>
  908. </div>
  909. </a>
  910. {@if videoId}
  911. <span class="J_add_convenient" title="鍔犲叆渚挎嵎鎮﹀崟" data-video-id="{{videoId}}"></span>
  912. </div>
  913. {@/if}
  914.  
  915. <div class="fl index_info">
  916. <h4 class="title"><a href="{@if videoId}http://v.yinyuetai.com/video/{{videoId}}?f=SY-MKDT-YYVB-1{@else}{@/if}" target="_blank">{{title}}</a>
  917. </h4>
  918.  
  919. <p class="info">{{content}}</p>
  920. </div>
  921. </div>
  922. </script>
  923. <script type="text/javascript">
  924. require(["app/main/index"], function(index) {
  925. var Tray = index.Tray, store = index.store;
  926.  
  927. new Tray({
  928. el : $('#shoubo'),
  929. tpl : $('#video_list_tpl').html(),
  930. data : [{"artists":[{"artistName":"瀹佹瀹?","id":31414}],"from":"SY-MVSB-QB-1","image":"http://img1.yytcdn.com/video/mv/151230/2462374/-M-5b0d2ab781ea5f17ffb278b13fe8d2a2_240x135.jpg?t=20151230093237","partner":false,"rank":0,"title":"Mango 瀹樻柟鐗?","videoId":2462374},{"artists":[{"artistName":"鏋椾繆鏉?","id":22}],"from":"SY-MVSB-QB-2","image":"http://img2.yytcdn.com/video/mv/151229/2462011/-M-3ed5156cedf3099946b6df099d4794bd_240x135.jpg","partner":false,"rank":0,"title":"鍏抽敭璇? 瀹樻柟鐗?","videoId":2462011},{"artists":[{"artistName":"Wiz Khalifa","id":5298}],"from":"SY-MVSB-QB-3","image":"http://img3.yytcdn.com/video/mv/151229/2461415/-M-ca61375fcc9102ca81fa57572b84084c_240x135.jpg?t=20151229095251","partner":false,"rank":0,"title":"King of Everything","videoId":2461415},{"artists":[{"artistName":"Cal Scruby","id":31214},{"artistName":"Chris Brown","id":115}],"from":"SY-MVSB-QB-4","image":"http://img2.yytcdn.com/video/mv/151229/2461393/-M-b712ea62950e5f75300b6cf120cc99f3_240x135.jpg?t=20151229013836","partner":false,"rank":0,"title":"Ain't Shit Change","videoId":2461393},{"artists":[{"artistName":"宸︾珛","id":30212}],"from":"SY-MVSB-QB-5","image":"http://img2.yytcdn.com/video/mv/151229/2461576/-M-28ce82a529ef67b2de4c56b3851e3bac_240x135.jpg?t=20151229110714","partner":false,"rank":0,"title":"鍋氳嚜宸辩殑姒滄牱 瀹樻柟鐗?","videoId":2461576},{"artists":[{"artistName":"鏉洊","id":37530}],"from":"SY-MVSB-QB-6","image":"http://img0.yytcdn.com/video/mv/151229/2461419/-M-10ff7c5b95f1d495d6faa5be0aa06b39_240x135.jpg?t=20151229095954","partner":false,"rank":0,"title":"娴风劧娴风劧 鐢靛奖<瀵婚緳璇?>鎻掓洸鐢靛奖鐗?","videoId":2461419},{"artists":[{"artistName":"鏉ㄥ煿瀹?","id":283}],"from":"SY-MVSB-QB-7","image":"http://img0.yytcdn.com/video/mv/151228/2461004/-M-5ffe211104c51fd8931a7dca1fb9f08d_240x135.jpg?t=20151228175818","partner":false,"rank":0,"title":"蹇冧笉璺充簡 瀹樻柟鐗?","videoId":2461004},{"artists":[{"artistName":"Nicole Scherzinger","id":1833},{"artistName":"Paul McCartney","id":1437},{"artistName":"Leona Lewis","id":447},{"artistName":"Colbie Caillat","id":655},{"artistName":"Natasha Bedingfield","id":1201}],"from":"SY-MVSB-QB-8","image":"http://img3.yytcdn.com/video/mv/151228/2457078/-M-1e288a98a5d958ad9b21a7bc66bbc80d_240x135.jpg?t=20151224090247","partner":false,"rank":0,"title":"Love Song To The Earth","videoId":2457078},{"artists":[{"artistName":"Melody Day","id":33510},{"artistName":"Ravi(VIXX)","id":35977}],"from":"SY-MVSB-QB-9","image":"http://img4.yytcdn.com/video/mv/151228/2460758/-M-c557f85747c06c84feb3aaf79f146045_240x135.jpg?t=20151228112218","partner":false,"rank":0,"title":"濡傛灉涓嬮洦(Feat. Ravi of VIXX) 瀹屾暣鐗?","videoId":2460758},{"artists":[{"artistName":"闊╂捣(Phantom)","id":39589}],"from":"SY-MVSB-QB-10","image":"http://img1.yytcdn.com/video/mv/151228/2460753/-M-769728c2c46c460664d9f232a575aeb2_240x135.jpg?t=20151228111801","partner":false,"rank":0,"title":"娌℃湁閭f牱鐨勪汉(No One Like Him) 瀹屾暣鐗?","videoId":2460753},{"artists":[{"artistName":"绱犵弽(Girl's Day)","id":22660}],"from":"SY-MVSB-QB-11","image":"http://img3.yytcdn.com/video/mv/151225/2458676/-M-1a4e19d71378363ae1840ee4156c9c0d_240x135.jpg?t=20151225231052","partner":false,"rank":0,"title":"姣忓ぉ鍜屼綘 <璇峰洖绛?1988>OST Part.8","videoId":2458676},{"artists":[{"artistName":"钄″仴闆?","id":75}],"from":"SY-MVSB-QB-12","image":"http://img0.yytcdn.com/video/mv/151225/2458261/-M-e077a7b85659dbb1488ffb0fda2b5228_240x135.jpg?t=20151225140832","partner":false,"rank":0,"title":"娲荤潃鏄渶濂界殑姝讳骸 瀹樻柟鐗?","videoId":2458261},{"artists":[{"artistName":"鍚翠繆浣?","id":10261}],"from":"SY-MVSB-QB-13","image":"http://img4.yytcdn.com/video/mv/151225/2458040/-M-65a98b3efa0993dccf30b0e97843d5e7_240x135.jpg","partner":false,"rank":0,"title":"you are so beautiful 瀹樻柟鐗?","videoId":2458040},{"artists":[{"artistName":"闄堣但","id":27661},{"artistName":"濮氭櫒","id":14497},{"artistName":"绐﹂獊","id":14998}],"from":"SY-MVSB-QB-14","image":"http://img3.yytcdn.com/video/mv/151225/2457072/-M-85654be4b686740b3cb6fbe347567589_240x135.jpg?t=20151224085130","partner":false,"rank":0,"title":"涓?灏佸涔? 缇ゆ槦鐗? 鐢靛奖<涓?鍒囬兘濂?>鎺ㄥ箍鏇?","videoId":2457072},{"artists":[{"artistName":"涓佸厠妫?","id":31304}],"from":"SY-MVSB-QB-15","image":"http://img2.yytcdn.com/video/mv/151225/2458078/-M-fc5c4d77634a5776c5b9a3f39e7f231c_240x135.jpg?t=20151225104021","partner":false,"rank":0,"title":"鍌荤摐鐨勪俊浠? 瀹樻柟鐗?","videoId":2458078},{"artists":[{"artistName":"鍗庤缇ゆ槦","id":4538}],"from":"SY-MVSB-QB-16","image":"http://img4.yytcdn.com/video/mv/151230/2462412/-M-3ed1476ac9a36d7fc83ee1bef7a9768c_240x135.jpg?t=20151230101959","partner":false,"rank":0,"title":"鍦扮嫳涔嬫瓕 鐢靛奖<鏋滃疂鐗规敾>瀹d紶鏇?","videoId":2462412},{"artists":[{"artistName":"鑷充笂鍔卞悎","id":158}],"from":"SY-MVSB-QB-17","image":"http://img0.yytcdn.com/video/mv/151225/2458042/-M-968bf0e83699c17cfee56a3aa0a1e53e_240x135.jpg?t=20151225095427","partner":false,"rank":0,"title":"鑷充笂鍔卞悎<灏忛晣闈掑勾>闊充箰鐢靛奖","videoId":2458042},{"artists":[{"artistName":"Panic! At The Disco","id":3793}],"from":"SY-MVSB-QB-18","image":"http://img4.yytcdn.com/video/mv/151225/2457760/-M-bf92b9b4ac82207224d82672efbf62a4_240x135.jpg?t=20151224233748","partner":false,"rank":0,"title":"Death Of A Bachelor","videoId":2457760},{"artists":[{"artistName":"BEAST","id":2654}],"from":"SY-MVSB-QB-19","image":"http://img2.yytcdn.com/video/mv/151224/2457737/-M-845ea5556380365cda0d958265ccb7a3_240x135.jpg?t=20151224232155","partner":false,"rank":0,"title":"STAY FOREVER YOUNG","videoId":2457737},{"artists":[{"artistName":"AKB48","id":994}],"from":"SY-MVSB-QB-20","image":"http://img3.yytcdn.com/video/mv/151224/2456765/-M-bdf6edf22a4cc61af4760a0e0070184a_240x135.jpg?t=20151223201608","partner":false,"rank":0,"title":"鍚涖伅浠娿伨銇с仼銇撱伀銇勩仧?","videoId":2456765},{"artists":[{"artistName":"Selena Gomez","id":2581}],"from":"SY-MVSB-QB-21","image":"http://img2.yytcdn.com/video/mv/151222/2455447/-M-01ae068d781f5ec530e66c51819cd879_240x135.jpg?t=20151222085138","partner":false,"rank":0,"title":"Hands To Myself","videoId":2455447},{"artists":[{"artistName":"鍛ㄥ(MONSTA X)","id":37651},{"artistName":"MONSTA X","id":38259}],"from":"SY-MVSB-QB-22","image":"http://img1.yytcdn.com/video/mv/151223/2456721/-M-62ca73a36eeafccb27188e64a70b0817_240x135.jpg?t=20151223191304","partner":false,"rank":0,"title":"RAPPIN (Short Ver.)","videoId":2456721},{"artists":[{"artistName":"瀹夌惀","id":4057},{"artistName":"濮滄","id":39613}],"from":"SY-MVSB-QB-23","image":"http://img0.yytcdn.com/video/mv/151224/2456671/-M-92dffaa891361d3fc7905380b60e8760_240x135.jpg?t=20151223181625","partner":false,"rank":0,"title":"澶╀笅鏃犲弻 瀹樻柟鐗?","videoId":2456671},{"artists":[{"artistName":"Myl猫ne Farmer","id":3230}],"from":"SY-MVSB-QB-24","image":"http://img4.yytcdn.com/video/mv/151223/2454482/-M-503af2315e48bb1bc312df73ea5a788d_240x135.png?t=20151220223936","partner":false,"rank":0,"title":"City Of Love","videoId":2454482},{"artists":[{"artistName":"娓呮槬","id":375}],"from":"SY-MVSB-QB-25","image":"http://img2.yytcdn.com/video/mv/151223/2456343/-M-673659c6f0874d90177e2ad30cecbb08_240x135.jpg?t=20151223114721","partner":false,"rank":0,"title":"銉娿偠銉兗","videoId":2456343},{"artists":[{"artistName":"Rihwa","id":24680}],"from":"SY-MVSB-QB-26","image":"http://img4.yytcdn.com/video/mv/151223/2456339/-M-09af78577eecb3c0657cb3e0de0c10f4_240x135.jpg?t=20151223114057","partner":false,"rank":0,"title":"鏄庢棩銇亶銇c仺銇勩亜鏃ャ伀銇倠","videoId":2456339},{"artists":[{"artistName":"璧典粫鐟?","id":36843}],"from":"SY-MVSB-QB-27","image":"http://img4.yytcdn.com/video/mv/151223/2456157/-M-e37ac7b6c10de8ebc312a18154a0ec4f_240x135.jpg?t=20151223045958","partner":false,"rank":0,"title":"鍚閭f椂鐨勭埍寰堢編 瀹樻柟鐗?","videoId":2456157},{"artists":[{"artistName":"閮戜笢娌?(澶嶆椿)","id":8936}],"from":"SY-MVSB-QB-28","image":"http://img1.yytcdn.com/video/mv/151223/2456302/-M-81ec673787a00138c8c3c541ecacd224_240x135.jpg?t=20151223111203","partner":false,"rank":0,"title":"鍐嶆,闆?(Snow again) 瀹屾暣鐗?","videoId":2456302},{"artists":[{"artistName":"鐖辨埓","id":950}],"from":"SY-MVSB-QB-29","image":"http://img2.yytcdn.com/video/mv/151223/2456248/-M-ae9d273d0884749213077f5174d12216_240x135.jpg?t=20151223104141","partner":false,"rank":0,"title":"BABY鐖? 瀹樻柟鐗?","videoId":2456248},{"artists":[{"artistName":"A蹇淧","id":39456}],"from":"SY-MVSB-QB-30","image":"http://img4.yytcdn.com/video/mv/151229/2459787/-M-5cc78c553eefccd1e404664420edc31c_240x135.jpg?t=20151227110121","partner":false,"rank":0,"title":"銇仾銇俱倠銇淬仯銇淬伅銈堛亜銇撱仩銇?","videoId":2459787}],
  931. fetchUrl : '/ajax/shoubo',
  932. initSize : 8,
  933. channel : 'MV棣栨挱'
  934.  
  935. });
  936. new Tray({
  937. el : $('#zhengliuxing'),
  938. tpl : $('#video_list_tpl').html(),
  939. data : [{"artists":[{"artistName":"Adele","id":974},{"artistName":"Billboard Hot 100","id":10616}],"from":"SY-ZZLX-QB-1","image":"http://img1.yytcdn.com/video/mv/151230/2462513/-M-fe9b3c28c652557d0571b80615bffdb3_240x135.jpg?t=20151230134237","partner":false,"rank":0,"title":"2016骞寸2鏈熺編鍥紹illboard鍗曟洸姒淭op 50","videoId":2462513},{"artists":[{"artistName":"Joyce Chu 鍥涜憠鑽?","id":34557}],"from":"SY-ZZLX-QB-2","image":"http://img0.yytcdn.com/video/mv/151230/2460808/-M-5724a61f7de6f2dac1a68b20d35d06f6_240x135.jpg?t=20151228122434","partner":false,"rank":0,"title":"濂芥兂浣? 涓嶆彃鐢电増","videoId":2460808},{"artists":[{"artistName":"Charli XCX","id":22776}],"from":"SY-ZZLX-QB-3","image":"http://img0.yytcdn.com/video/mv/151230/2461984/-M-63d93eeca0f07614ed7f7288a4cad37b_240x135.jpg?t=20151229173855","partner":false,"rank":0,"title":"Super Love (EB.TV Live Classics) 鐜板満鐗?","videoId":2461984},{"artists":[{"artistName":"鍒樻稕","id":28328}],"from":"SY-ZZLX-QB-4","image":"http://img4.yytcdn.com/video/mv/151230/2462539/-M-6803f11726c4b3accb49323ba5bbd405_240x135.jpg?t=20151230141629","partner":false,"rank":0,"title":"澶х帇姝屼箣鍒樻稕鑺卞紡鍠婂ぇ鐜?","videoId":2462539},{"artists":[{"artistName":"闄堝鍐?","id":35165},{"artistName":"鍗庤缇ゆ槦","id":4538},{"artistName":"钖涘嚡鐞?","id":246}],"from":"SY-ZZLX-QB-5","image":"http://img3.yytcdn.com/video/mv/151230/2462466/-M-b452078f6401e2b4e3da5c4593601aaf_240x135.jpg?t=20151230114428","partner":false,"rank":0,"title":"鐢靛奖<楂樿窡闉嬪厛鐢?> \"缇庡皯濂冲.澹玕"鐗堥鍛?","videoId":2462466},{"artists":[{"artistName":"Dal鈽卻habet","id":13377}],"from":"SY-ZZLX-QB-6","image":"http://img1.yytcdn.com/video/mv/151230/2462442/-M-be9347cedde600c9514bf292f3f88696_240x135.jpg?t=20151230111121","partner":false,"rank":0,"title":"濡備綘(Someone like U) 棰勫憡鐗?","videoId":2462442},{"artists":[{"artistName":"Gary","id":33009},{"artistName":"瀹嬫櫤瀛?","id":38037},{"artistName":"Gaeko(Dynamic Duo)","id":36197}],"from":"SY-ZZLX-QB-7","image":"http://img3.yytcdn.com/video/mv/151230/2462439/-M-c438aba1d0ae70f3bbb88a21286be20a_240x135.png?t=20151230110540","partner":false,"rank":0,"title":"鍙堜竴澶? 棰勫憡鐗?","videoId":2462439},{"artists":[{"artistName":"闊虫偊V姒滅壒鍒紒鍒?","id":32393},{"artistName":"SpeXial","id":27113}],"from":"SY-ZZLX-QB-8","image":"http://img1.yytcdn.com/video/mv/151226/2459321/-M-3530acefc7f260ed21bb44e2ea6f50f0_240x135.jpg","partner":false,"rank":0,"title":"EP120 鍋跺儚鍖呰⒈绮夌鏈虹鍥涘脊__SpeXial鐗硅緫","videoId":2459321},{"artists":[{"artistName":"褰辫鍘熷0","id":15442}],"from":"SY-ZZLX-QB-9","image":"http://img2.yytcdn.com/video/mv/151229/2461728/-M-f25cddddf0510cd4419cf4b2fe300c8d_240x135.jpg?t=20151229121858","partner":false,"rank":0,"title":"\"鏄熺悆澶ф垬:鍘熷姏瑙夐啋\"寮哄娍鏉ヨ 鍥涘ぇ涓诲垱涓婃捣閫犲娍","videoId":2461728},{"artists":[{"artistName":"AOA","id":25339},{"artistName":"TWICE","id":38959},{"artistName":"VIXX","id":24334},{"artistName":"閲戝湥鍦?(Infinite)","id":26913},{"artistName":"BTOB","id":23535},{"artistName":"闃插脊灏戝勾鍥?","id":29570},{"artistName":"IU","id":3583},{"artistName":"ZICO(Block B)","id":36481},{"artistName":"miss A","id":7742},{"artistName":"Girl's Day","id":8247}],"from":"SY-ZZLX-QB-10","image":"http://img2.yytcdn.com/video/mv/151229/2461685/-M-58ede6478500de62b5f6ceac7458439b_240x135.jpg?t=20151229115409","partner":false,"rank":0,"title":"Who's your mama? - 2015 1theKING 涓枃瀛楀箷","videoId":2461685},{"artists":[{"artistName":"鍗庤缇ゆ槦","id":4538}],"from":"SY-ZZLX-QB-11","image":"http://img4.yytcdn.com/video/mv/151229/2461588/-M-7662a05ca8f6d98bd0f69fd5d4877998_240x135.jpg?t=20151229111150","partner":false,"rank":0,"title":"鐢靛奖<闈掕洐鐜嬪浗2>瀹氭。棰勫憡","videoId":2461588},{"artists":[{"artistName":"娓¤竟楹诲弸","id":22885},{"artistName":"AKB48","id":994}],"from":"SY-ZZLX-QB-12","image":"http://img2.yytcdn.com/video/mv/151229/2460805/-M-e6c46d185ab66bb42c68aeec9109bb59_240x135.jpg?t=20151228131215","partner":false,"rank":0,"title":"<澶уゥ>绗竴閮? 鏈?鍑躲伄濂? 绶? 1鏈?22鏃? 鐗瑰牨3 涓枃瀛楀箷 (涓轰簡楹诲弸瀛楀箷缁?)","videoId":2460805},{"artists":[{"artistName":"鍓嶇敯鏁﹀瓙","id":17280},{"artistName":"楂樻ˉ鍗?","id":28181},{"artistName":"AKB48","id":994}],"from":"SY-ZZLX-QB-13","image":"http://img1.yytcdn.com/video/mv/151228/2460944/-M-55a18d9d56399aabcb1e9c1b9919d331_240x135.jpg?t=20151228154908","partner":false,"rank":0,"title":"鍙宠偐 (2015 Best Ver.)","videoId":2460944},{"artists":[{"artistName":"KAT-TUN","id":385}],"from":"SY-ZZLX-QB-14","image":"http://img4.yytcdn.com/video/mv/151229/2461400/-M-f83397607a552759a1a92f4f11edf91a_240x135.jpg?t=20151229093838","partner":false,"rank":0,"title":"銉嬨兂銈层兂瑕冲療!銉€儖銈裤儶銉炽偘KAT-TUN Part 涓枃瀛楀箷 (15/12/24)","videoId":2461400},{"artists":[{"artistName":"GOT7","id":33018},{"artistName":"Seventeen","id":27172},{"artistName":"BTOB","id":23535},{"artistName":"MONSTA X","id":38259}],"from":"SY-ZZLX-QB-15","image":"http://img1.yytcdn.com/video/mv/151228/2460921/-M-021c9b128db74ee696e3ae4953a4e8b8_240x135.png?t=20151228153053","partner":false,"rank":0,"title":"\"鐤媯鎼炵瑧\"鍚嶈獕娈垮爞 - The Qmentary 涓枃瀛楀箷","videoId":2460921},{"artists":[{"artistName":"2PM","id":1237},{"artistName":"BTOB","id":23535},{"artistName":"TWICE","id":38959},{"artistName":"Girl's Day","id":8247},{"artistName":"GOT7","id":33018},{"artistName":"CNBLUE","id":4289}],"from":"SY-ZZLX-QB-16","image":"http://img2.yytcdn.com/video/mv/151228/2460923/-M-6cdfe55da86377268d6c660a6eb20411_240x135.png?t=20151228153432","partner":false,"rank":0,"title":"蹇嶇瑧10闃舵 涓枃瀛楀箷","videoId":2460923},{"artists":[{"artistName":"鍚翠害鍑?","id":34611}],"from":"SY-ZZLX-QB-17","image":"http://img1.yytcdn.com/video/mv/151228/2460830/-M-656fde0aa3f5161007eb7b5fa05d10a8_240x135.jpg?t=20151228130555","partner":false,"rank":0,"title":"<鑺辨埧濮戝>鏂扮紪MV 楗埗鐗?","videoId":2460830},{"artists":[{"artistName":"闊虫偊V姒?","id":21713},{"artistName":"5 Seconds of Summer","id":31322}],"from":"SY-ZZLX-QB-18","image":"http://img3.yytcdn.com/video/mv/151228/2452301/-M-48b19e3ecfca2deb49d721c12b3b0f72_240x135.jpg?t=20151218155622","partner":false,"rank":0,"title":"浜旂鐩涘 鎵撴ID","videoId":2452301},{"artists":[{"artistName":"灞变笅鏅轰箙","id":3250}],"from":"SY-ZZLX-QB-19","image":"http://img3.yytcdn.com/video/mv/151228/2460120/-M-6eeb025f8a6a935defe484de6223edd8_240x135.jpg?t=20151227154907","partner":false,"rank":0,"title":"灞盤鐨凨ISS鑻辫 绗崄鍏洖 涓枃瀛楀箷 15/11/06(P鍚у瓧骞曠粍)","videoId":2460120},{"artists":[{"artistName":"鍗庤缇ゆ槦","id":4538}],"from":"SY-ZZLX-QB-20","image":"http://img0.yytcdn.com/video/mv/151228/2460787/-M-e183387ea65199566752f177cf4e56bc_240x135.jpg?t=20151228115100","partner":false,"rank":0,"title":"鐢靛奖<鍔熷か鐔婄尗3>鐔婄尗鎷ユ姳璁″垝鍏ㄧ邯褰?","videoId":2460787},{"artists":[{"artistName":"鍏虫檽褰?","id":34692}],"from":"SY-ZZLX-QB-21","image":"http://img4.yytcdn.com/video/mv/151228/2460752/-M-0ccc4d44b7a0fe611fc9539d3b5d0832_240x135.jpg?t=20151228111135","partner":false,"rank":0,"title":"瀹夋磥瑗垮叕涓? 30绉掗鍛婄増","videoId":2460752},{"artists":[{"artistName":"鍗庤缇ゆ槦","id":4538}],"from":"SY-ZZLX-QB-22","image":"http://img0.yytcdn.com/video/mv/151228/2460726/-M-73be5dbc9db69c7cd220b003f5027599_240x135.jpg?t=20151228105259","partner":false,"rank":0,"title":"鐢靛奖<鑰佺偖鍎?>绠¤檸鐗硅緫","videoId":2460726},{"artists":[{"artistName":"鍗庤缇ゆ槦","id":4538}],"from":"SY-ZZLX-QB-23","image":"http://img2.yytcdn.com/video/mv/151228/2460675/-M-6833ff43b0d8abfa2d393fa92dfd71c2_240x135.jpg?t=20151228095619","partner":false,"rank":0,"title":"鐢靛奖<骞村吔澶т綔鎴?> \"鍏芥?уぇ鍙慭"鐗硅緫","videoId":2460675},{"artists":[{"artistName":"浣熶附濞?","id":25002},{"artistName":"鍛ㄥ啲闆?","id":14997}],"from":"SY-ZZLX-QB-24","image":"http://img0.yytcdn.com/video/mv/151228/2460673/-M-52ad28eee299241542e667d3a41429a4_240x135.jpg?t=20151228095429","partner":false,"rank":0,"title":"鐢靛奖<濂旂埍> \"鐪熺埍\"鐗硅緫","videoId":2460673},{"artists":[{"artistName":"寮犺壓鍏?(EXO)","id":29765},{"artistName":"瀛欑孩闆?","id":21696},{"artistName":"榛勬袱","id":16782},{"artistName":"榛勭","id":2344},{"artistName":"缃楀織绁?","id":15}],"from":"SY-ZZLX-QB-25","image":"http://img2.yytcdn.com/video/mv/151228/2460660/-M-e8ec5c64ba0b516eb35dcfc91502d862_240x135.jpg?t=20151228094303","partner":false,"rank":0,"title":"鐢靛奖<鏋侀檺鎸戞垬>\"涓夌簿涓夊偦\"鐗堥鍛?","videoId":2460660},{"artists":[{"artistName":"Miley Cyrus","id":280}],"from":"SY-ZZLX-QB-26","image":"http://img1.yytcdn.com/video/mv/151227/2460113/-M-eef3410c3f1c58b353745188a3fb724c_240x135.jpg?t=20151227152151","partner":false,"rank":0,"title":"My Sad Christmas Song (璇曞惉)","videoId":2460113},{"artists":[{"artistName":"Elle King","id":36104}],"from":"SY-ZZLX-QB-27","image":"http://img1.yytcdn.com/video/mv/151227/2460018/-M-084edc13e7c33e357e8ecfa8c5ecbfb8_240x135.jpg?t=20151227130112","partner":false,"rank":0,"title":"America's Sweetheart(鐜板満鐗?)","videoId":2460018},{"artists":[{"artistName":"褰辫鍘熷0","id":15442}],"from":"SY-ZZLX-QB-28","image":"http://img2.yytcdn.com/video/mv/151226/2458977/-M-3d7c28268c0e15725cd92246213ef3f9_240x135.jpg?t=20151226105427","partner":false,"rank":0,"title":"鐢靛奖<姝讳緧>涓枃棰勫憡 涓枃瀛楀箷","videoId":2458977},{"artists":[{"artistName":"Coldplay","id":123}],"from":"SY-ZZLX-QB-29","image":"http://img3.yytcdn.com/video/mv/151226/2458901/-M-9ec87cf3b8e349621a9522aa351b4a88_240x135.jpg?t=20151226093802","partner":false,"rank":0,"title":"Adventure Of A Lifetime (2015 Top of the Pops) 鐜板満鐗?","videoId":2458901},{"artists":[{"artistName":"Years & Years","id":33897}],"from":"SY-ZZLX-QB-30","image":"http://img3.yytcdn.com/video/mv/151226/2458882/-M-5f35a83f4dd3e2ada03ecbfb3f15c3d2_240x135.jpg?t=20151226092752","partner":false,"rank":0,"title":"King (2015 BBC Top of the Pops) 鐜板満鐗?","videoId":2458882}],
  940. fetchUrl : '/ajax/zhengliuxing',
  941. initSize : 6,
  942. channel : '姝e湪娴佽'
  943. });
  944. var vchartVideos = [{"artists":[{"artistName":"TFBOYS","id":30905}],"from":"SY-YYVB-ND-1","image":"http://img2.yytcdn.com/video/mv/151211/2445791/-M-ccf0e8542755f34b3505e2180a0a8190_240x135.jpg?t=20151211102043","partner":false,"rank":1,"title":"澶фⅵ鎯冲 瀹樻柟鐗?","videoId":2445791},{"artists":[{"artistName":"鏉庢槗宄?","id":279},{"artistName":"鍐皬鍒?","id":39610}],"from":"SY-YYVB-ND-2","image":"http://img4.yytcdn.com/video/mv/151222/2455446/-M-564f19d5c67da7834113b8a888cc68e6_240x135.jpg","partner":false,"rank":2,"title":"鐖辩殑浠d环 鐢靛奖<鑰佺偖鍎?>瀹d紶鏇?","videoId":2455446},{"artists":[{"artistName":"鍚翠害鍑?","id":34611}],"from":"SY-YYVB-ND-3","image":"http://img2.yytcdn.com/video/mv/151217/2450920/-M-c7a9589e906669b7fdcb7b13f2d8058b_240x135.jpg?t=20151217095024","partner":false,"rank":3,"title":"鑺辨埧濮戝 鐢靛奖<鑰佺偖鍎?>瀹d紶鏇?","videoId":2450920},{"artists":[{"artistName":"鏉庢槗宄?","id":279}],"from":"SY-YYVB-ND-4","image":"http://img3.yytcdn.com/video/mv/151216/2450184/-M-7f783c2ff2ca14ed53379976204177d9_240x135.jpg?t=20151216113853","partner":false,"rank":4,"title":"璇疯窡鎴戣仈缁?","videoId":2450184},{"artists":[{"artistName":"鏉庡畤鏄?","id":32}],"from":"SY-YYVB-ND-5","image":"http://img4.yytcdn.com/video/mv/151210/2445086/-M-c20428d09f1e95d7a68c7d893b985e5c_240x135.jpg","partner":false,"rank":5,"title":"娣疯泲,鎴戞兂浣? 瀹樻柟鐗?","videoId":2445086},{"artists":[{"artistName":"鏉庡畤鏄?","id":32}],"from":"SY-YYVB-ND-6","image":"http://img3.yytcdn.com/video/mv/151210/2445094/-M-cf7d8e004929a2bfcdcb6627550ee584_240x135.jpg","partner":false,"rank":6,"title":"鐖辨湁寮曞姏 瀹樻柟鐗?","videoId":2445094},{"artists":[{"artistName":"鑷充笂鍔卞悎","id":158}],"from":"SY-YYVB-ND-7","image":"http://img0.yytcdn.com/video/mv/151225/2458042/-M-968bf0e83699c17cfee56a3aa0a1e53e_240x135.jpg?t=20151225095427","partner":false,"rank":7,"title":"鑷充笂鍔卞悎<灏忛晣闈掑勾>闊充箰鐢靛奖","videoId":2458042},{"artists":[{"artistName":"鐖辨埓","id":950}],"from":"SY-YYVB-ND-8","image":"http://img2.yytcdn.com/video/mv/151223/2456248/-M-ae9d273d0884749213077f5174d12216_240x135.jpg?t=20151223104141","partner":false,"rank":8,"title":"BABY鐖? 瀹樻柟鐗?","videoId":2456248},{"artists":[{"artistName":"闃块瞾闃垮崜","id":2794}],"from":"SY-YYVB-ND-9","image":"http://img0.yytcdn.com/video/mv/151130/2435691/-M-72715c973f9b613358b64b8fdb737d80_240x135.jpg?t=20151130103723","partner":false,"rank":9,"title":"瑗块","videoId":2435691},{"artists":[{"artistName":"闊╁簹","id":4437}],"from":"SY-YYVB-ND-10","image":"http://img4.yytcdn.com/video/mv/151220/2453778/-M-7666a25b90ef97690b8550b0db7ed529_240x135.jpg?t=20151220100137","partner":false,"rank":10,"title":"閫冧笉鎺? 瀹樻柟鐗?","videoId":2453778},{"artists":[{"artistName":"楣挎櫁","id":36176}],"from":"SY-YYVB-ND-11","image":"http://img4.yytcdn.com/video/mv/151202/2437545/-M-07ff74d984a27e80022d10e2e22cee3b_240x135.jpg?t=20151202091854","partner":false,"rank":11,"title":"娴峰簳 鐢靛奖<鍔熷か鐔婄尗3>瀹樻柟鎺ㄥ箍鏇?","videoId":2437545},{"artists":[{"artistName":"閭撹秴","id":3279}],"from":"SY-YYVB-ND-12","image":"http://img4.yytcdn.com/video/mv/151220/2453752/-M-e97b78a19f49be20ce23a692567c9059_240x135.png","partner":false,"rank":12,"title":"鏈夋儏涓栭棿 鐢靛奖<鎭舵澶╀娇>涓婚鏇?","videoId":2453752},{"artists":[{"artistName":" O2O Goddess","id":39594}],"from":"SY-YYVB-ND-13","image":"http://img4.yytcdn.com/video/mv/151222/2455522/-M-3b7efc178e194fe2dcd9b6a92b3e2584_240x135.jpg?t=20151222095904","partner":false,"rank":13,"title":"澹佸挌 鐢靛奖<蹇冩儕鑲夌瑧>涓婚鏇?","videoId":2455522},{"artists":[{"artistName":"璧佃嫳淇?","id":27219},{"artistName":"鐧藉","id":30713},{"artistName":"鍙吔鏄撳皬鏄?","id":30370}],"from":"SY-YYVB-ND-14","image":"http://img1.yytcdn.com/video/mv/151218/2451759/-M-cb69010e1d90efcacbe637550ca09211_240x135.jpg?t=20151217215710","partner":false,"rank":14,"title":"涓囦竾 鐢靛奖<涓囦竾娌℃兂鍒?>涓婚鏇?","videoId":2451759},{"artists":[{"artistName":"濂藉濡逛箰闃?","id":26665}],"from":"SY-YYVB-ND-15","image":"http://img4.yytcdn.com/video/mv/151220/2454001/-M-22114f8c6f2edc93d69d1316fc700c9c_240x135.jpg","partner":false,"rank":15,"title":"涓?灏佸涔? 鐢靛奖<涓?鍒囬兘濂?>鎺ㄥ箍鏇?","videoId":2454001},{"artists":[{"artistName":"鐜嬭搲","id":90}],"from":"SY-YYVB-ND-16","image":"http://img3.yytcdn.com/video/mv/151222/2455585/-M-b3b4cc01b95c904c8400b584d9999d1b_240x135.jpg?t=20151222112603","partner":false,"rank":16,"title":"鍙堕棶 鐢靛奖<鍙堕棶3>瀹d紶鏇?","videoId":2455585},{"artists":[{"artistName":"鏉洊","id":37530}],"from":"SY-YYVB-ND-17","image":"http://img4.yytcdn.com/video/mv/151223/2456183/-M-ad1639dc2622495f9def107228149c8a_240x135.jpg?t=20151223100523","partner":false,"rank":17,"title":"閰掓瓕 鐢靛奖<瀵婚緳璇?>鎻掓洸","videoId":2456183},{"artists":[{"artistName":"瀹嬭寽","id":16169}],"from":"SY-YYVB-ND-18","image":"http://img0.yytcdn.com/video/mv/151217/2450963/-M-75a8fa8c62ce4948ecae61fc87705677_240x135.jpg?t=20151217103401","partner":false,"rank":18,"title":"鏄熸槦娉? 鐢佃鍓?<缇庝附鐨勭瀵?>涓婚鏇?","videoId":2450963},{"artists":[{"artistName":"EXO","id":22594}],"from":"SY-YYVB-ND-19","image":"http://img3.yytcdn.com/video/mv/151209/2444735/-M-d80b55804935634e9b5a6c883291743c_240x135.jpg","partner":false,"rank":19,"title":"EXO_Sing For You(涓轰綘鑰屽敱)_Music Video","videoId":2444735},{"artists":[{"artistName":"鍗庢櫒瀹?","id":30165}],"from":"SY-YYVB-ND-20","image":"http://img0.yytcdn.com/video/mv/151120/2425734/-M-d7d304680469f1d63203274d159d8326_240x135.jpg?t=20151120100025","partner":false,"rank":20,"title":"铚夎潱 瀹樻柟鐗?","videoId":2425734}];
  945. vchartVideos = vchartVideos.concat([
  946. {type : 'trends', area : 'ML'},
  947. {type : 'v', area : 'ML'}
  948. ]);
  949. var vchart = new Tray({
  950. el : $('#vchart'),
  951. tpl : $('#video_list_tpl').html(),
  952. data : vchartVideos,
  953. fetchUrl : '/ajax/vchart',
  954. initSize : 6,
  955. special : 'vchart',
  956. channel : '闊虫偊V姒?'
  957. });
  958. vchart.on('loadArea', function(area) {
  959. store.set('index-vchart-area', area);
  960. });
  961. var area = store.get('index-vchart-area');
  962. if (area && area != 'ml') {
  963. vchart.on('init', function() {
  964. vchart.$el.find('.J_area[data-area=' + area + ']').click();
  965. })
  966. }
  967. });
  968. </script>
  969. </div>
  970. <!-- End 鍐呭 -->
  971.  
  972. <!-- Strat Footer-->
  973. <div class="footer">
  974. <p class="footer_link">
  975. <a href="http://www.yinyuetai.com/article/3" target="_blank" title="鍏充簬鎴戜滑">鍏充簬鎴戜滑</a>
  976. <span class="ico_line"></span>
  977. <a href="http://www.yinyuetai.com/joinus" target="_blank" title="浜烘墠鎷涜仒">浜烘墠鎷涜仒</a>
  978. <span class="ico_line"></span>
  979. <a href="http://www.yinyuetai.com/article/1" target="_blank" title="鑱旂郴鎴戜滑">鑱旂郴鎴戜滑</a>
  980. <span class="ico_line"></span>
  981. <a href="http://www.yinyuetai.com/links" target="_blank" title="鍙嬫儏閾炬帴">鍙嬫儏閾炬帴</a>
  982. <span class="ico_line"></span>
  983. <a href="http://www.yinyuetai.com/article/4" target="_blank" title="鐗堟潈澹版槑">鐗堟潈澹版槑</a>
  984. <span class="ico_line"></span>
  985. <a href="http://www.yinyuetai.com/service/problem" target="_blank" title="瀹㈡湇涓績">瀹㈡湇涓績</a>
  986. </p>
  987.  
  988. <p class="footer_copy">
  989. Copyright &copy; 2009 - 2014 yinyuetai.com 骞挎挱鐢佃鑺傜洰鍒朵綔缁忚惀 璁稿彲璇佺紪鍙?(浜?)瀛楃1891鍙? | <a href="http://www.yinyuetai.com/cert" target="_blank">浜綉鏂嘯2014]2037-287鍙?</a>
  990. | <a href="http://www.yinyuetai.com/permit" title="缃戠粶瑙嗗惉璁稿彲璇?0110413鍙?">缃戠粶瑙嗗惉璁稿彲璇?0110413鍙?</a><br/>
  991. 浜琁CP澶?11024134鍙?-1 | 浜琁CP璇?060716鍙? | 浜叕缃戝畨澶?110105014900 | 鍑虹増鐗╃粡钀ヨ鍙瘉 鏂板嚭鍙戜含闆跺瓧绗湞130062鍙? | 澧炲?肩數淇′笟鍔$粡钀ヨ鍙瘉B2-20140501
  992. <a href="http://www.hd315.gov.cn/beian/view.asp?bianhao=010202013092900002" target="_blank" class="positionImg"><img src="http://s.yytcdn.com/images/biaoshi.gif" style="vertical-align: top; margin-top: -25px;"/></a>
  993. </p>
  994. </div>
  995. <!-- End Footer -->
  996.  
  997. <script type="text/javascript">
  998. (function() {
  999. var counter = 1;
  1000.  
  1001. var timer = setInterval(function(){
  1002. counter = counter + 2;
  1003. }, 2000);
  1004.  
  1005. if ($.toString().indexOf('fn') !== -1 || $.toString().indexOf('J.init') !== -1) {
  1006. $.ajax({
  1007. url : 'http://gettime.yinyuetai.com/time?t='+new Date().getTime(),
  1008. dataType : 'jsonp',
  1009. success : function(data) {
  1010. $(window).on('beforeunload', function() {
  1011. clearInterval(timer);
  1012. $.ajax({
  1013. cache : false,
  1014. async : false,
  1015. type : 'post',
  1016. url : '/onunload?start=' + counter + '&date=' + data.time + '&seconds=' + counter
  1017. });
  1018. });
  1019. }
  1020. });
  1021. } else if ($.toString().indexOf('document.id') !== -1) {
  1022. new Request.JSONP({
  1023. url : 'http://gettime.yinyuetai.com/time?t='+new Date().getTime(),
  1024. onComplete : function(data) {
  1025. $(window).addEvent('beforeunload', function() {
  1026. clearInterval(timer);
  1027. new Request({
  1028. method : "post",
  1029. async : false,
  1030. noCache : true,
  1031. url : '/onunload?start=' + counter + '&date=' + data.time + '&seconds=' + counter
  1032. }).send();
  1033. });
  1034. }
  1035. }).send();
  1036. }
  1037. })();
  1038. </script>
  1039. <script type="text/javascript">
  1040. (function() {
  1041. var urls = window.TRACK_SHOW;
  1042. if (!urls || !urls.push) {
  1043. urls = [];
  1044. }
  1045. urls.push("http://log.collect.yinyuetai.com/view-log?referUrl=" + document.referrer);
  1046. urls.push("http://log.collect.yinyuetai.com/page?referUrl=" + document.referrer);
  1047. for (var i = 0, len = urls.length; i < len; i++) {
  1048. var url = urls[i];
  1049. if (url.indexOf("?") < 0)
  1050. url += "?" + (new Date()).getTime();
  1051. else
  1052. url += "&" + (new Date()).getTime();
  1053. document.write('<img style="display: none;" width="1" height="1" src="' + url + '">');
  1054. }
  1055. })();
  1056. </script>
  1057. <script type="text/javascript">
  1058. (function(G, D, s, c, p) {
  1059. c = {
  1060. UA : "UA-yinyuetai-000001",
  1061. NO_FLS : 0,
  1062. WITH_REF : 1,
  1063. URL : "http://s.yytcdn.com/js/utils/iwt-min-yyt.js"
  1064. };
  1065. G._iwt ? G._iwt.track(c, p) : (G._iwtTQ = G._iwtTQ || []).push([c, p]), !G._iwtLoading && lo();
  1066. function lo(t) {
  1067. G._iwtLoading = 1;
  1068. s = D.createElement("script");
  1069. s.src = c.URL;
  1070. t = D.getElementsByTagName("script");
  1071. t = t[t.length - 1];
  1072. t.parentNode.insertBefore(s, t);
  1073. }
  1074. })(this, document);
  1075. </script>
  1076.  
  1077. <span style="display:none">
  1078.  
  1079. <script language="JavaScript">
  1080. <!--
  1081. pagechoice_t_url = 'http://col.hztags.net/dap/www/delivery/hztags.php?random=' + ( Math.floor(Math.random() * 10000 + 1) );
  1082. document.write("<img width='1' height='1' style='position: absolute' src='" + pagechoice_t_url + "'/>");
  1083. //--></script>
  1084. <script src="http://s4.cnzz.com/stat.php?id=1330456&web_id=1330456" type="text/javascript"></script>
  1085.  
  1086. <script type="text/javascript">
  1087. window.YYTrev = "###revision###";
  1088. window.YYThostName = "BGP-LF-1RS1121";
  1089. window.YYTrequestStart = "1451479894035";
  1090. window.YYTrequestEnd = "1451479894665";
  1091. var uid1 = "awCxLrSY9aQEfpiPlzdbzKDJ";
  1092. var uid = null;
  1093. try {
  1094. uid = Y.Cookie.get("yinyuetai_uid");
  1095. if (uid == null) {
  1096. uid = uid1;
  1097. }
  1098. var ref = document.referrer || "";
  1099. if (uid != null && uid.length > 0) {
  1100. var masterUrl = "http://cm.admaster.com.cn/?tid=1635&type=1&uid=" + uid + "&loc=" + encodeURIComponent(location.href) +
  1101. "&ref=" + encodeURIComponent(ref);
  1102. var img = new Image();
  1103. img.src = masterUrl;
  1104. img.width = 1;
  1105. img.height = 1;
  1106. //document.body.appendChild(img);
  1107. }
  1108.  
  1109. } catch (ex) {}
  1110. </script>
  1111.  
  1112. <script type="text/javascript">
  1113. (function() {
  1114. var csid = "F09828";
  1115. var bpid = "yinyuetai";
  1116. var e = document.createElement("script");
  1117. var s = document.getElementsByTagName("script")[0];
  1118. e.src = "//js.revsci.net/gateway/gw.js?auto=t&csid=" + csid + "&bpid=" + bpid;
  1119. e.async = true;
  1120. s.parentNode.insertBefore(e, s);
  1121. })();
  1122. </script>
  1123. </span>
  1124.  
  1125. </div>
  1126.  
  1127. </body>
  1128. </html>
  1129.  
  1130. http
  1131. //www.cnblogs.com/liuzhongfeng
  1132. www.cnblogs.com
  1133. null
  1134. www.cnblogs.com
  1135. -1
  1136. /liuzhongfeng
  1137. null
  1138. null
  1139. http//www.cnblogs.com/p/5084309
  1140. /p/5084309

2、URL和URLConnection

  1)、如果想要获取某个网页的html源代码,比如http://www.cnblogs.com/liuzhongfeng 则只需要:

    (1)URL url = new URL("http://www.cnblogs.com/liuzhongfeng/");

    (2)Scanner in = new Scanner(url.openStream());

  2)、当操作一个URLConnection对象时,注意以下内容:

    URLConnection connection=url.openConnection();获得URLConnection对象。

    connection.connect();连接远程资源

    connection.getContentLength();

    connection.getContentType();

    connection.setDoOutput(true)获得输出流

    connection.getOutputStream();

    connection.getInputStream();

  1. package socket;
  2. import java.net.*;
  3. import java.util.List;
  4. import java.util.Map;
  5. public class URLConnectionTest {
  6. public static void main(String[] args)throws Exception{
  7. String urlName="http://java.sun.com";
  8. URL url=new URL(urlName);
  9. URLConnection connection=url.openConnection();
  10. Map<String,List<String>> map=connection.getHeaderFields();
  11. for(Map.Entry<String, List<String>>entry:map.entrySet()){
  12. String key=entry.getKey();
  13. List<String>value=entry.getValue();
  14. System.out.println(key+":"+value);
  15. }
  16. }
  17. }
  1. Transfer-Encoding:[chunked]
  2. X-Frame-Options:[SAMEORIGIN]
  3. null:[HTTP/1.1 200 OK]
  4. Server:[Oracle-Application-Server-11g Oracle-Web-Cache-11g/11.1.1.6.0 (TH;max-age=300+0;age=120;ecid=163913388711036,0:1)]
  5. Access-Control-Allow-Origin:[*]
  6. Connection:[Transfer-Encoding, keep-alive]
  7. Date:[Wed, 30 Dec 2015 13:09:53 GMT]
  8. Content-Language:[en]
  9. Content-Type:[text/html; charset=utf-8]
  10. X-Powered-By:[Servlet/2.5 JSP/2.1]

四、提交表单数据

  我们知道了如何从一个Web服务器读取数据。那么,程序如何又再将数据返回给Web服务器和那些被Web服务器调用的程序呢?通过程序脚本技术可以实现Web服务器对程序的调用。如Java Servlet、JavaServer Face等。

  在向Web服务器发送信息时,通常用到两个命令:get和post

  (1)、get方法是直接把数据跟在url的后面,以name=value进行传输,

每个数据之间用&进行分割,value中的空格用+替换,非字母数字用%替换,并后跟两个16进制数,这种编码方式称为URL编码。URLEncoder和URLDecoder

  (2)、post方法是通过URLConnection发送给服务器,编码方式和get一样。URLEncoder.encode(VALUE,"UTF-8");

一般在传输中文时会运用编码和解码。

具体的向服务器发送数据的过程:

  1)、创建一个URLConnection对象。URL url=new URL(String);URLConnection connnection=url.openConnection();

  2)、调用setDoOutput方法建立一个用于输出的连接。connection.setDoOutput(true);

  3)、调用getOutputStream方法获得一个流。通过这个流可以向服务器发送数据。如果想要发送文本信息,可以将流包装在PrintWriter对象中。

    即:PrintWriter out=new PrintWriter(connnect.getOutputStream());

  4)、向服务器发送数据。out.print(name1+" "+URLEncoder.encode(value1,"UTF-8")+"&");

  5)、关闭输出流。out.close();

  1. package socket;
  2. import java.io.*;
  3. import java.net.*;
  4. import java.nio.file.*;
  5. import java.util.*;
  6. public class PostTest {
  7. public static void main(String[] args)throws IOException{
  8. Properties props=new Properties();
  9. try(InputStream in=Files.newInputStream(Paths.get(args[0]))){
  10. props.load(in);
  11. }
  12. String url=props.remove("url").toString();
  13. String result=doPost(url,props);
  14. System.out.println(result);
  15. }
  16. public static String doPost(String urlString ,Map<Object,Object>nameValuePairs)throws IOException{
  17. URL url=new URL(urlString);
  18. URLConnection connection=url.openConnection();
  19. connection.setDoOutput(true);
  20. try(PrintWriter out=new PrintWriter(connection.getOutputStream())){
  21. boolean first=true;
  22. for(Map.Entry<Object, Object>pair:nameValuePairs.entrySet()){
  23. if(first) first=false;
  24. else out.print('&');
  25. String name=pair.getKey().toString();
  26. String value=pair.getValue().toString();
  27. out.print(name);
  28. out.print('=');
  29. out.print(URLEncoder.encode(value,"UTF-8"));
  30. }
  31. }
  32. StringBuilder response=new StringBuilder();
  33. try(Scanner in=new Scanner(connection.getInputStream())){
  34. while(in.hasNextLine()){
  35. response.append(in.nextLine());
  36. response.append("/n");
  37. }
  38. }
  39. catch(IOException e){
  40. if(!(connection instanceof HttpURLConnection)) throw e;
  41. InputStream err=((HttpURLConnection)connection).getErrorStream();
  42. if(err==null)throw e;
  43. Scanner in=new Scanner(err);
  44. response.append(in.nextLine());
  45. response.append("\n");
  46. }
  47. return response.toString();
  48. }
  49. }

Java:网络编程的更多相关文章

  1. 20145205 《Java程序设计》实验报告五:Java网络编程及安全

    20145205 <Java程序设计>实验报告五:Java网络编程及安全 实验要求 1.掌握Socket程序的编写: 2.掌握密码技术的使用: 3.客户端中输入明文,利用DES算法加密,D ...

  2. Java 网络编程学习总结

    新手一枚,Java学习中,把自己学习网络编程的知识总结一下,梳理下知识,方便日后查阅,高手莫进. 本文的主要内容: [1]    网络编程认识                [2]  TCP/IP编程 ...

  3. 20145212 实验五《Java网络编程》

    20145212 实验五<Java网络编程> 一.实验内容 1.运行下载的TCP代码,结对进行,一人服务器,一人客户端: 2.利用加解密代码包,编译运行代码,一人加密,一人解密: 3.集成 ...

  4. 20145213《Java程序设计》实验五Java网络编程及安全

    20145213<Java程序设计>实验五Java网络编程及安全 实验内容 1.掌握Socket程序的编写. 2.掌握密码技术的使用. 3.设计安全传输系统. 实验预期 1.客户端与服务器 ...

  5. 20145206《Java程序设计》实验五Java网络编程及安全

    20145206<Java程序设计>实验五 Java网络编程及安全 实验内容 1.掌握Socket程序的编写: 2.掌握密码技术的使用: 3.设计安全传输系统. 实验步骤 我和201451 ...

  6. 20145337实验五Java网络编程及安全

    20145337实验五Java网络编程及安全 实验内容 掌握Socket程序的编写 掌握密码技术的使用 设计安全传输系统 实验步骤 基于Java Socket实现安全传输 基于TCP实现客户端和服务器 ...

  7. java 网络编程复习(转)

    好久没有看过Java网络编程了,现在刚好公司有机会接触,顺便的拾起以前的东西 参照原博客:http://www.cnblogs.com/linzheng/archive/2011/01/23/1942 ...

  8. JAVA课程实验报告 实验五 Java网络编程及安全

    北京电子科技学院(BESTI) 实     验    报     告 课程:Java程序设计  班级:1353  姓名:韩玉琪  学号:20135317 成绩:             指导教师:娄嘉 ...

  9. 20145225《Java程序设计》 实验五 Java网络编程及安全

    20145225<Java程序设计> 实验五 Java网络编程及安全 实验报告 一.实验内容 基于Java Socket实现安全传输. 基于TCP实现客户端和服务器,结对编程一人负责客户端 ...

  10. Java 网络编程----基本概念

    网络现在是一个非常普遍的概念. 以下是维基百科上的解释: 网络一词有多种意义,可解作: 网络流也简称为网络(network).一般用于管道系统.交通系统.通讯系统建模. 有时特指计算机网络. 或特指其 ...

随机推荐

  1. mysql 字符集配置

    查看和设置MySQL数据库字符集作者:scorpio 2008-01-21 10:05:17 标签: 杂谈 Liunx下修改MySQL字符集:1.查找MySQL的cnf文件的位置find / -ina ...

  2. git版本控制(一)

    ​[声明] 欢迎转载,但请保留文章原始出处→_→ 生命壹号:http://www.cnblogs.com/smyhvae/ 文章来源:http://www.cnblogs.com/smyhvae/p/ ...

  3. input输入框和 pure框架中的 box-sizing 值问题

    在使用pureCSS框架的时候,遇到一个问题. input输入框,我给他们设置了宽度和padding值,我发现,在火狐和谷歌上面发现,增加padding值并不会影响最终的宽度,而在IE6 7下则会影响 ...

  4. Linux:网络yum源设置

    网络yum源,最大的网易(163)算是一个,无论是速度还是软件版本,都非常的不错,将yum源设置为163yum,可以提升软件包安装和更新的速度,同时避免一些常见软件版本无法找到.具体设置方法如下: 1 ...

  5. python之路:进阶篇 内置函数

     li = [11, 22, 33] news = map(  li = [100, 2200, 3300] news = map(  [13, 24, 35] [11, 11, 11] [22, 4 ...

  6. TCP与UDP的区别(转)

    源:http://blog.chinaunix.net/uid-20745340-id-1878774.html 参考:TCP协议与UDP协议的区别 TCP与UDP的区别 中国移动.中国联通推行的GP ...

  7. HDU 1540 POJ 2892 Tunnel Warfare

    线段树 区间合并 单点修改 区间查询.又是1秒钟构思,差错查了好久... ... 发现一个int型的定义成了char型,打脸. #include <stdio.h> #include &l ...

  8. Lua学习系列(二)

    资源整理: 风云老师博客: http://blog.codingnow.com/eo/luaoeeeaeau/ 知乎: https://www.zhihu.com/question/20736660 ...

  9. CMU机器学习课程-简介

    CMU在机器学习研究领域大名鼎鼎,Tom Mitchell 即是该学校老师.学校开设有机器学习课程.如今机器学习应用的领域越来越广泛,之前传统的<机器学习>课程,现在分成一般非机器学习领域 ...

  10. 链接器工具错误 LNK1123

    由于新学C++变成,找不到人求教,所以这个问题困扰了我很久,今天终于找到终极解决方案了: 出处,此帖25楼: http://bbs.csdn.net/topics/390121452 终极解决方案:V ...