Jump to content

Form handling with conditions.


JustinDupre773

Recommended Posts

I've been banging my head on a wall for 30 hours over this!

 

What I am trying to do seems so simple. I have a couple of views, a profile overview type of page and an edit profile page. After verifying your account with an email link my site brings you to a blank-ish profile page and you have to follow another link from there to update your profile. It's just not as slick as I'd like it to be before launch and allows other functionality to be available before your profile has any content. I don't like it.

 

I created a specific "Create Your Profile" view that I want to include only if a user_id hasn't been included in the profilemaster table.

 

All that I have left to do is check to see if my session user_id exists in my profilemaster table and if it does include the old profile page and if it doesn't include the new "Create Your Profile" page.

 

I have tried everything over and over and then got beat up by the people at stack on top of it.

 

I need some direction.

 

I might just be tired, I've been working on the site for a solid week. All of my other functions are working, data can be inserted and updated, my emails are flowing when they need to, my log in is safe. I'm befuddled.

 

Thanks if you have any suggestions!

 

Justin

Link to comment
https://forums.phpfreaks.com/topic/286782-form-handling-with-conditions/
Share on other sites

 

 

All that I have left to do is check to see if my session user_id exists in my profilemaster table and if it does include the old profile page and if it doesn't include the new "Create Your Profile" page.

 

 1. Query the Database to determine the values needed

 2. Add a conditional statement to show which page you need to load for the user and load it

 

 I don't know if your using a Framework or if you're using modular code to create these pages so I can't really bring much to the table other than what I mentioned, I would be using templates with a MVC approach and I'd just load the content dynamically with jQuery depending on what my GET returned.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.