<svg xmlns="http://www.w3.org/2000/svg" version="1.1" class="svg-filters">
<defs>
<filter id="filter-ripple-1">
<feImage xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="img/ripple.png" x="-204" y="-280" width="600" height="600" result="ripple"></feImage>
<feDisplacementMap xChannelSelector="R" yChannelSelector="G" color-interpolation-filters="sRGB" in="SourceGraphic" in2="ripple" scale="0" result="dm"></feDisplacementMap>
<feComposite operator="in" in2="ripple"></feComposite>
<feComposite in2="SourceGraphic"></feComposite>
</filter>
</defs>
</svg>
.btn.filter {
-webkit-filter: url(#filter-ripple-1);
filter: url(#filter-ripple-1);
}
$(".btn").click(function(e){
var turb = document.querySelectorAll('#filter-ripple-1 feImage')[0];
var dm = document.querySelectorAll('#filter-ripple-1 feDisplacementMap')[0];
$(".btn").removeClass("filter");
$(this).addClass("filter");
TweenLite.set(turb, { attr: { x: e.offsetX, y: e.offsetY, width: 0, height: 0 } });
TweenLite.to(turb, 3, { attr: { x: '-=300', y: '-=300', width: 600, height: 600 } });
TweenLite.fromTo(dm, 2, { attr: { scale: 30 } }, { attr: { scale: 0 } });
});
DocumentRoot "C:/xampp2/htdocs"
<Directory "C:/xampp2/htdocs">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Require all granted
</Directory>
C:/xampp2/htdocs/index.php
C:/xampp2/htdocs/img/
C:/xampp2/htdocs/tmp/img/cat-with-shoes.jpg
<?php
$temp_location = 'tmp/img/cat-with-shoes.jpg';
$target_location = 'img/cat-with-shoes.jpg';
echo "Temp location - \"" . $temp_location . "\"<br>";
echo "Target location - \"" . $target_location . "\"<br>";
if (copy( $temp_location, $target_location )) {
echo "File \"" . $temp_location . "\" is copied<br>";
if (unlink( $temp_location )) {
echo "File \"" . $temp_location . "\" is deleted<br>";
if (file_exists( $target_location )) {
echo "File \"" . $target_location . "\" exists<br>";
} else {
echo "File \"" . $target_location . "\" does not exist<br>";
}
} else {
echo "Error during an attemp to delete file \"" . $temp_location . "\"<br>";
}
} else {
echo "Error during an attemp to copy file \"" . $temp_location . "\"<br>";
}
C:/xampp2/htdocs/index.php
C:/xampp2/htdocs/img/cat-with-shoes.jpg
C:/xampp2/htdocs/tmp/img/
Temp location - "tmp/img/cat-with-shoes.jpg"
Target location - "img/cat-with-shoes.jpg"
File "tmp/img/cat-with-shoes.jpg" is copied
File "tmp/img/cat-with-shoes.jpg" is deleted
File "img/cat-with-shoes.jpg" exists
Попробуйте почитать в гугле вопросы/статейки по запросу "php windows relative path doesn't work", там некоторые советуют всякие хитрые функции, может поможет.