unlink alternatives
Hi, I need for a file to be deleted from server soon after its created. I have heard that unlink is a dangerous thing to do. What's a better alternative? Thanks
Get your free Flash Contact Forms for your website.
Coming soon: Flash Attachment Email
GDVS posted this at 10:15 — 1st April 2006.
They have: 36 posts
Joined: Mar 2006
Unlink is only dangerous if you're not careful about what you're doing. Don't allow any way for users to specify what's being deleted and you're fine.
timjpriebe posted this at 12:28 — 3rd April 2006.
He has: 2,667 posts
Joined: Dec 2004
Agreed. I use unlink, no problem. But I never allow users to specify what's being deleted. Just program smart, and you'll have no problem.
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.