Topic awaiting preservation: PHP and SSI (Page 1 of 1) |
|
---|---|
Maniac (V) Inmate From: there...no..there..... |
posted 05-13-2003 19:36
Hi all. I know I probably bug the hell out of you all with these questions but I have fought with this for quite some time. Here is what I have. code: <form method="POST" action="posts.php">
code: <?
|
Paranoid (IV) Mad Scientist with Finglongers From: Germany |
posted 05-13-2003 20:01
with out reading any of your code, just you comment... check out fopen() and fputthrough() (and fread() and fclose() as well). that should get you started. |
Maniac (V) Mad Scientist with Finglongers From: Cell 53, East Wing |
posted 05-13-2003 20:04
CPrompt: quote:
|
Paranoid (IV) Mad Scientist with Finglongers From: Germany |
posted 05-13-2003 22:22
if you want to get the output of an included file into a variable, code: foreach ($listOfFiles as $aFile)
|
Maniac (V) Inmate From: there...no..there..... |
posted 05-14-2003 00:25
OK, well. . . I didn't think that my post was that cryptic but then again I wrote it |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 05-14-2003 00:48
I get it. (I think) code: while ($file_name = readdir($dir)) {
code: while ($file_name = readdir($dir)) {
code: $file_list = array()
code: foreach ($file_list as $var) include($var); // shorthand loop
|
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 05-14-2003 00:51
In another note I don't think you want to escape the dollar sign in your regular expression. Without testing it I'm pretty sure that you are killing it's regexp meaning (dat at the end if the file name) and instead making your regular look literally 'dat$' what you probably want is |
Maniac (V) Inmate From: there...no..there..... |
posted 05-14-2003 00:55
yep you got it Bit. That is what I am trying to do. Might not be the best way to do it but I am learning |
Maniac (V) Inmate From: there...no..there..... |
posted 05-14-2003 04:02
actually bit, your first post is what I was trying to do. I guess I was on the right track but not quite there I am going to test the other just to see the outcome of them. |