aakici
Posts: 49
|
| Posted: 01/23/2005, 4:54 AM |
|
I write some codes for general use of me. For example; format numbers, get some money conversions, etc. I use them almost every page i wrote. I write include pages and include them in php pages. But, i can't do this for html codes. How can i use include pages in html pages?
_________________
Regards,
M.Alpaslan AKICI |
 |
 |
mrachow
Posts: 509
|
| Posted: 01/23/2005, 9:56 AM |
|
In Toolbox on tab Forms there is an template Include Page.
Mostly this feature is used to include header and footer pages/page parts.
_________________
Best regards,
Michael |
 |
 |
peterr
Posts: 5971
|
| Posted: 01/23/2005, 11:07 AM |
|
You cannot include CCS pages in non-CCS HTML pages. However, you can create a CCS page based on your HTML.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
aakici
Posts: 49
|
| Posted: 01/23/2005, 12:17 PM |
|
I don't know if it is possible. Hovewer, i know different use of include pages is maintained other programming languages, for example, pascal, vb, delphi (units). I think there must be a way.
_________________
Regards,
M.Alpaslan AKICI |
 |
 |
peterr
Posts: 5971
|
| Posted: 01/23/2005, 12:45 PM |
|
This really depends on the situation & approach. Not every Delphi program can be included in other non-Delphi program. Otherwise why people would need to create Delphi or ActiveX components?
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
aakici
Posts: 49
|
| Posted: 01/23/2005, 12:55 PM |
|
I don't mean that. I can't wish delphi programs can be included in other non-delphi program. The situastion i tried to explain is including a html code without rewriting it in other html page. You can include a DElphi program (called unit.) in other Delphi program.
_________________
Regards,
M.Alpaslan AKICI |
 |
 |
aakici
Posts: 49
|
| Posted: 01/23/2005, 12:56 PM |
|
And as you know, you can include a php page in another php page. this is what i meant.
_________________
Regards,
M.Alpaslan AKICI |
 |
 |
Matt
|
| Posted: 02/18/2005, 7:12 AM |
|
I think the easiest way to do it in html is to use the embed tags, I'm looking for an easier way at the moment myself. I hope you found it already since no one has written here for like a month
|
|
|
 |
feha
Posts: 712
|
| Posted: 02/20/2005, 1:05 AM |
|
You must use functions
and functions has to return your HTML in the string.
In before show event you can call your function and set result in to HTML label within an include page.
function test()
{
$test="<strong>Hello World!";
return $test;
}
$somegrid->$some label->SetValue(test());
_________________
Regards
feha
www.vision.to
feedpixel.com |
 |
 |
jeverhart
|
| Posted: 02/23/2005, 2:47 PM |
|
Not sure if I quite understand the question, but for sure we include non-CCS items inside of CCS pages all the time. Just create the non-CCS HTML file (for example, "footer.inc"). Then in the Common.php we add this little function:
function include_file($template_variable_name, $path_and_file){
global $Tpl;
$path_and_file = realpath($path_and_file);
$Tpl->SetVar("$template_variable_name", join('',file($path_and_file)));
}
Then for your CCS page in a Before Show event, add the code:
global $Tpl;
include_file("myfooter", "../includes/footer.inc") // put your actual path and file name here
$Tpl->SetVar("myfooter");
Finally, in your HTML, add this template variable where you want the file included:
{myfooter}
We do this on all our projects with no problems
|
|
|
 |