Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 01-30-2003, 10:29 AM   #1
snowball179
Confirmed User
 
Join Date: Dec 2002
Posts: 261
Directory listing script?

I need a script that will scan on a webserver for all the sub-directories on a given directory, and will write itMs path in a *.txt file.

Does anyone knows any?
snowball179 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-30-2003, 11:25 AM   #2
snowball179
Confirmed User
 
Join Date: Dec 2002
Posts: 261
anyone knows any?
snowball179 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-30-2003, 12:28 PM   #3
FuqALot
Confirmed User
 
Join Date: Dec 2001
Location: Malibu
Posts: 3,817
Here you go.

#!/usr/bin/perl
@dir = (`du`);
open (list,">list.txt");
foreach (@dir) { print list; }
close(list);

put in a file and drop it in your starting directory
launch with: perl file, through ssh or whatever :-P.
FuqALot is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-30-2003, 02:05 PM   #4
snowball179
Confirmed User
 
Join Date: Dec 2002
Posts: 261
I need to put this perl file in a *.pl or *.chgi file, in the category I want it to list....with a *.txt file that I chmod to 777, right?

The problem is that I cannot put perl files outside the cgi-bin directory...
snowball179 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-30-2003, 02:43 PM   #5
FuqALot
Confirmed User
 
Join Date: Dec 2001
Location: Malibu
Posts: 3,817
If you run this through ssh or telnet then it doesn't matter wether you name it .pl .cgi. or whatever, you should just put it in a file and then put the file in a starting directory, and make sure the script can create a file in that starting directory, and then type: 'perl file.pl', without the quotes, list.txt will then be created with the directories and stuff.
FuqALot is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-30-2003, 03:11 PM   #6
snowball179
Confirmed User
 
Join Date: Dec 2002
Posts: 261
can I load it with IE?
I cannot connect to that server with ssh right now, and my tech is not here.
snowball179 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.