Dodekus Posted August 16, 2008 Share Posted August 16, 2008 Hello everyone. I would like to make a PHP code that reads all the swf-files and jpg-files from a map, and make links of the images and the swf-file names. I hope you guys understand what I mean. It's a bit hard to explain. Ask anything if you dont undestand. Link to comment https://forums.phpfreaks.com/topic/119963-solved-make-links-to-swf/ Share on other sites More sharing options...
ignace Posted August 16, 2008 Share Posted August 16, 2008 I would like to make a PHP code that reads all the swf-files and jpg-files from a map well you have got my support! Link to comment https://forums.phpfreaks.com/topic/119963-solved-make-links-to-swf/#findComment-617977 Share on other sites More sharing options...
Dodekus Posted August 16, 2008 Author Share Posted August 16, 2008 Ok, lets make it easier. I can personally make tha last part. I would like a php-code to make links to all swf files in a map. Link to comment https://forums.phpfreaks.com/topic/119963-solved-make-links-to-swf/#findComment-617980 Share on other sites More sharing options...
ignace Posted August 16, 2008 Share Posted August 16, 2008 here hope this helps <?php $dh =@ opendir($directory); if ($dh) { while ($file = readdir($dh)) { if ($file != "." && $file != "..") { $fileInfo = pathinfo($directory . DIRECTORY_SEPARATOR . $file); if ($fileInfo["extension"] === "swf") { echo "<a href='" . $httpPathToDirectory . "/" . $file . "'>" . $file . "</a><br />\n"; } } } } Link to comment https://forums.phpfreaks.com/topic/119963-solved-make-links-to-swf/#findComment-618122 Share on other sites More sharing options...
Dodekus Posted August 17, 2008 Author Share Posted August 17, 2008 Thank you really much. This solved my problem. Topic Solved! Link to comment https://forums.phpfreaks.com/topic/119963-solved-make-links-to-swf/#findComment-618390 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.