From: Robert Dober Date: 2007-08-13T08:18:35+09:00 Subject: Re: Removing file names with '.' in their names from list? On 8/12/07, Sfdesigner Sfdesigner wrote: > Currently I'm using this code to output a list of files to a .rhtml > page: > > <% > Dir.foreach("/") do |file| > next if File.fnmatch('*.*', file) I would suggest next if /\./ === file > puts '' + file + '' > end > %> > HTH Robert -- [...] as simple as possible, but no simpler. -- Attributed to Albert Einstein