I am trying to use Google to download jQuery for some pages and the jQuery user interface for others. On pages where I just need jQuery, I do the following:
<script src="http://www.google.com/jsapi"></script> <script type="text/javascript"> function OnLoad() { </script>
And on pages where I need jQueryUI, I also add the following:
<link rel="stylesheet" type="text/css" href="/Library/jQuery/UI/Smoothness/css/smoothness/jquery-ui-1.7.2.custom.css"> <script type="text/javascript"> function OnLoadUI(){ $('div.tabs').tabs(); $('input.date').datepicker(); } google.load("jqueryui", "1"); google.setOnLoadCallback(OnLoadUI); </script>
Q: Am I doing something wrong? This works, but I want to know if I am writing code that does not make sense. Q: Does Google have various css themes for the user interface? Or am I right in thinking that I need to cater for the topic of smoothness myself? (This is not a special topic - it's just the default).
jquery
Phillip senn
source share