PDA

View Full Version : help with vb, very simple question for expert!


12-12-2000, 03:19 AM
I want to call the script call news from /forum
how would I do this? I've got this so far:
<?php

require("news.php");

?>
but I want to put that line of code in my home dir. not /forum. Any ideas?

12-12-2000, 04:52 AM
require("forum/news.php");

I think that should do the trick :)

12-12-2000, 07:23 AM
no, now it says:

Warning: Failed opening 'global.php3' for inclusion in forums/news.php3 on line 5

Fatal error: Failed opening required 'bfc.php3' in forums/news.php3 on line 6

12-12-2000, 07:28 AM
k, nevermind, fixed that by using absolute urls in the news.php3 file... but now all it does it leave the page blank where it should be calling news.php3... i checked the source and it's gone, so something's happened. also, how do i get it parse the file for SSI at the same time? now that's not working either!

12-12-2000, 03:31 PM
You shouldn't need to use both SSI and PHP include functions in the same file - they do exactly the same thing.
Sounds like the path to news.php3 or the filename is wrong - try changing the "require" to "include" - that might come up with an error giving you more information.
Check paths and filenames, that should fix your problem.

12-12-2000, 08:21 PM
Ok... so I have to take my insert files that I was calling with SSI and make them into VB templates and call them that way?

12-13-2000, 04:57 AM
No, all you have to do is replace all your SSI calls with require() calls like the ones above - they perform the same function.