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, 816🔥, 0💬
Popular Posts:
Molecule Summary: ID: FYI-1003296 Names: InChIKey: JSMRVXYDHGMPPA-UHFFFAOYS A-NSMILES: COc4cccc(c3nc...
Molecule Summary: ID: FYI-1003271 Names: InChIKey: IHACWDINNZTNTN-UHFFFAOYS A-NSMILES: Oc3ccc(O)c(c2...
Molecule Summary: ID: FYI-1014805 Names: InChIKey: RALDEEUHNXQFIN-UHFFFAOYS A-NSMILES: C=C(CCCCCCCCC...
Molecule Summary: ID: FYI-1005761 Names: InChIKey: JACRWUWPXAESPB-UHFFFAOYS A-NSMILES: C1=CC=C(C=C1)...
Molecule Summary: ID: FYI-1001103 SMILES: CC1(CCC(=C(C1)C2=CC=C(C= C2)Cl)CN3CCN(CC3)C4=CC(= C(C=C4)C(=...