Another problem!!!
If you enter this url
<!-- m --><a class="postlink" href="http://www.karinne.net/pix/index.php?c=ddir&ddir=jeep">http://www.karinne.net/pix/index.php?c=ddir&ddir=jeep</a><!-- m -->
You should get is stock-flex since that's the folder that's inside jeep (&ddir=jeep)
Here's the if statement
if ($_GET['c'] = 'ddir') {
$ddir = $_GET['ddir'];
displaydirs($ddir);
exit;
}
And here's the function displaydirs($dirs)
function displaydirs($ddir) {
$dir = opendir("/home/karinne/pix.karinne.net/".$ddir);
$structure = array();
while($directory = readdir($dir)) {
if ($directory == '.') { continue; }
if ($directory == '..') { continue; }
if (preg_match('/\.php$/', $directory)) { continue; }
if (preg_match('/\.swp$/', $directory)) { continue; }
array_push($structure, $directory);
}
sort($structure);
for ($j=0; $j < count($structure); $j++) { ?>
<p>» <a href=http://www.htmlforums.com/archive/index.php/"/pix/index.php?c=img&ddir=<?=$ddir?>&sdir=<?=$structure[$j]?>"><?=$structure[$j]?></a></p>
<? }
closedir($dir);
}
The if statement is not grabbing anything past the & in the url?! What am I missing here?!I had to put $_SERVER['QUERY_STRING'] where I included that file! It works now! weeeeeeeeeeeeedon't know if this is the problem, but try turning
if ($_GET['c'] = 'ddir') {
into
if ($_GET['c'] == 'ddir') { o.oNo that wasn't the problem... I actually solved... hence the post above yours! Originally posted by karinne
No that wasn't the problem... I actually solved... hence the post above yours!
T____T
I had to put $_SERVER['QUERY_STRING'] where I included that file! It works not! weeeeeeeeeeeee
pointing to the 'it works not!'.... and i dind't expect you meant 'now' instead of 'not'...sinze the 't' is quite for away from the 'w' .... atleast on my keyboard ;_;Originally posted by yoda
pointing to the 'it works not!'.... and i dind't expect you meant 'now' instead of 'not'...sinze the 't' is quite for away from the 'w' .... atleast on my keyboard ;_;
Holy typo Batman!!! =:O
Sorry 'bout that yoda!
If you enter this url
<!-- m --><a class="postlink" href="http://www.karinne.net/pix/index.php?c=ddir&ddir=jeep">http://www.karinne.net/pix/index.php?c=ddir&ddir=jeep</a><!-- m -->
You should get is stock-flex since that's the folder that's inside jeep (&ddir=jeep)
Here's the if statement
if ($_GET['c'] = 'ddir') {
$ddir = $_GET['ddir'];
displaydirs($ddir);
exit;
}
And here's the function displaydirs($dirs)
function displaydirs($ddir) {
$dir = opendir("/home/karinne/pix.karinne.net/".$ddir);
$structure = array();
while($directory = readdir($dir)) {
if ($directory == '.') { continue; }
if ($directory == '..') { continue; }
if (preg_match('/\.php$/', $directory)) { continue; }
if (preg_match('/\.swp$/', $directory)) { continue; }
array_push($structure, $directory);
}
sort($structure);
for ($j=0; $j < count($structure); $j++) { ?>
<p>» <a href=http://www.htmlforums.com/archive/index.php/"/pix/index.php?c=img&ddir=<?=$ddir?>&sdir=<?=$structure[$j]?>"><?=$structure[$j]?></a></p>
<? }
closedir($dir);
}
The if statement is not grabbing anything past the & in the url?! What am I missing here?!I had to put $_SERVER['QUERY_STRING'] where I included that file! It works now! weeeeeeeeeeeeedon't know if this is the problem, but try turning
if ($_GET['c'] = 'ddir') {
into
if ($_GET['c'] == 'ddir') { o.oNo that wasn't the problem... I actually solved... hence the post above yours! Originally posted by karinne
No that wasn't the problem... I actually solved... hence the post above yours!
T____T
I had to put $_SERVER['QUERY_STRING'] where I included that file! It works not! weeeeeeeeeeeee
pointing to the 'it works not!'.... and i dind't expect you meant 'now' instead of 'not'...sinze the 't' is quite for away from the 'w' .... atleast on my keyboard ;_;Originally posted by yoda
pointing to the 'it works not!'.... and i dind't expect you meant 'now' instead of 'not'...sinze the 't' is quite for away from the 'w' .... atleast on my keyboard ;_;
Holy typo Batman!!! =:O
Sorry 'bout that yoda!