Now edit the script: for example, change one of the colors. Now we will switch between the file and viewing it in a browser.Ģ8. "load pdb_files/ cartoons only select :a color red select :b color blue select :c color yellow moveto /* time, axisAngle */ 1.0 72.433464 -47.33075 0.0 spin y 10 delay 10 spin off"Įach item must be closed with a semicolon (typical jmol commands spaces are optional)Ģ7. To change the jmol script, go back to the, for example, copy and past this: JmolApplet0 = Jmol.getApplet("jmolApplet0", Info) Ģ6. The target="_blank" will cause the page to open in a new window. These use the tags to reference a URL:Ģ4. In the Y cell are references to the PubMed entry and the Protein DataBank file.Ģ3. Text is easiest to add in the "WYSIWYG" view.Ģ2. In this Table, X, the left cell, is the jmol "applet", and Y, the right cell, is the text describing it. You can also creat or modify Tables in the "WYSIWYG" view of BlueGriffonĢ1. This Table has other formatting information: width="1200" border="1" cellspacing="3" cellpadding="3"> (you can play with these values to see their effects.) Where "X" and "Y" are the text or items in the table cells.Ģ0. This is a Table that has 1 row and 2 columns.
Make things spin in jmol code#
The code for a table with 2 cells is a little complicated to understand. The jmol applet will be in one cell of a Table, and the text describing it will be in the other cell.ġ9. Here one can code the background color of the html page: bgcolor="#000088". Third, the jmol loading and script information: script: "load pdb_files/",ġ7. You have complete control of the background color. Second the background color of the jmol box: color: "#ffffff", which is White. There are 3 important things following this tag: įirst, the dimensions of the jmol box, shown here in pixels: width: 800, height: 800, Also in the is the basic jmol information. Therefore, the path is given by "jsmol/".ġ6. In this case, the Jmol.js file is in the "jsmol" folder, which is in the "jmol" folder, as is your template1018.html file. If is in the same folder as the template.html file, then just the name of the file is given. Here the correct pathway to the file is essential. This allows buttons and other special items to be incorporated into the page. Also in this is a path to the javascript file called "". You should rename it when you make a new page.ġ5. The title of this page is "Name of page".
![make things spin in jmol make things spin in jmol](https://quotefancy.com/media/wallpaper/3840x2160/2016046-John-Wooden-Quote-Things-turn-out-best-for-those-who-make-best-of.jpg)
The title is displayed at the top of any webpage. This format works for all tags (almost).ġ4. So everything between will be defined by this tag. This identifies the file as an HTML file. Lines that begin with exclamation marks "!" or "//" are for comments-they are not displayed by the browser.ġ3. If you click "Source" you will see the html code. In BlueGriffon, look at the bottom of the page where it says WYSIWYG/Source. The template file is initially set up to use the pdb file .ġ2. Any text editor will work, and a dedicated web page editor, such as Blue Griffon has some very useful features.ġ1. Then edit the "template2018.html" page to use that pdb file. This is one way to make a Jmol page: First load a pdb file into the correct folder: "pdb_files".
![make things spin in jmol make things spin in jmol](https://cdn.mycrafts.com/i/1/8/4/how-to-make-fidget-spinner-out-of-jb4V-m.jpg)
( Unfortunately, the current Chrome or Safari will probably not work to load local files. Select Firefox and check the box to remember this choice. To see how this page looks in a browser, click the globe-like button in BlueGriffon.
Make things spin in jmol download#
Or, you can always download the original again.ĩ.
![make things spin in jmol make things spin in jmol](https://3.bp.blogspot.com/-CztGuSZdSbM/W3NjjiMQqXI/AAAAAAAEWbQ/o6He8USeaDERIQCJImHQND16HseiN2vPgCLcBGAs/s1600/Make%2Ba%2B3%2Bcolour%2Bwheel%2Bpart%2B2.jpg)
That will preserve the template file in its original state, in case you need to come back to it later. Save this file as "1template2018.html", "XYZtemplate2018.html" or some other name. (Try right-click) I recommend BlueGriffon. Open the "template2018.html" file in a text editor or html editor application. Move the "jsmol" folder and the "pdb_files" folder into the jmol_pages folder.ħ. Or save it anywhere, and then drag and drop the file in the folder.Ħ. To do this: for example, right-click (Control-click) and "Save Link As." to the new "jmol_pages" folder. Download the " template2018.html" file and place it in the "jmol_pages" folder. Check that your jmol folder also contains a folder called "pdb_files", with the file "".ĥ. Check that your jmol folder contains a folder called "jmol_pages".Ĥ.
Make things spin in jmol zip#
You might have it in a zip format, in which case, expand it.ģ. Check to see that it contains a folder called "jsmol". You will need BlueGriffon and Firefox for this lesson.Ģ.