|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
"http://www.w3.org/TR/html4/loose.dtd"> |
"http://www.w3.org/TR/html4/loose.dtd"> |
<html> |
<html> |
<head> |
<head> |
<title>Demo of the tree layout in D3.js</title> |
<title>Demo of the tree layout in D3.js</title> |
<!-- source: http://blog.pixelingene.com/demos/d3_tree/ |
<!-- source: http://blog.pixelingene.com/demos/d3_tree/ |
http://javadude.wordpress.com/2012/06/20/d3-js-from-tree-to-cluster-and-radial-projection/ |
http://javadude.wordpress.com/2012/06/20/d3-js-from-tree-to-cluster-and-radial-projection/ |
http://bl.ocks.org/1249394--> |
http://bl.ocks.org/1249394--> |
<style> |
<style> |
g.node { |
g.node { |
font-family: Verdana, Helvetica; |
font-family: Verdana, Helvetica; |
font-size: 12px; |
font-size: 12px; |
font-weight: bold; |
font-weight: bold; |
} |
} |
circle.node-dot { |
circle.node-dot { |
fill: lightsalmon; |
fill: lightsalmon; |
stroke: red; |
stroke: red; |
stroke-width: 1px; |
stroke-width: 1px; |
} |
} |
|
|
path.link { |
path.link { |
fill: none; |
fill: none; |
stroke: gray; |
stroke: gray; |
} |
} |
|
|
</style> |
</style> |
</head> |
</head> |
<body> |
<body> |
|
|
<div id="tree-container"></div> |
<div id="tree-container"></div> |
<div id="viz"></div> |
<div id="viz"></div> |
|
|
<script type="text/javascript" src="../javascripts/jquery-1.6.2.min.js"></script> |
<script type="text/javascript" src="../js/jquery-1.6.2.min.js"></script> |
<script type="text/javascript" src="../javascripts/d3.min.js"></script> |
<script type="text/javascript" src="../js/d3.min.js"></script> |
<script type="text/javascript" src="../javascripts/d3.layout.min.js"></script> |
<script type="text/javascript" src="../js/d3.layout.min.js"></script> |
|
|
<script> |
<script> |
/** |
/** |
* Created by JetBrains RubyMine. |
* Created by JetBrains RubyMine. |
* User: pavanpodila |
* User: pavanpodila |
* Date: 7/17/11 |
* Date: 7/17/11 |
* Time: 4:30 PM |
* Time: 4:30 PM |
* To change this template use File | Settings | File Templates. |
* To change this template use File | Settings | File Templates. |
*/ |
*/ |
|
|
var treeData = |
var treeData = |
<?php |
<?php |
// $json = file_get_children('naa-agift.json'); |
// $json = file_get_children('naa-agift.json'); |
// $raw = json_decode($json); |
// $raw = json_decode($json); |
// echo $json; |
// echo $json; |
// print_r($raw); |
// print_r($raw); |
$raw = json_decode('[ |
$raw = json_decode('[ |
"Home", |
"Home", |
"index.htm", |
"index.htm", |
[ |
[ |
"BUSINESS SUPPORT AND REGULATION", |
"BUSINESS SUPPORT AND REGULATION", |
"000411.htm", |
"000411.htm", |
[ |
[ |
"Association registration", |
"Association registration", |
"000396.htm" |
"000396.htm" |
], |
], |
[ |
[ |
"Business process auditing", |
"Business process auditing", |
"000413.htm" |
"000413.htm" |
], |
], |
[ |
[ |
"Business registration and licensing", |
"Business registration and licensing", |
"000414.htm" |
"000414.htm" |
], |
], |
[ |
[ |
"Business sponsorship", |
"Business sponsorship", |
"001371.htm" |
"001371.htm" |
], |
], |
[ |
[ |
"Consumer protection", |
"Consumer protection", |
"000439.htm" |
"000439.htm" |
], |
], |
[ |
[ |
"Fair trading compliance", |
"Fair trading compliance", |
"000482.htm", |
"000482.htm", |
[ |
[ |
"Prices surveillance", |
"Prices surveillance", |
"000533.htm" |
"000533.htm" |
], |
], |
[ |
[ |
"Product safety", |
"Product safety", |
"000534.htm" |
"000534.htm" |
], |
], |
[ |
[ |
"Trade practices compliance", |
"Trade practices compliance", |
"000583.htm" |
"000583.htm" |
] |
] |
], |
], |
[ |
[ |
"Financial institutions regulation", |
"Financial institutions regulation", |
"000485.htm" |
"000485.htm" |
], |
], |
[ |
[ |
"Government procurement regulation", |
"Government procurement regulation", |
"000491.htm" |
"000491.htm" |
], |
], |
[ |
[ |
"Industry assistance schemes", |
"Industry assistance schemes", |
"000499.htm" |
"000499.htm" |
], |
], |
[ |
[ |
"Industry development", |
"Industry development", |
"000500.htm" |
"000500.htm" |
], |
], |
[ |
[ |
"Insurance regulation", |
"Insurance regulation", |
"000501.htm", |
"000501.htm", |
[ |
[ |
"General insurance", |
"General insurance", |
"000489.htm" |
"000489.htm" |
], |
], |
[ |
[ |
"Life insurance", |
"Life insurance", |
"000505.htm" |
"000505.htm" |
] |
] |
], |
], |
[ |
[ |
"Professional accreditation", |
"Professional accreditation", |
"000535.htm" |
"000535.htm" |
], |
], |
[ |
[ |
"Small business services", |
"Small business services", |
"000565.htm", |
"000565.htm", |
[ |
[ |
"Small business advocacy", |
"Small business advocacy", |
"000563.htm" |
"000563.htm" |
], |
], |
[ |
[ |
"Small business development", |
"Small business development", |
"000564.htm" |
"000564.htm" |
] |
] |
], |
], |
[ |
[ |
"Stock market regulation", |
"Stock market regulation", |
"000572.htm" |
"000572.htm" |
] |
] |
], |
], |
[ |
[ |
"CIVIC INFRASTRUCTURE", |
"CIVIC INFRASTRUCTURE", |
"000424.htm", |
"000424.htm", |
[ |
[ |
"Civic management", |
"Civic management", |
"000425.htm", |
"000425.htm", |
[ |
[ |
"Architectural services", |
"Architectural services", |
"000387.htm" |
"000387.htm" |
], |
], |
[ |
[ |
"Building approval services", |
"Building approval services", |
"000406.htm" |
"000406.htm" |
], |
], |
[ |
[ |
"Building regulations and standards", |
"Building regulations and standards", |
"000408.htm" |
"000408.htm" |
], |
], |
[ |
[ |
"Engineering services", |
"Engineering services", |
"000477.htm" |
"000477.htm" |
], |
], |
[ |
[ |
"Town planning", |
"Town planning", |
"000582.htm" |
"000582.htm" |
] |
] |
], |
], |
[ |
[ |
"Energy supply", |
"Energy supply", |
"000476.htm" |
"000476.htm" |
], |
], |
[ |
[ |
"Integrated services planning", |
"Integrated services planning", |
"000503.htm" |
"000503.htm" |
], |
], |
[ |
[ |
"Public housing", |
"Public housing", |
"000536.htm", |
"000536.htm", |
[ |
[ |
"Public housing construction", |
"Public housing construction", |
"000537.htm" |
"000537.htm" |
], |
], |
[ |
[ |
"Public housing design", |
"Public housing design", |
"000538.htm" |
"000538.htm" |
], |
], |
[ |
[ |
"Public housing maintenance", |
"Public housing maintenance", |
"000540.htm" |
"000540.htm" |
] |
] |
], |
], |
[ |
[ |
"Public land management", |
"Public land management", |
"000541.htm", |
"000541.htm", |
[ |
[ |
"Burial ground management", |
"Burial ground management", |
"000410.htm" |
"000410.htm" |
], |
], |
[ |
[ |
"Cultural centre management", |
"Cultural centre management", |
"000444.htm" |
"000444.htm" |
], |
], |
[ |
[ |
"Garden management", |
"Garden management", |
"000488.htm" |
"000488.htm" |
], |
], |
[ |
[ |
"Memorial maintenance", |
"Memorial maintenance", |
"000509.htm" |
"000509.htm" |
], |
], |
[ |
[ |
"Recreational park management", |
"Recreational park management", |
"000549.htm" |
"000549.htm" |
], |
], |
[ |
[ |
"Sporting facilities management", |
"Sporting facilities management", |
"000571.htm" |
"000571.htm" |
] |
] |
], |
], |
[ |
[ |
"Regional development", |
"Regional development", |
"000552.htm" |
"000552.htm" |
], |
], |
[ |
[ |
"Transport network maintenance", |
"Transport network maintenance", |
"000586.htm" |
"000586.htm" |
], |
], |
[ |
[ |
"Waste management", |
"Waste management", |
"001349.htm" |
"001349.htm" |
] |
] |
], |
], |
[ |
[ |
"COMMUNICATIONS", |
"COMMUNICATIONS", |
"000433.htm", |
"000433.htm", |
[ |
[ |
"Advertising standards", |
"Advertising standards", |
"000381.htm" |
"000381.htm" |
], |
], |
[ |
[ |
"Broadcasting", |
"Broadcasting", |
"000403.htm", |
"000403.htm", |
[ |
[ |
"Broadcasting standards", |
"Broadcasting standards", |
"000404.htm" |
"000404.htm" |
], |
], |
[ |
[ |
"Radio broadcasting", |
"Radio broadcasting", |
"000546.htm" |
"000546.htm" |
], |
], |
[ |
[ |
"Television broadcasting", |
"Television broadcasting", |
"000580.htm" |
"000580.htm" |
] |
] |
], |
], |
[ |
[ |
"Call centre administration", |
"Call centre administration", |
"000417.htm" |
"000417.htm" |
], |
], |
[ |
[ |
"Electronic commerce", |
"Electronic commerce", |
"000468.htm", |
"000468.htm", |
[ |
[ |
"Authentication", |
"Authentication", |
"000399.htm" |
"000399.htm" |
], |
], |
[ |
[ |
"Online transaction standards", |
"Online transaction standards", |
"000526.htm" |
"000526.htm" |
] |
] |
], |
], |
[ |
[ |
"Government media", |
"Government media", |
"000490.htm" |
"000490.htm" |
], |
], |
[ |
[ |
"Information management standards", |
"Information management standards", |
"000283.htm", |
"000283.htm", |
[ |
[ |
"Data management", |
"Data management", |
"000448.htm" |
"000448.htm" |
], |
], |
[ |
[ |
"Information dissemination", |
"Information dissemination", |
"000502.htm" |
"000502.htm" |
], |
], |
[ |
[ |
"Information technology standards", |
"Information technology standards", |
"000282.htm" |
"000282.htm" |
] |
] |
], |
], |
[ |
[ |
"Media ownership regulation", |
"Media ownership regulation", |
"000508.htm" |
"000508.htm" |
], |
], |
[ |
[ |
"Postal services", |
"Postal services", |
"000530.htm", |
"000530.htm", |
[ |
[ |
"Courier services", |
"Courier services", |
"000441.htm" |
"000441.htm" |
], |
], |
[ |
[ |
"Electronic postal services", |
"Electronic postal services", |
"000469.htm" |
"000469.htm" |
], |
], |
[ |
[ |
"Retail postal services", |
"Retail postal services", |
"000554.htm" |
"000554.htm" |
] |
] |
], |
], |
[ |
[ |
"Publishing", |
"Publishing", |
"000543.htm", |
"000543.htm", |
[ |
[ |
"Electronic publishing", |
"Electronic publishing", |
"000470.htm" |
"000470.htm" |
], |
], |
[ |
[ |
"Publishing standards", |
"Publishing standards", |
"000544.htm" |
"000544.htm" |
], |
], |
[ |
[ |
"Website development", |
"Website development", |
"000591.htm" |
"000591.htm" |
] |
] |
], |
], |
[ |
[ |
"Radio communication", |
"Radio communication", |
"000547.htm", |
"000547.htm", |
[ |
[ |
"Apparatus licensing", |
"Apparatus licensing", |
"000385.htm" |
"000385.htm" |
], |
], |
[ |
[ |
"Spectrum management", |
"Spectrum management", |
"000570.htm" |
"000570.htm" |
] |
] |
], |
], |
[ |
[ |
"Satellite communication", |
"Satellite communication", |
"000560.htm" |
"000560.htm" |
], |
], |
[ |
[ |
"Telecommunications", |
"Telecommunications", |
"000578.htm", |
"000578.htm", |
[ |
[ |
"Carriage service providers", |
"Carriage service providers", |
"000420.htm" |
"000420.htm" |
], |
], |
[ |
[ |
"Carrier licensing", |
"Carrier licensing", |
"000421.htm" |
"000421.htm" |
], |
], |
[ |
[ |
"Equipment licensing", |
"Equipment licensing", |
"000480.htm" |
"000480.htm" |
], |
], |
[ |
[ |
"Mobile telephone services", |
"Mobile telephone services", |
"000516.htm" |
"000516.htm" |
], |
], |
[ |
[ |
"Telephone services", |
"Telephone services", |
"000579.htm" |
"000579.htm" |
] |
] |
] |
] |
], |
], |
[ |
[ |
"COMMUNITY SERVICES", |
"COMMUNITY SERVICES", |
"000435.htm", |
"000435.htm", |
[ |
[ |
"Accommodation services", |
"Accommodation services", |
"000377.htm", |
"000377.htm", |
[ |
[ |
"Defence housing", |
"Defence housing", |
"000458.htm" |
"000458.htm" |
], |
], |
[ |
[ |
"Emergency accommodation", |
"Emergency accommodation", |
"000471.htm" |
"000471.htm" |
], |
], |
[ |
[ |
"Public housing entitlements", |
"Public housing entitlements", |
"000539.htm" |
"000539.htm" |
], |
], |
[ |
[ |
"Refuge support", |
"Refuge support", |
"000551.htm" |
"000551.htm" |
] |
] |
], |
], |
[ |
[ |
"Community support", |
"Community support", |
"000436.htm", |
"000436.htm", |
[ |
[ |
"Adoption services", |
"Adoption services", |
"000378.htm" |
"000378.htm" |
], |
], |
[ |
[ |
"Aged care services", |
"Aged care services", |
"000382.htm" |
"000382.htm" |
], |
], |
[ |
[ |
"Child and youth support", |
"Child and youth support", |
"000422.htm" |
"000422.htm" |
], |
], |
[ |
[ |
"Child-care services", |
"Child-care services", |
"000423.htm" |
"000423.htm" |