Daniel, the zip file you sent me doesn´t have the actual page created by
PHP. I´d rather see that than the PHP itself. I need to see exactly what is
in the second browser window to see what went wrong.
On Thu, Aug 25, 2011 at 11:16 AM, Daniel Carbajo
<[email protected]>wrote:
> I'm sorry I didn't know I couldn't upload files; in any case I created a
> web on our cluster where you can download the zip file and view the test
> pages. It needs a username and a password, so please write me to
> [email protected] and I will give you individually the address,
> username and password. Bob, I have already sent you this information to
> your stolaf.edu account, ok? Thanks again!
> Daniel
>
>
> 2011/8/25 Robert Hanson <[email protected]>
>
>> What I need to see is the source for the result of this PHP, Daniel.
>> Please send me what the 2nd PHP file produces, as simply copied from "view
>> source" in the client browser. I'll check on that second part when I have
>> that.
>>
>>
>> On Thu, Aug 25, 2011 at 6:25 AM, Daniel Carbajo <[email protected]
>> > wrote:
>>
>>> Hi Bob, I enclose a zip file with the test pages. The state of the first
>>> (testpage1.php) should be restored in the second (testpage2.php); it is the
>>> only thing that does not work (line 68 in testpage2.php), you can forget
>>> about the rest, I just included it since what I really need to restore are
>>> the models loaded and the residues selected.
>>>
>>> It is a little bit more tricky than it seems since the files in the 2nd
>>> page are different (same protein structures but B-factors changed), so
>>> $ESTADO needs to be parsed.
>>> I would prefer that the state is restored by default, instead of clicking
>>> a button, if you have an idea of how to do so...
>>>
>>> I also wanted to ask you another thing... If you play a little bit with
>>> the test pages, you can measure the distance between native residues and
>>> residues in the loaded models (last column in the "Residue selection" box),
>>> and the result is prompted; rather than that, I would prefer that all the
>>> information (including models loaded, residues selected and measures)
>>> appears in a text box inside the page, as in
>>> http://jena3d.fli-leibniz.de/ImgLibPDB/Jena3D/doc/jmol_scripting/examples-11/measure.htm
>>> but
>>> I could not make it work looking at the source code of that page. In any
>>> case let's try to solve the "restore state" issue first. Thanks a lot!
>>> Daniel
>>>
>>> PS: If you want to visit us at the Sapienza University when you are in
>>> Rome just tell me!
>>>
>>>
>>> 2011/8/24 Robert Hanson <[email protected]>
>>>
>>>> Great. I'm going to Turin next week and leave from Rome on the 6th.
>>>>
>>>> On Wed, Aug 24, 2011 at 12:39 PM, Daniel Carbajo <
>>>> [email protected]> wrote:
>>>>
>>>>> Thanks for the fast response Bob. It is just a part of a big page that
>>>>> queries databases and stuff, so I will have to work on the test pages a
>>>>> little bit; I'll send them to you tomorrow before midday (GMT+1). Thanks
>>>>> again; by the way now I'm working in Rome but I'm from Madrid ;)
>>>>>
>>>>>
>>>>> 2011/8/24 Robert Hanson <[email protected]>
>>>>>
>>>>>> [También, digame de dónde está. Estoy en Villadolid.]
>>>>>>
>>>>>>
>>>>>> On Wed, Aug 24, 2011 at 11:54 AM, Robert Hanson
>>>>>> <[email protected]>wrote:
>>>>>>
>>>>>>> Daniel, please send me a link to some test pages.
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Aug 24, 2011 at 10:38 AM, Daniel Carbajo <
>>>>>>> [email protected]> wrote:
>>>>>>>
>>>>>>>> Hello everyone,
>>>>>>>> I am sorry to re-open this thread, but just got back from holidays
>>>>>>>> trying to make this work with all the feedback I got (thanks Paul,
>>>>>>>> Rolf and
>>>>>>>> Bob), but I am not succeeding...
>>>>>>>> My aim is the following:
>>>>>>>> -I have 2 php pages, each with a Jmol window where I can load
>>>>>>>> different protein structures and I give the possibility to change the
>>>>>>>> display of such proteins (cartoon, spacefill, trace, backbone), to
>>>>>>>> highlight
>>>>>>>> (in sticks) different residues and give them a label.
>>>>>>>> -I want to save the state information of the Jmol window in the
>>>>>>>> first page (which I have already done) and pass it to the second,
>>>>>>>> where I
>>>>>>>> can restore it (where I have the problem).
>>>>>>>>
>>>>>>>>
>>>>>>>> I already have the following:
>>>>>>>>
>>>>>>>> FIRST PHP:
>>>>>>>>
>>>>>>>> $cont0 .= "<form name=\"PASARCOLORS\" action=\"MODshowCOLORS.php\"
>>>>>>>> method=\"POST\" onSubmit='var
>>>>>>>> state=jmolGetPropertyAsString(\"stateInfo\");
>>>>>>>> document.PASARCOLORS.ESTADO.value=state;'>";
>>>>>>>> $cont0 .= "<input type=\"hidden\" name=\"ESTADO\"></form>";
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> SECOND PHP:
>>>>>>>>
>>>>>>>> $ESTADO=$_POST["ESTADO"];
>>>>>>>> echo "<!-- /***** Jmol Embedded Script ****
>>>>>>>> ?php echo $ESTADO; ?
>>>>>>>> **/ -->";
>>>>>>>> $JMOL = "<script type=\"text/javascript\">
>>>>>>>> jmolInitialize(\"Jmol-12new\", true);
>>>>>>>> jmolSetAppletColor(\"white\");
>>>>>>>> var jmolcmds = [
>>>>>>>> \"load $ZIPtoUSE|$PREFIX-Models_$code/$PREFIX-$code.pdb\",
>>>>>>>> \"set frank off; select all; hbonds off; spin off; wireframe off;
>>>>>>>> spacefill off; trace off; set ambient 40; set specpower 40; slab off;
>>>>>>>> ribbons off; cartoons off; label off; monitor off\",
>>>>>>>> \"set isosurfacePropertySmoothing TRUE\",
>>>>>>>> \"set showAxes true\",
>>>>>>>> \"set appendNew true\",
>>>>>>>> \"frame all\",
>>>>>>>> \"display all\",
>>>>>>>> \"select 1.1; cartoon; set propertyColorScheme 'bwr'; color atoms
>>>>>>>> property temperature ABSOLUTE $range\",
>>>>>>>> \"script Jmol-12new/myJMOLfunctions.spt\"
>>>>>>>> ];
>>>>>>>> jmolApplet([580,500], jmolcmds.join(\"; \"));
>>>>>>>> </script>";
>>>>>>>>
>>>>>>>> $JMOL .= "<form><script>jmolButton(\"reset\", \"Original
>>>>>>>> orientation\");
>>>>>>>> jmolButton(\"move 360 0 0 0 0 0 0 0 20\", \"Rotate X axis\");
>>>>>>>> jmolButton(\"move 0 360 0 0 0 0 0 0 20\", \"Rotate Y axis\");
>>>>>>>> jmolButton(\"write image.png\", \"Create image\");
>>>>>>>> </script>";
>>>>>>>> $JMOL .= '<script>function
>>>>>>>> restoreState(){jmolScript(document.body.innerHTML)};
>>>>>>>> jmolButton([restoreState], "RESTORE");</script></form>';
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> The last line is not working, but I don't know why, since the
>>>>>>>> information is correctly passed to $ESTADO (any idea Bob?). Besides, I
>>>>>>>> would
>>>>>>>> like that the state is restored by default, so I guess I don't need
>>>>>>>> "var jmolcmds" at all, just restoring at the beginning with
>>>>>>>> jmolScript...
>>>>>>>> how should it be? Thanks again to everyone!
>>>>>>>> Daniel
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> EMC VNX: the world's simplest storage, starting under $10K
>>>>>>>> The only unified storage solution that offers unified management
>>>>>>>> Up to 160% more powerful than alternatives and 25% more efficient.
>>>>>>>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>>>>>>>> _______________________________________________
>>>>>>>> Jmol-users mailing list
>>>>>>>> [email protected]
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Robert M. Hanson
>>>>>>> Professor of Chemistry
>>>>>>> St. Olaf College
>>>>>>> 1520 St. Olaf Ave.
>>>>>>> Northfield, MN 55057
>>>>>>> http://www.stolaf.edu/people/hansonr
>>>>>>> phone: 507-786-3107
>>>>>>>
>>>>>>>
>>>>>>> If nature does not answer first what we want,
>>>>>>> it is better to take what answer we get.
>>>>>>>
>>>>>>> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Robert M. Hanson
>>>>>> Professor of Chemistry
>>>>>> St. Olaf College
>>>>>> 1520 St. Olaf Ave.
>>>>>> Northfield, MN 55057
>>>>>> http://www.stolaf.edu/people/hansonr
>>>>>> phone: 507-786-3107
>>>>>>
>>>>>>
>>>>>> If nature does not answer first what we want,
>>>>>> it is better to take what answer we get.
>>>>>>
>>>>>> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> EMC VNX: the world's simplest storage, starting under $10K
>>>>>> The only unified storage solution that offers unified management
>>>>>> Up to 160% more powerful than alternatives and 25% more efficient.
>>>>>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>>>>>> _______________________________________________
>>>>>> Jmol-users mailing list
>>>>>> [email protected]
>>>>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> EMC VNX: the world's simplest storage, starting under $10K
>>>>> The only unified storage solution that offers unified management
>>>>> Up to 160% more powerful than alternatives and 25% more efficient.
>>>>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>>>>> _______________________________________________
>>>>> Jmol-users mailing list
>>>>> [email protected]
>>>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Robert M. Hanson
>>>> Professor of Chemistry
>>>> St. Olaf College
>>>> 1520 St. Olaf Ave.
>>>> Northfield, MN 55057
>>>> http://www.stolaf.edu/people/hansonr
>>>> phone: 507-786-3107
>>>>
>>>>
>>>> If nature does not answer first what we want,
>>>> it is better to take what answer we get.
>>>>
>>>> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> EMC VNX: the world's simplest storage, starting under $10K
>>>> The only unified storage solution that offers unified management
>>>> Up to 160% more powerful than alternatives and 25% more efficient.
>>>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>>>> _______________________________________________
>>>> Jmol-users mailing list
>>>> [email protected]
>>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>>
>>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> EMC VNX: the world's simplest storage, starting under $10K
>>> The only unified storage solution that offers unified management
>>> Up to 160% more powerful than alternatives and 25% more efficient.
>>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>>> _______________________________________________
>>> Jmol-users mailing list
>>> [email protected]
>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>
>>>
>>
>>
>> --
>> Robert M. Hanson
>> Professor of Chemistry
>> St. Olaf College
>> 1520 St. Olaf Ave.
>> Northfield, MN 55057
>> http://www.stolaf.edu/people/hansonr
>> phone: 507-786-3107
>>
>>
>> If nature does not answer first what we want,
>> it is better to take what answer we get.
>>
>> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>>
>>
>> ------------------------------------------------------------------------------
>> EMC VNX: the world's simplest storage, starting under $10K
>> The only unified storage solution that offers unified management
>> Up to 160% more powerful than alternatives and 25% more efficient.
>> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
>> _______________________________________________
>> Jmol-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>
>>
>
>
> ------------------------------------------------------------------------------
> EMC VNX: the world's simplest storage, starting under $10K
> The only unified storage solution that offers unified management
> Up to 160% more powerful than alternatives and 25% more efficient.
> Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
> _______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>
--
Robert M. Hanson
Professor of Chemistry
St. Olaf College
1520 St. Olaf Ave.
Northfield, MN 55057
http://www.stolaf.edu/people/hansonr
phone: 507-786-3107
If nature does not answer first what we want,
it is better to take what answer we get.
-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
------------------------------------------------------------------------------
EMC VNX: the world's simplest storage, starting under $10K
The only unified storage solution that offers unified management
Up to 160% more powerful than alternatives and 25% more efficient.
Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users