This page is also available in: 日本語
It is possible to integrate Molmil on your own website. The following example is a simple webpage including the required JavaScript to load and initialize Molmil:
      var molmil_settings = {src: ""}, canvas;
      function initViewer() {
        if (! window.molmil.configBox || ! molmil.configBox.initFinished) {return setTimeout(initViewer, 100);}
        canvas = document.getElementById("molmilViewer");
        canvas = molmil.createViewer(canvas);
        molmil.loadPDB(canvas.getAttribute("data-pdbid"), null, null, canvas.molmilViewer);
  <body onload="initViewer();">
      <h1 id="mm_title">molmil viewer</h1>
      <h3>Integration test page</h3>
      <span class="molmil_UI_container">
        <canvas id="molmilViewer" data-pdbid="1crn" width="600" height="400" style="display: block; border: 1px solid #DDD;"></canvas>
  <script src=""></script>

The above example downloads Molmil (line 24) and loads the structure (identified by data-pdbid="1crn" in line 20) with PDBID 1crn via the initViewer JavaScript function (link 6) using PDBj's rest service (line 10) for PDB entry files.
Screenshot for page produced from the above code
2014-08-21 (last edited: more than 1 year ago)2015-12-08
PDBj@FacebookPDBj@TwitterwwPDBwwPDB FoundationEM DataBank

Copyright © 2013-2017 Protein Data Bank Japan