My static website generator using poole https://www.xythobuz.de
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

yoxview-init.js 1.1KB

12345678910111213141516171819202122232425262728293031323334
  1. var yoxviewPath = getYoxviewPath();
  2. var cssLink = top.document.createElement("link");
  3. cssLink.setAttribute("rel", "Stylesheet");
  4. cssLink.setAttribute("type", "text/css");
  5. cssLink.setAttribute("href", yoxviewPath + "yoxview.css");
  6. top.document.getElementsByTagName("head")[0].appendChild(cssLink);
  7. function LoadScript(url)
  8. {
  9. document.write( '<scr' + 'ipt type="text/javascript" src="' + url + '"><\/scr' + 'ipt>' ) ;
  10. }
  11. var jQueryIsLoaded = typeof jQuery != "undefined";
  12. if (!jQueryIsLoaded)
  13. LoadScript("http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js");
  14. LoadScript(yoxviewPath + "jquery.yoxview-2.21.min.js");
  15. function getYoxviewPath()
  16. {
  17. var scripts = document.getElementsByTagName("script");
  18. var regex = /(.*\/)yoxview-init/i;
  19. for(var i=0; i<scripts.length; i++)
  20. {
  21. var currentScriptSrc = scripts[i].src;
  22. if (currentScriptSrc.match(regex))
  23. return currentScriptSrc.match(regex)[1];
  24. }
  25. return null;
  26. }
  27. // Remove the next line's comment to apply yoxview without knowing jQuery to all containers with class 'yoxview':
  28. LoadScript(yoxviewPath + "yoxview-nojquery.js");