CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Panel Hide Show Issues

Print topic Send  topic

Author Message
will

Posts: 88
Posted: 08/31/2008, 4:02 PM

i have 2 panels on 1 include page and i 4 diffent groups

1 2 3 4

panel one I only want to show if the user group id is 1
and panel 2 i only want to show if user group is is not 1

basicly panel one should only show to users that group id is 1

and panel2 is to only show if user group Id is 2,3,4 but what ever i use it does not work
View profile  Send private message
maxhugen

Posts: 272
Posted: 08/31/2008, 8:03 PM

Are you using a BeforeShow event?

Basically, code should look something like:
  
switch (group_id) {  
    case 1:  
        Panel1->Visible = True;  
        Panel2->Visible = False;  
    default:  
        Panel1->Visible = False;  
        Panel2->Visible = True;  
}
Does this help?
_________________
Max
www.gardenloco.com | www.eipdna.com | www.chrisarminson.com
View profile  Send private message
will

Posts: 88
Posted: 08/31/2008, 9:27 PM

I have done that it does nothing
View profile  Send private message
maxhugen

Posts: 272
Posted: 08/31/2008, 9:38 PM

It might help if you post your actual code here...
_________________
Max
www.gardenloco.com | www.eipdna.com | www.chrisarminson.com
View profile  Send private message
will

Posts: 88
Posted: 08/31/2008, 9:56 PM

Panel1 beforeshow

if (!CCGetSession("auth_id")>1){
$Component->Visible = true;
} else {
$Component->Visible = false;
}

Panel2 beforeshow

if (!CCGetSession("auth_id")>1){
$Component->Visible = false;
} else {
$Component->Visible = true;
}
View profile  Send private message
datadoit
Posted: 09/01/2008, 6:07 AM

Do some basic debugging by tossing in some echo statements to make
certain your session has values as expected.

In addition, remove the conditions to make sure the panels are
showing/hiding as expected.

Add new topic Subscribe to topic   


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

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


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