navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
FrontPage Alternative
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

Automatically generate hyperlink list

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Expression Web Help >> Automatically generate hyperlink list
Page: [1]
 
Lambini

 

Posts: 32
Joined: 1/31/2007
Status: offline

 
Automatically generate hyperlink list - 10/1/2008 11:43:02   
I need to create a page that contains a list of hyperlinks that point to various documents residing in the same online directory or subdirectories. This is to aid a site search engine spider. It is not practical to add the links manually. Is there a way (some script) to automatically scan the directory/subdirs and write the links to a master page? Is this more or less a table of contents page? Is there some automation to create that?

Thanks.
coreybryant

 

Posts: 2494
Joined: 3/17/2002
From: Castle Rock CO USA
Status: offline

 
RE: Automatically generate hyperlink list - 10/1/2008 12:07:32   
So I guess you are using Expression Web?

you would need some type of database to help handle those links. There might even be some code that someone knows just to read the pages / titles from a certain folder (but they would probably need to know what your server supports (PHP, ASP, .NET, etc)) to help you out with that code. You might even check out hotscripts for something.

_____________________________

Corey R. Bryant
Merchant Accounts | Toll Free Numbers | Expression Web Blog

(in reply to Lambini)
Tailslide

 

Posts: 6294
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Automatically generate hyperlink list - 10/1/2008 13:17:12   
This does exactly that in PHP, just change the path to the required folder.:

<ul>
<?

// Define the full path to your folder from root
$path = "full/path/to/folder";

// Open the folder
$dir_handle = @opendir($path) or die("Unable to open $path");

// Loop through the files
while ($file = readdir($dir_handle)) {

if($file == "." || $file == ".." || $file == "index.php" )

continue;
echo "<li><a href=\"$file\">$file</a></li>";

}

// Close
closedir($dir_handle);

?>
</ul>



_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to coreybryant)
Page:   [1]

All Forums >> Web Development >> Expression Web Help >> Automatically generate hyperlink list
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts