CodeCharge Studio
search Register Login  

Web Reports

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

YesSoftware Forums -> CodeCharge Studio -> PHP

 CCGetUserLogin

Print topic Send  topic

Author Message
Stephen Martin
Posted: 04/07/2004, 12:20 PM

Hello,
I am attempting to set a component with a value derived from

CCGetUserLogin()

using PHP,

CCGetUserLogin() returns an empty string?

<CODE>
//Custom Code @7-DBA303E4
// -------------------------
global $Header;
// Write your own code here.
// This code will init the component with the current logged in User.

$Header->loggedin->SetText(CCGetUserLogin());

// -------------------------
//End Custom Code
</CODE>

Basically I want to display ithe header the currently logged in user. Am I using the right function?

Can this information be gleaned in amore reliable way?

Thanks Stephen
peterr


Posts: 5971
Posted: 04/07/2004, 12:31 PM

I don't use PHP regularly but couldn't find "SetText" in our Help file. I believe that it should be "SetValue". Especially based on examples like these: http://docs.codecharge.com/studio/html/ProgrammingTechn...ntrolValue.html
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message
p3ptools

Posts: 19
Posted: 04/07/2004, 1:33 PM

Hello,
I made the amendment that you suggested but to no avail.

It appears that the

CCGetUserLogin() function is just not returning any valid
data?

I tried echo'ing out a few debug strings to see what this function is doing
but each time it was an empty string.

Stephen
_________________
Sometimes the complaints will be false...
View profile  Send private message
peterr


Posts: 5971
Posted: 04/07/2004, 2:28 PM

Looks like no one is logged in. Do you have any indications that you're logged in? Possibly try accessing any restricted page to see if it redirects you to the login page.
Also, which event are you using?
Possibly try echo'ing a static string like "abc" to see if it even will work.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message
p3ptools

Posts: 19
Posted: 04/07/2004, 2:48 PM

Hello,
thanks.. that has picked up an issue of logging in!

I thought a login process had been built by the wizard.. but I will have to check that.

Stephen
_________________
Sometimes the complaints will be false...
View profile  Send private message
peterr


Posts: 5971
Posted: 04/07/2004, 2:51 PM

Well, even if the wizard built the login, the application doesn't know who you are until you actually perform the login on your Website. Therefore CCGetUserLogin() can work only after you (or the user) go to the login page and login successfully. It will then return the ID of the user.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message

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.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


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