AiD AiD - 2 months ago 12
PHP Question

Move and rename picture with Intervention/image module

I'm using 'Intervention/image' module , have two folders , i want to move and rename image .

public/temp/image1.png
to
public/my-folder/my-image.png

Answer

Run simply php rename function

rename("/public/temp/image1.png", "/public/my-folder/my-image.png");

php rename manual

Comments