Collections:
Assign Embedded 3Dmol Viewer to DIV
How to assign Embedded 3Dmol Viewer to a "div" element?
✍: FYIcenter.com
Here is an HTML code example, Embedded-Viewer-PDB.html, that
assigns the Embedded 3Dmol Viewer to in "div" element.
It also uses "data-*" attributes to load a protein from the PDB Websites,
creates a selection from chain A and displays it in cartoon style.
<html><head> <script src="/3Dmol-min.js"></script> </head> <body> <div style="width: 400px; height: 400px; position: relative;" class="viewer_3Dmoljs" data-pdb="1YCR" data-select='chain:A' data-style='cartoon:color=spectrum' data-ui="true" /> </body></html>
This example HTML code will display a PDB protein in cartoon style:
Note that the protein structure data is downloaded with the following PDB API:
http://files.rcsb.org/view/{PDB_ID}.pdb
⇒ Multiple Selections with Embedded 3Dmol Viewer
⇐ What Is Embedded 3Dmol Viewer
⇑⇑ 3Dmol.js FAQ
2023-01-30, 900🔥, 0💬
Popular Posts:
Molecule Summary: ID: FYI-1001105 SMILES: C=CCN1CCC23C4C(=O)CCC2(C 1CC5=C3C(=C(C=C5)OC6C(C( C(C(O6)C(=...
Molecule Summary: ID: FYI-1004178 Names: InChIKey: HZZVJAQRINQKSD-PBFISZAIS A-NSMILES: O=C(O)[C@H]2/...
Molecule Summary: ID: FYI-1004013 Names: InChIKey: QBLWWQDTKCIRSW-UHFFFAOYS A-NSMILES: Sc2nnc(c1cccn...
Molecule Summary: ID: FYI-1000462 SMILES: C1[C@@H]([C@H](C2(O1)C3[ C@@]45C[C@@](O2)([C@]6([ C@@]([C@@H...
Molecule Summary: ID: FYI-1005859 Names: InChIKey: YAFYTEUTGDIFDN-UHFFFAOYS A-NSMILES: Cc2c(CNC(=O)C...