CodeCharge Studio
search Register Login  

Web Reports

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

YesSoftware Forums -> Archive -> GotoCode Archive

 Update records for only the login user.

Print topic Send  topic

Author Message
Peter
Posted: 08/01/2002, 1:56 AM

Hi all

Page Created
============
I have 2 pages. One that the login user can view his own records and able to update his records only.

The other page is a search page, where he can view everyone else's records too. The problem lies here. I want him to be able to view all the records but only able to edit his own entries. How do I do it?

I have read that someone posted the solution that the login is is to be captured and be compared to the current login id session. The problem is how do it do that?

Thank you for your reply.
NR
Posted: 08/01/2002, 7:17 AM

If you are using CCS you have the user login in the session variable UserLogin.
I've done something similar for myself.

I've placed a special link in the entry page to a page where the user can update only is own record.
This second page is restricted and requires user to login. Than in this page I've changed the Initialize() function
to look like this:

Where there was... $this->ds->Parameters["urlid]" = CCGetFromGet("id","");
Now there is... $this->ds->Parameters["urlid]" = CCGetFromGet("id",CCGetUserID());

This will pass is own userID as a parameter to the form so the form will only show is own record.
Notice that the entry page provides a login entry point but is not the Login page.
There is a separate page that is the default application login, called whenever new authorization is required.

   


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.