Last post Aug 30, 2017 06:27 AM by Billy Liu
Aug 24, 2017 04:23 PM|Hnqtxe1Hn@555|LINK
We have a website for our organization, built in .Net framework 4.0, which lets different types of members to login to do relevant activities. The home page of the site should be dynamic to show only relevant content to the user logged in. For example, the
home page of a doctor should have different information to that of a patient. Currently, this is achieved using static div tags that are shown/hidden, in code behind (VB.NET) , information of person who logs in.
The objective is to drive this home page data from SQL server data table. Something like, when a user logs in, a stored procedure is called with ID as parameter which returns content that is to be placed in different sections of home page. A kind of mini
CMS. I can go ahead and create a table with content row for each member type and pull it with stored procedure as soon as person logs in.
But, I don't prefer to do it the old way. Please suggest best ways to achieve above.
Aug 25, 2017 07:43 AM|Billy Liu|LINK
Hi Siva Karthik,
I think you could try to create different home pages for different users.
When user logs in, you could redirect the page to their home page according to their roles.
Aug 25, 2017 03:43 PM|Hnqtxe1Hn@555|LINK
Thanks for your reply.
Creating a different home page may not be suitable for our website as there are around 20 member types and may increase in future. Also, if there is a change in the content of the home page, we need code changes hence testing and deployment. To reduce the
amount of work, I would like to drive the content from data base so that I can do the changes with SQL statement saving lot of time.
Aug 30, 2017 06:27 AM|Billy Liu|LINK
Hi Siva Karthik,
According to your description, it seems that your old way is good enough.
Which part do you want to change?