2011-07-03 84 views
0
<html> 
<head> 
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
<title>Untitled Document</title> 

<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/library/js/pixastic.custom.js"></script> 

<script type="text/javascript"> 

     $(document).ready(function() { 
      $(".attachment-thumbnail").load(); 
     $('.attachment-thumbnail').pixastic("desaturate"); 
    }); 
</script> 
</head> 

<body> 
<img class="attachment-thumbnail" src="image1.jpg"/> 
</body> 
</html> 

我一直在为此工作了将近一天,甚至无法完成。你可以看到不饱和的缩略图here 任何帮助将不胜感激。Pixastic效果问题

+0

难道你不使用调试器吗? Firefox的错误控制台报告:“$不是函数,第40行”。 – katspaugh

回答

0

你已经有了一个JS错误第40行:40

TypeError: Property '$' of object [object DOMWindow] is not a function 

线路是:

$(".attachment-thumbnail").load(); 

看来你有麻烦的jQuery(jQuery的功能在Chrome浏览器调试器)

0

你没有的jQuery核心加载花花公子:-) 你需要添加

<script type="text/javascript" src="jquery.js ... 

就在添加pixastic之前