Sep 24
Marc Pinnell L9: File Listing
Sep 24, 2014; 13:42
Marc Pinnell
L9: File Listing
Working on converting a site from 8 to 9 and modernize the code as much as possible as I go. Hit a page that shows a list of word docs and PDFs in a folder that can be clicked on and downloaded. The following L8 code will not run in 9. I believe the culprit is the "file_listdirectory" tag. The tag that I think I need in L9 (dir->forEachEntry), only returns the first 10 results and in the wrong order. Any help in converting this to L9 is appreciated!
var('files' = file_listdirectory('/_images/_userfiles/File/'));
$files->removeall('.DS_Store');
$files->removeall('Thumbs.db');
$files->removeall('tmp/');
$files->removeall('_notes/');
//$files->foreach({params->first = (pair: (date: (file_moddate: '/_images/Forms/'params->first))->format('%m-%d-%Y') = params->first); return: true;});
$files->foreach({params->first = (pair: (date: (file_moddate: '/_images/_userfiles/File/'params->first))->format('%Q') = params->first); return: true;});
$files->removeall('0000-01-01 00:00:00');
$files->sort(false);
iterate($files, var('file'));
'<p><a href="/_images/_userfiles/File/'$file->second'">'$file->second + ' (Posted: ' date($file->first)->format('%m-%d-%Y') + ')</a>';
if(31 > (date_difference(date, date($file->first), -Day)));
'<span style="color: red;"> << New</span>';
/if;
'</p><p> </p>';
/iterate;
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com
#############################################################
Attend the Lasso Developer Conference 2014!
October 1-3, 2014 at Treefrog HQ, Newmarket, Ontario, Canada
http://www.lassosoft.com/LDC-newmarket-2014
#############################################################
This message is sent to you because you are subscribed to
the mailing list Lasso Lasso@lists.lassosoft.com
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <Lasso-unsubscribe@lists.lassosoft.com>
Send administrative queries to <Lasso-request@lists.lassosoft.com>
Sep 24
Steve Piercy - Website Builder Re: L9: File Listing
Sep 24, 2014; 14:02
Steve Piercy - Website Builder
Re: L9: File Listing
Sep 24
Steve Piercy - Website Builder Re: L9: File Listing
Sep 24, 2014; 14:04
Steve Piercy - Website Builder
Re: L9: File Listing
Sep 24
Jolle Carlestam Re: L9: File Listing
Sep 24, 2014; 23:07
Jolle Carlestam
Re: L9: File Listing
Sep 24
Marc Pinnell Re: L9: File Listing
Sep 24, 2014; 15:02
Marc Pinnell
Re: L9: File Listing
Sep 24
Marc Pinnell Re: L9: File Listing
Sep 24, 2014; 16:22
Marc Pinnell
Re: L9: File Listing
Sep 24
Steve Piercy - Website Builder Re: L9: File Listing
Sep 24, 2014; 17:01
Steve Piercy - Website Builder
Re: L9: File Listing
Sep 24
Marc Pinnell Re: L9: File Listing
Sep 24, 2014; 20:24
Marc Pinnell
Re: L9: File Listing
Sep 25
Ke Carlton Re: L9: File Listing
Sep 25, 2014; 15:29
Ke Carlton
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 09:47
Brad Lindsay
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 09:19
Marc Pinnell
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 13:36
Brad Lindsay
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 10:39
Marc Pinnell
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 13:45
Brad Lindsay
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 10:55
Marc Pinnell
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 11:01
Marc Pinnell
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 14:05
Brad Lindsay
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 14:06
Brad Lindsay
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 11:10
Marc Pinnell
Re: L9: File Listing
Sep 25
Marc Pinnell Re: L9: File Listing
Sep 25, 2014; 11:10
Marc Pinnell
Re: L9: File Listing
Sep 25
Brad Lindsay Re: L9: File Listing
Sep 25, 2014; 14:21
Brad Lindsay
Re: L9: File Listing
Sep 25
Steve Piercy - Website Builder Re: L9: File Listing
Sep 25, 2014; 14:32
Steve Piercy - Website Builder
Re: L9: File Listing