GreeceMonkey
04-03-2007, 07:19 PM
Hello People,
I am not any good at all with PHP, and am trying to find a good way for me to create a dyanmic advertising system.
I would like to be able to create static page containing the code for each advert
so I may have
/adverts/1.htm
/adverts/3.htm
to provide the content to foums 1 and 3. I will always have a file for all my forums, so I dont need any exceptions writen in the code.
just how do I write include /advert/{fourmid}.htm in the sections of the templates I want to display adverts
I did find some threads but I could not make it work, as it was not exactly what i was looking for
Kind Regards
Graham Mattingley
Hi Sorry to bump this already. I have found this code, and am going to try it. I know very little about PHP script. Does the blow script mean I need to create a ob_start for every possible file that could be called by the requirestatement.
How to I refer to the contents of the file as a varable, is the varable name $fieldnote
// get htm file to include at the top of the thread:
ob_start();
require("../fielddoc/1/1.htm");
$fieldnote = ob_get_contents();
ob_end_clean();
require("../fielddoc/1/".$threadid.".htm");
Graham
Hi Sorry to bump this already. I have found this code, and am going to try it. I know very little about PHP script. Does the blow script mean I need to create a ob_start for every possible file that could be called by the requirestatement.
How to I refer to the contents of the file as a varable, is the varable name $fieldnote
// get htm file to include at the top of the thread:
ob_start();
require("../fielddoc/1/1.htm");
$fieldnote = ob_get_contents();
ob_end_clean();
require("../fielddoc/1/".$threadid.".htm");
I am not any good at all with PHP, and am trying to find a good way for me to create a dyanmic advertising system.
I would like to be able to create static page containing the code for each advert
so I may have
/adverts/1.htm
/adverts/3.htm
to provide the content to foums 1 and 3. I will always have a file for all my forums, so I dont need any exceptions writen in the code.
just how do I write include /advert/{fourmid}.htm in the sections of the templates I want to display adverts
I did find some threads but I could not make it work, as it was not exactly what i was looking for
Kind Regards
Graham Mattingley
Hi Sorry to bump this already. I have found this code, and am going to try it. I know very little about PHP script. Does the blow script mean I need to create a ob_start for every possible file that could be called by the requirestatement.
How to I refer to the contents of the file as a varable, is the varable name $fieldnote
// get htm file to include at the top of the thread:
ob_start();
require("../fielddoc/1/1.htm");
$fieldnote = ob_get_contents();
ob_end_clean();
require("../fielddoc/1/".$threadid.".htm");
Graham
Hi Sorry to bump this already. I have found this code, and am going to try it. I know very little about PHP script. Does the blow script mean I need to create a ob_start for every possible file that could be called by the requirestatement.
How to I refer to the contents of the file as a varable, is the varable name $fieldnote
// get htm file to include at the top of the thread:
ob_start();
require("../fielddoc/1/1.htm");
$fieldnote = ob_get_contents();
ob_end_clean();
require("../fielddoc/1/".$threadid.".htm");