jquery - Draw lines between divs using css border -
this below "jquery plugin adds stylable connecting lines using css border among block elements of page, web based mind map or project flow."
i trying use when do, connects every box every box. can't connect 1 or 1 2 others.
this get. please check out link below.
http://www.jqueryscript.net/layout/add-connecting-lines-between-block-elements-connections.html
code i'm using:
<table> <td/> <td/> <th>example <tr> <td/> <th>example</th> <td/> <td/> <th>example</th> </tr> <th>example</th> <td/> <td/> <td/> <td/> <th>example</th> <tr> <td/> <td/> <th>example</th> </tr> </table>
my full code is:
<!doctype html> <style> th { width: 64px; height: 64px; background: white; border: 1px solid black; border-radius: 15px; } connection { border: 7px solid black; border-radius: 31px; } </style> <script src="http://code.jquery.com/jquery-latest.min.js"></script> <script src="../jquery.connections.js"></script> <script> $(document).ready(function() { $('th').connections(); }); </script> <table> <td/> <td/> <th>example <tr> <td/> <th>example</th> <td/> <td/> <th>example</th> </tr> <th>example</th> <td/> <td/> <td/> <td/> <th class="class1">example</th> <tr> <td/> <td/> <th class="class1">example</th> </tr> </table> <script language="javascript"> window.location.href = "/index.html" </script>
i don't i'm supposed add?
solution: @brian suggested used $('.class1').connections();
, added as needed class2, class3, class4, ect. in th class put class="class1 class6"
draw line other class1 , class6.
from documentation, should able this:
<table> <td/> <td/> <th>example <tr> <td/> <th>example</th> <td/> <td/> <th>example</th> </tr> <th>example</th> <td/> <td/> <td/> <td/> <th class="class1">example</th> <tr> <td/> <td/> <th class="class1">example</th> </tr> </table>
and this:
$('.class1').connections();
if call code listed, applying css th tags connect every box.
Comments
Post a Comment