Jump to content

Ignoring Parts Of An Array.


shadowayex

Recommended Posts

Well, I use glob() to find files for a file access system I'm using. I use a Debian distribution for my server and it makes backup files of each one of my files. The glob() finds these so the array has a regular file, then a back up file ending in a tilde (~). For example, it could have:files[0] filename.php -> files[1] filename.php~Or something along those lines. I want to know how I can have PHP delete and/or ignore the files with a tilde (~) . I figured a regular expression of some kind to do it, but I don't know which or anything. Any ideas?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...