Page 1 of 1

show only content for that member

Posted: Sat Oct 31, 2009 6:30 pm
by DonnaNJ
I'm creating a member only area where client can go in and create a profile - and then fill out a questionnaire. (may be more than only form for each user).

Then visitors can search information and pull back all the details if they are interested.

However - I want the client to go in and be able to edit /change or delete their questionnaire.  So after they log in and want them to only see their questionnairs - and be able to edit them - but not anyone elses.

I know how to create member areas with FEU and Custom Content... but how do I make the customcontent show only the logged in users forms ?

So each Content page will be different based on the login - but I don't want 100's of pages ?

I hope this is clear - but it's hard to describe.

thanks

DonnaNJ

Re: show only content for that member

Posted: Sat Oct 31, 2009 7:01 pm
by jmcgin51
I don't know what you're using to generate the form(s), but let's say you're using a CMSMS module.  Your logic would look something like this:

IF user is logged in and authorized to see this content
  {cms_module module="whatever" form="profile_for_$ccuser->username()"
ELSE
  sorry, you can't see this
END IF

Your forms, then, will need to be named according to the username of the user (i.e. "profile_for_user1")

BTW, I'm sure the code above is not syntactically correct.  It's just to get you started with the logic.

There are probably other ways to do this; this is just the one that came to mind first.