You're right about the relative .files. The thumbnail issue is because the GET_PARAMS are not implemented everywhere.
To solve your problem I think only the j/file.class.js has to be modified. I did a full search on get.php to solve further future issues on this one (included in the diff)
The diff of the fix is:
Index: plugins/lightbox/plugin.js
===================================================================
--- plugins/lightbox/plugin.js (revision 1007)
+++ plugins/lightbox/plugin.js (working copy)
@@ -60,7 +60,7 @@
wrapper.appendChild(el);
}
if(oldEl)$j(oldEl).remove();
- var w=data.width,h=data.height,url='get.php?id='+id,r=0;
+ var w=data.width,h=data.height,url='get.php?id='+id+kfm_vars.get_params,r=0;
if(!w||!h)return kfm_img_stopLightbox();
if(w>ws.x*.9||h>ws.y*.9){
if(w>ws.x*.9){
Index: plugins/cropper/croparea.php
===================================================================
--- plugins/cropper/croparea.php (revision 1007)
+++ plugins/cropper/croparea.php (working copy)
@@ -31,6 +31,6 @@
</style>
</head>
<body>
-<img src="<?php echo preg_replace('#plugins/cropper.*#','',$_SERVER['REQUEST_URI']); ?>get.php?id=<?php print $_GET['id'].'&'.rand(1,500);?>" alt="Crop image" id="cropImage" width="<?php print $_GET['width'];?>" height="<?php print $_GET['height'];?>" />
+<img src="<?php echo preg_replace('#plugins/cropper.*#','',$_SERVER['REQUEST_URI']); ?>get.php?id=<?php print $_GET['id'].'&'.rand(1,500).GET_PARAMS;?>" alt="Crop image" id="cropImage" width="<?php print $_GET['width'];?>" height="<?php print $_GET['height'];?>" />
</body>
</html>
Index: j/file.class.js
===================================================================
--- j/file.class.js (revision 1007)
+++ j/file.class.js (working copy)
@@ -48,7 +48,7 @@
}
}
// sprite doesn't exist, or image is not in a CSS sprite
- el.style.background='url(get.php?id='+id+'&width=64&height=64) center top no-repeat';
+ el.style.background='url(get.php?id='+id+'&width=64&height=64'+kfm_vars.get_params+') center top no-repeat';
}
File.prototype.iterateThumbnailQueue=function(){
if(!File_ThumbnailsQueue.length){
@@ -57,7 +57,7 @@
}
var el=window.File_ThumbnailsQueue[0][0],id=window.File_ThumbnailsQueue[0][1];
if(el && el.parentNode && el.parentNode.id=='documents_body'){
- var url='get.php?id='+id+'&width=64&height=64&get_params='+kfm_vars.get_params;
+ var url='get.php?id='+id+'&width=64&height=64'+kfm_vars.get_params;
var img=document.createElement('img');
img.src=url;
img.style.width=1;
Index: j/functions/kfm_downloadSelectedFiles_addIframe.js
===================================================================
--- j/functions/kfm_downloadSelectedFiles_addIframe.js (revision 1007)
+++ j/functions/kfm_downloadSelectedFiles_addIframe.js (working copy)
@@ -1,5 +1,5 @@
window.kfm_downloadSelectedFiles_addIframe=function(wrapper,id){
var iframe=document.createElement('iframe');
- iframe.src='get.php?id='+id+'&forcedownload=1';
+ iframe.src='get.php?id='+id+'&forcedownload=1'+kfm_vars.get_params;
kfm.addEl(wrapper,iframe);
}