ispwebhosting4u
Posts: 17
|
Posted: 01/27/2004, 7:10 AM |
|
Dear fellow developers,
I have been searching the forum and have found several solutions to my problem, but the solutions don't seem to be working. Can someone please show me the light?
I am using CCS+PHP+MySQL
In the 'After Initialize' event for the page, I placed the following code to hide the record form.
global $page_name;
global $recordForm_name; //I'm not for sure if this is necessary, but someone had it in their solution.
$page_name->recordForm_name->Visible = false;
I have also tried:
$page_name->recordForm_name->Visible = "false";
Record is still visible.
Any suggestions would be great.
Thanks
_________________
Rick Page
PageHosting4U.com |
|
|
ispwebhosting4u
Posts: 17
|
Posted: 01/27/2004, 7:16 AM |
|
I found the solution that works.
Don't use the $page_name.
Here is my completed solution.
global $page_name;
// Write your own code here.
global $recordForm_name;
if(CCGetParam("param_id",0) == 0)
{
$recordForm_name->Visible = "false";
}
else
{
$recordForm_name->Visible="true";
}
It does not matter if there are quotes around true and false or not.
_________________
Rick Page
PageHosting4U.com |
|
|
ispwebhosting4u
Posts: 17
|
Posted: 01/27/2004, 7:18 AM |
|
Sorry, the quotes do seem to make a difference. Use them.
_________________
Rick Page
PageHosting4U.com |
|
|
peterr
Posts: 5971
|
Posted: 01/27/2004, 11:50 AM |
|
Note that you may need to use $page_name if you're working with an Includable page. Otherwise looks like you're all set.
Here is another example: http://docs.codecharge.com/studio/html/ProgrammingTechn...s/HideGrid.html
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
|
|