Jump to content

Employee profile page-changing the rank of employees


guttyguppy

Recommended Posts

Hi, a site I'm working on has a list of about 40 employees-a picture, name, and brief bio, followed by the next one, etc.

The client can add, edit or delete the employees, but they also want to reorder them.

I'm having a hard time looking at this from a programming view. If I add a new column to the mysql db called "rank", plug in defaults, and have the results sort by that, I think that's a start. But if they move employee #6 to the #12 spot, for instance, 7,8,9,10,and 11 need to drop by one, and 12 and up need to go up one. I could make them manually enter all this, but it seems like a major hassle for something that could easily be programmed.

What's the best way to do this? Thanks for any advice.

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.