JohnK
|
| Posted: 01/09/2005, 11:47 AM |
|
I have included a label somewhere in my css page.
In a before show event i include custom html and it works fine in the position where i have put the label.
When i insert custom php code it works too but it shows it only in the beggining of the page. for example i insert the code
include ("test.php");
or
print ("hello");
the php code works ok but i cant get it to show it in the right position of the page?
what i am doing wrong?
|
|
|
 |
peterr
Posts: 5971
|
| Posted: 01/09/2005, 2:19 PM |
|
You must assign the output to the label. Do not output/print anything directly to the page.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
JohnK
|
| Posted: 01/09/2005, 2:51 PM |
|
//CustomHTML_BeforeShow @359-882CC1B2
function CustomHTML_BeforeShow()
{
$CustomHTML_BeforeShow = true;
//End CustomHTML_BeforeShow
this is the code i use.
i am still getting the result up in the page and not in the label position.
any ideas?
//Retrieve Value for Control @360-4BD3F6EC
global $CustomHTML;
$CustomHTML->SetValue(include("poll.php"));
//End Retrieve Value for Control
//Close CustomHTML_BeforeShow @359-3C73144F
return $CustomHTML_BeforeShow;
}
//End Close CustomHTML_BeforeShow
|
|
|
 |
peterr
Posts: 5971
|
| Posted: 01/09/2005, 3:09 PM |
|
This probably cannot work because poll.php is printing something to the screen/page, outside of the HTML template.
So instead of $CustomHTML->SetValue(include("poll.php")); you would need to call some function in poll.php, return the result, and then use $CustomHTML->SetValue($result_of_poll);
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |