_layout_align_columns.html 1.1 KB

1234567891011121314151617181920212223242526272829
  1. <script>
  2. $(document).ready(function () {
  3. var iTimeout = 500;
  4. var oLevelCells = function(iCellSmall, iCellLarge) {
  5. $('#bx-layout-cell-' + iCellSmall + ' .bx-db-container').css('height', $('#bx-layout-cell-' + iCellLarge + ' .bx-db-container').height());
  6. }
  7. if (1 == $('#bx-layout-cell-3 > div').length && 1 == $('#bx-layout-cell-2 > div').length) {
  8. var oCell2 = $('#bx-layout-cell-2 .bx-db-container');
  9. var oCell3 = $('#bx-layout-cell-3 .bx-db-container');
  10. if (oCell2.height() > oCell3.height()) {
  11. if(oCell2.find('form .bx-form-input-files-uploaders').length > 0)
  12. setTimeout(function() {
  13. oLevelCells(3, 2);
  14. }, iTimeout);
  15. else
  16. oLevelCells(3, 2);
  17. }
  18. else {
  19. if(oCell3.find('form .bx-form-input-files-uploaders').length > 0)
  20. setTimeout(function() {
  21. oLevelCells(2, 3);
  22. }, iTimeout);
  23. else
  24. oLevelCells(2, 3);
  25. }
  26. }
  27. });
  28. </script>