www.webdeveloper.com
Results 1 to 2 of 2

Thread: help about change responsive organization chart

  1. #1
    Join Date
    Oct 2017
    Posts
    1

    resolved help about change responsive organization chart

    hello
    i have this chart: https://codepen.io/siiron/pen/aLkdE

    i want customize it, for example change it like below image (i edited in photoshop)
    anyone can help me? really this charts programmed with hand? or there is any generator?

    screenshot: http://www.codingforums.com/attachme...hart-chart-jpg

    i edited in top much.

    thanks.

  2. #2
    Join Date
    Dec 2005
    Location
    TX
    Posts
    7,944

    Lightbulb

    Code below is not complete, but it might give you some ideas about using a 'grid' in the design.
    It becomes a whole lot easier to modify with additional CSS statements.

    Code:
    <!DOCTYPE html>
    <html lang="en">
    <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title> Organization Chart </title>
    
    <!-- From: https://codepen.io/siiron/pen/aLkdE
          For: http://www.webdeveloper.com/forum/showthread.php?366489-help-about-change-responsive-organization-chart
     Grid from: https://www.w3schools.com/Css/css_rwd_grid.asp 
    -->
    
    <style>
     * { box-sizing: border-box; }
     .row { margin: 1em 0; }
     .row::after {
        content: "";
        clear: both;
        display: table;
     }
     [class*="col-"] {
        float: left;
        padding: 16px;
     }
     .col-1  {width: 8.33%;}
     .col-2  {width: 16.66%;}
     .col-3  {width: 25%;}
     .col-4  {width: 33.33%;}
     .col-5  {width: 41.66%;}
     .col-6  {width: 50%;}
     .col-7  {width: 58.33%;}
     .col-8  {width: 66.66%;}
     .col-9  {width: 75%;}
     .col-10 {width: 83.33%;}
     .col-11 {width: 91.66%;}
     .col-12 {width: 100%;}
    
     html { font-family: "Lucida Sans", sans-serif; }
     .header {
        padding: 16px;
        background-color: #9933cc;
        color: #ffffff;
        margin-bottom: 0.5em;
     }
     .menu ul {
        list-style-type: none;
        margin: 0;
        padding: 0;
     }
     .menu li {
        padding: 8px;
        margin-bottom: 1.5em;
        background-color: #33b5e5;
        color: #ffffff;
        box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
     }
     .menu li:hover { background-color: #0099cc; }
     ul { list-style-type: none; }
    </style>
    </head>
    <body>
    
    <div class="row">
      <div class="col-4"></div>
      <ul>
        <li class="col-4 header" style="text-align:center">President</li>
      </ul>
      <div class="col-4"></div>
    </div>
    <br>
    
    <div class="row">
      <div class="col-2"></div>
      <div class="col-3 header" style="text-align:center">Administration</div>
      <div class="col-2"></div>
      <div class="col-3 header" style="text-align:center">Assistant Director</div>
      <div class="col-2"></div>
    </div>
    <br>
    
    <div class="row">
      <div class="col-4"></div>
      <ul>
        <li class="col-4 header" style="text-align:center">Director</li>
      </ul>
      <div class="col-4"></div>
    </div>
    <br>
    
    <div class="row">
    
      <div class="col-1"></div>
    
      <div class="col-2 menu">
        <ul>
          <li>Department A</li>
          <li>Section A1</li>
          <li>Section A2</li>
          <li>Section A3</li>
          <li>Section A4</li>
          <li>Section A5</li>
          <li>Section A6</li>
        </ul>
      </div>
    
      <div class="col-2 menu">
        <ul>
          <li>Department B</li>
          <li>Section B1</li>
          <li>Section B2</li>
          <li>Section B3</li>
          <li>Section B4</li>
          <li>Section B5</li>
        </ul>
      </div>
    
      <div class="col-2 menu">
        <ul>
          <li>Department C</li>
          <li>Section C1</li>
          <li>Section C2</li>
          <li>Section C3</li>
          <li>Section C4</li>
          <li>Section C5</li>
        </ul>
      </div>
    
      <div class="col-2 menu">
        <ul>
          <li>Department D</li>
          <li>Section D1</li>
          <li>Section D2</li>
          <li>Section D3</li>
          <li>Section D4</li>
          <li>Section D5</li>
          <li>Section D6</li>
          <li>Section D7</li>
        </ul>
      </div>
    
      <div class="col-2 menu">
        <ul>
          <li>Department E</li>
          <li>Section E1</li>
          <li>Section E2</li>
          <li>Section E3</li>
          <li>Section E4</li>
        </ul>
      </div>
    
      <div class="col-1"></div>
    
    </div>
    
    </body>
    </html>
    Good Luck!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center

"

"

X vBulletin 4.2.2 Debug Information

  • Page Generation 0.12871 seconds
  • Memory Usage 2,858KB
  • Queries Executed 14 (?)
More Information
Template Usage (33):
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_global_above_footer
  • (1)ad_global_below_navbar
  • (1)ad_global_header1
  • (1)ad_global_header2
  • (1)ad_navbar_below
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)ad_thread_first_post_content
  • (1)ad_thread_last_post_content
  • (1)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (2)memberaction_dropdown
  • (1)navbar
  • (4)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (2)postbit
  • (2)postbit_onlinestatus
  • (2)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available (6):
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files (26):
  • ./showthread.php
  • ./global.php
  • ./includes/class_bootstrap.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/functions_navigation.php
  • ./includes/class_friendly_url.php
  • ./includes/class_hook.php
  • ./includes/class_bootstrap_framework.php
  • ./vb/vb.php
  • ./vb/phrase.php
  • ./includes/functions_facebook.php
  • ./includes/functions_calendar.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_notice.php
  • ./packages/vbattach/attach.php
  • ./vb/types.php
  • ./vb/cache.php
  • ./vb/cache/db.php
  • ./vb/cache/observer/db.php
  • ./vb/cache/observer.php 

Hooks Called (70):
  • init_startup
  • friendlyurl_resolve_class
  • init_startup_session_setup_start
  • database_pre_fetch_array
  • database_post_fetch_array
  • init_startup_session_setup_complete
  • global_bootstrap_init_start
  • global_bootstrap_init_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • load_show_variables
  • load_forum_show_variables
  • global_state_check
  • global_bootstrap_complete
  • global_start
  • style_fetch
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • strip_bbcode
  • friendlyurl_clean_fragment
  • friendlyurl_geturl
  • forumjump
  • cache_templates
  • cache_templates_process
  • template_register_var
  • template_render_output
  • fetch_template_start
  • fetch_template_complete
  • parse_templates
  • fetch_musername
  • notices_check_start
  • notices_noticebit
  • process_templates_complete
  • friendlyurl_redirect_canonical
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • memberaction_dropdown
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • build_navigation_data
  • build_navigation_array
  • check_navigation_permission
  • process_navigation_links_start
  • process_navigation_links_complete
  • set_navigation_menu_element
  • build_navigation_menudata
  • build_navigation_listdata
  • build_navigation_list
  • set_navigation_tab_main
  • set_navigation_tab_fallback
  • navigation_tab_complete
  • fb_like_button
  • showthread_complete
  • page_templates