Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/jquery-ui/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Jquery ui 如何将自定义主题添加到jQueryUI themeswitcher?_Jquery Ui_Themes - Fatal编程技术网

Jquery ui 如何将自定义主题添加到jQueryUI themeswitcher?

Jquery ui 如何将自定义主题添加到jQueryUI themeswitcher?,jquery-ui,themes,Jquery Ui,Themes,在这里: 我在我的页面上找到了一个很好的小部件来切换动态jQueryUI主题。 我还创建了自己的自定义主题。如何将其添加到主题列表中?我使用了与您相同的解决方案…从下载js,将其保存为jquery.themeswitcher.js,并将所有http jquery ui URL替换为google API https URL 唯一的变化是在var switcherpane中,每个链接看起来像: <li><a href= "http://jqueryui.com/themerolle

在这里: 我在我的页面上找到了一个很好的小部件来切换动态jQueryUI主题。
我还创建了自己的自定义主题。如何将其添加到主题列表中?

我使用了与您相同的解决方案…从下载js,将其保存为jquery.themeswitcher.js,并将所有http jquery ui URL替换为google API https URL

唯一的变化是在var switcherpane中,每个链接看起来像:

<li><a href=
"http://jqueryui.com/themeroller/css/parseTheme.css.php?....">
<img src=
"http://jqueryui.com/themeroller/images/themeGallery/theme_90_ui_dark.png" alt=
"UI Darkness" title="UI Darkness" /> <span class="themeName">UI
darkness</span></a></li>
我将其替换为:

<li><a href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.23/themes/ui-lightness/jquery-ui.css">
<img src="content/images/theme_90_ui_light.png" alt="UI Lightness" title=
"UI Lightness" /><span class="themeName">UI lightness</span></a></li>
您可以在var switcherpane中将自定义图像添加为

如果在文件中搜索,则会有一些其他html图像被进一步引用


就合法性而言,我不太确定,但我不明白为什么你不能这么做,因为jQuery UI是免费的,开源的。

我找到了一些解决方案:从中保存.js文件并对其进行编辑。.添加了我的主题属性。然后它就出现了。。但我不知道这是否合法?如果我保存并使用了他们的javascript文件,并从我的主机加载了该文件。。你怎么看?我也这么想。这是一种恼人的主题切换没有这个开箱即用