我有一个jquery的插件(是一个JS文件)。 中间有这样的一段代码
a.fn.prettyPhoto = function(t) {
t = jQuery.extend({
animationSpeed: "normal",
padding: 40,
opacity: 0.4,
showTitle: true,
allowresize: true,
counter_separator_label: "/",
theme: "light_rounded",
callback: function() { }因为这个插件在很多页面都用到了。
有什么办法把【callback】回调函数。写在页面中间。
a.fn.prettyPhoto = function(t) {
t = jQuery.extend({
animationSpeed: "normal",
padding: 40,
opacity: 0.4,
showTitle: true,
allowresize: true,
counter_separator_label: "/",
theme: "light_rounded",
callback: function() { }因为这个插件在很多页面都用到了。
有什么办法把【callback】回调函数。写在页面中间。
解决方案 »
- 如何点击图片引发查询action
- JavaScript传值问题【已解决】
- 执行button的onclientclick 后 textbox内容被清空
- 请教一个在网页中js控制默认横向打印的问题
- jquery text() 遇到“对象不支持此属性或方法”,求救!
- 如何自动下载服务器上的文件到本地? 100 在线等候
- <marquee>问题
- 请问怎么在我着段代码里定义函数啊?我怎么定义不了!在线等待~!!
- 图片为什么显示在图层上,一个有关菜单的显示问题?
- 请问<script src="xxx.js">和<!-- #include file="xxx.js"-->有何区别?
- 求一段js代码 就是连线页面中任意2个div的~~~~
- 图片一组显示,但是点击向前向后按钮可以如下显示?
a.fn.prettyPhoto = function(t) {
t = jQuery.extend({
animationSpeed: "normal",
padding: 40,
opacity: 0.4,
showTitle: true,
allowresize: true,
counter_separator_label: "/",
theme: "light_rounded",
callback: fun
$.fn.f = function(p) {
p = $.extend({}, {
callBack: function() {}
}, p);
}//调用
$('#aa').f({
callBack: function() {
...
}
});