Advertisement
Guest User

libphotofloat.js.ie7.patch

a guest
Aug 22nd, 2012
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. --- js/010-libphotofloat.js.dist    2012-08-17 17:16:23.000000000 +0200
  2. +++ js/010-libphotofloat.js 2012-08-22 11:38:34.000000000 +0200
  3. @@ -106,7 +106,7 @@
  4.     PhotoFloat.cachePath = function(path) {
  5.         if (path === "")
  6.             return "root";
  7. -       if (path[0] === "/")
  8. +       if (path.charAt(0) === "/")
  9.             path = path.substring(1);
  10.         path = path
  11.             .replace(/ /g, "_")
  12. @@ -155,15 +155,15 @@
  13.     };
  14.     PhotoFloat.cleanHash = function(hash) {
  15.         while (hash.length) {
  16. -           if (hash[0] === "#")
  17. +           if (hash.charAt(0) === "#")
  18.                 hash = hash.substring(1);
  19. -           else if (hash[0] === "!")
  20. +           else if (hash.charAt(0) === "!")
  21.                 hash = hash.substring(1);
  22. -           else if (hash[0] === "/")
  23. +           else if (hash.charAt(0) === "/")
  24.                 hash = hash.substring(1);
  25.             else if (hash.substring(0, 3) === "%21")
  26.                 hash = hash.substring(3);
  27. -           else if (hash[hash.length - 1] === "/")
  28. +           else if (hash.charAt(hash.length - 1) === "/")
  29.                 hash = hash.substring(0, hash.length - 1);
  30.             else
  31.                 break;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement