CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Help ! Need to Hide fields

Print topic Send  topic

Author Message
Lorenz
Posted: 05/13/2002, 8:33 AM

Please, i need to hide fields previously declared "label" , if they don't contain valours. They eventually assumes data in "Before show" event, after all operations I decide if "Field captions TD" must be canceled from the page.
I read other discussions, but i didn't understand. I'M NOT AN EXPERT!:(
I use PHP4 with templates.
THANK YOU TO ALL , YOU'RE GREAT!
Special THANKS to Alexey Alexapolsky.
Nicole
Posted: 05/14/2002, 5:13 AM

Lorenz,
Hm.. the solution depends on pattern you use, Grid type and your own preferences.
Here are some approaches.
1. The easiest way is to assign empty value to field and still display its caption. To do it just place the code like below to Before Show event:
if (condition_to_hide)
$fldfield_name = "";

2. of course you can hide field and its caption. It is more complex and depends on Grid type. I want to say that solution will be more elegant with templatless pattern because it allows edit html code within CC project. With template one you should edit .html file.
Again, solution for Columnar grid form is easier and could be implemented without much coding in both php and php+templates pattern.

3.Solution for Tabular grid could be implemented in templatless pattern only (for my opinion). And one clarification is need here. Do you think that whole column is to be hidden if at least one field in this columns should be hidden.

Let me know what do you think about each approach.
Lorenz
Posted: 05/14/2002, 11:29 PM

Thank you very much for your response, sorry but i didn't explain well.
I need to hide field an its caption, as you spoke about approach 2, but I prefered not to edit html code. But if it's the only way, I'll do it. :)
Can you tell me what you mean in approach 3? Was it a solution by editing html too? :)
Thank you again. I'm happy you response me because your messages with other people helped me much in the past.:)
Donna
Posted: 05/15/2002, 6:27 AM

Hi, Nicole,
I'm trying to do the same thing and number two describes my form. (you can hide field and its caption: solution for Columnar grid form is easier and could be implemented without much coding in both php and php+templates pattern)

I'm using php w. templates. Could you please tell me what code to use and where to place it?


Thanks!

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.