Bitcoin Forum
May 28, 2024, 04:00:37 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Count files in a directory where name = and output number to a variable...  (Read 264 times)
MoreBloodWine (OP)
Legendary
*
Offline Offline

Activity: 1050
Merit: 1001


View Profile
June 13, 2015, 04:48:06 AM
Last edit: June 14, 2015, 06:23:45 AM by MoreBloodWine
 #1

This is to do with making something on my crypto site a bit easier as in the long one it will be one less thing for me to manually manage, anyway...

I need to count files in folder (path/to/me) who's names match *_lottery.inc.php where the * is a wild card since files might be named such as...

hello_lottery.inc.php
and_lottery.inc.php
goodbye_lottery.inc.php

So the output would be 3

Can someone please write a bit of PHP for me that will do this ?

Ty.


Problem solved.

To be decided...
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!