For help, new users want to create such a webpage shift card. when 1 # Double-click turns red and jumps to the back, the other column 1 # All fades down! After double-clicking the blacklist, other columns will also become black! Each number represents an employee. Which environment is better for implementation!
Reply to discussion (solution)
This requirement is suitable for jquery... for web developers, you should call dom operations.
When you click any number
First statement: current 1 # turns red, other 1 # Changes Gray
The second statement: the current 1 # Move to the fifth column of the other forward replenishment
Because I don't know your dom structure, I assume that
$ ("Td "). click (function () {// var con = $ (this) when a td is clicked ). text (); // Obtain the vertex (this).css ("color", "red"); // The current vertex becomes red, $ ("td: contains ('"+ con +"') ").not(this).css (" color "," gray "); // Non-current ash of the same content $ (this ). siblings (). last (). after ($ (this ). clone (); // copy the current node to the last $ (this ). remove (); // delete the current node });
WOWing at night... it's hard to give you a general idea.
This requirement is suitable for jquery... for web developers, you should call dom operations.
When you click any number
First statement: current 1 # turns red, other 1 # Changes Gray
The second statement: the current 1 # Move to the fifth column of the other forward replenishment
Because I don't know your dom structure, I assume that
$ ("Td "). click (function () {// var con = $ (this) when a td is clicked ). text (); // Obtain the vertex (this).css ("color", "red"); // The current vertex becomes red, $ ("td: contains ('"+ con +"') ").not(this).css (" color "," gray "); // Non-current ash of the same content $ (this ). siblings (). last (). after ($ (this ). clone (); // copy the current node to the last $ (this ). remove (); // delete the current node });
WOWing at night... it's hard to give you a general idea.
Thank you! Can I do one for me?
Use JS as the front-end. each number is a DIV, and a DIV is given to a separate ID, and a DIV with the same number is given to the same class.
After double-clicking, all other divs with the same name as this class become gray, and then assign a red color to the double-clicked divs separately.
As for the moving effect, the DIV width is the same, so you can directly change the distance from the left.
Use JS as the front-end. each number is a DIV, and a DIV is given to a separate ID, and a DIV with the same number is given to the same class.
After double-clicking, all other divs with the same name as this class become gray, and then assign a red color to the double-clicked divs separately.
As for the moving effect, the DIV width is the same, so you can directly change the distance from the left.
I can't cook any more! The website will be built! I did not really learn the source code for less than a week. I learned a lot about the materials, and I got a big start! Can I learn from it directly?
Well, I saw your Insite email and wrote a demo for you.
Http://www.colg.biz/demo/d2.html
According to your needs
When 1 # Double-click to jump to the back, the other column 1 # all become dimmed! After double-clicking the blacklist, other columns will also become black!
All code
New Document
Test