I want to create a form which can be only edited by members

Hey,

I want to create a separte form then singup … That form will only be visible to member after login. That form is the additional details . So i have created a database for additional details … and the form is connected to that database as well.

But the issue is that each member wil fill their own form and can edit it . So thats not working . I want to have that form add/edit by the member and then that data will be own by that member only .

In php its a easy job that we connect the data with id . But how to do in Covid Wix ?

Please its urgent

Hello Bilal shah,

for your project, i think you will need something like this…

 import wixUsers from 'wix-users';
 
 $w.onReady(function () {
    MEMBER_USER()
});
 
 function MEMBER_USER() {
  let USER = wixUsers.currentUser;
  let UserID = wixUsers.currentUser.id;
    console.log("USER = " + USER);
    console.log("USER-ID = " + UserID);} 

This example should give you a little help.
If you are using “Google-Chrome”, then press [F12] on your Keyboard and choose —> “Console”.
There you should find the results of that code-snipet.

Try it out.

I think the form should be handled in the dynamic page after the member login, please refer to the following:
https://support.wix.com/en/article/corvid-tutorial-building-your-own-members-area
So each member has his own form.

The members profile tutorial which Ayelung66 has linked to above would be a great starting point for you to work from.

You can change the page to whatever user inputs you want or need to have, you do not need to keep it the same as the example provided.

Please follow our forum guidelines and do not post your own issue and then bump up old threads with the same issue.
https://www.wix.com/corvid/forum/community-discussion/a-form-can-edit-from-members

https://www.wix.com/corvid/forum/community-discussion/corvid-community-guidelines
No Thread Hijacking. Don’t post about an issue and then bump other threads with your issue.

But the thing in which i face difficult is that how my form data is inserted by that user like

User A first login … click on a page there a form on that page → then we filled the form … now the data must be saved with respect to that user …

user B comes they will see an empty form and they fill fill it … then that data is used with repect to user B

This is what i want to do …

Please check my above comment … that what i need to do … tahnks

anyone to help ? please

The members profile tutorial does exactly that, read the example thoroughly and understand what it does.

You have the static page that shows your login button which can go to your Default, Custom or Corvid Login lightbox.

The user logs in and the profile button is shown to them.

The user clicks on the profile button and they will be taken to their first dynamic page which is their profile page and this is unique to each user as you use the users Id in the dynamic page url.

You can see this in the tutorial itself clearly as it tells you how to add the {ID} field in the dynamic page url.

The database which you add for this example is called Members and on the first dynamic page the dataset connector that you put on the page is set to read only as it will just show the users details.

Depending on what you collect in your signup lightbox, then this will be either just the users email address if you just used the standard email and password. Whereas, if you create your own Corvid signup lightbox then you can capture whatever user inputs you want and these will be displayed on this page when the user first views the page.

The second dynamic page, where the dataset connector will be set to read and write, is where that specific user can edit or add any details that they want on that profile page.

Once the user clicks on the save or submit button, it is all saved again into the Members dataset and the user is then taken back to the first dynamic page which then shows the alterations if any.

Both of these dynamic pages have the users unique User Id in the url for them, hence why the profile button has the current users Id in the Wix Location to() function in the profile button onClick event.