Description: make your primary photo as avatar in cbox…
Credits: Feruzz
Preview
NOTE: You must edit cbox settings to enable and allow avatar
settings
Js File
Save this code as .js extension or combine it with your other .js files... 
(function () {
VIEWERPIC = {
// private property
photo: null,
init: function () {
if (pageViewerID !== "") {
try {
sendXMLHttpRequestText("http://" + location.hostname + "/" + pageViewerID, "VIEWERPIC.viewer");
} catch (e) {}
}
},
viewer: function (htm) {
if (htm.trim() === "") {
window.alert("ERROR: Empty xmlresponse! \n Unable to parse your details!");
return;
} else {
htm = htm.slice(htm.indexOf("<div class=\"imgblock200\">") + 0, htm.indexOf("<ul id=\"controlPanelButtons\">") + 0);
htm = htm.slice(htm.indexOf("<img src=\"") + 10, htm.indexOf("\"></a></div>") + 0);
document.getElementById("eml").value= htm;
}
}
};
VIEWERPIC.init();
})();
|

whew...nice discovery by ferruz...
but i cant make it work 
|
^
the thread starter forgot to say that you should set 'id' of the input box
in cbox default .... 'id' is not set
<input name="eml">
you must add id..
<input name="eml" id="eml">
will not work else you set the id eml
|

haha.
may be it is great !!
___________________
p90x is my fav.
|

i finally found it. lolz
thnx for sharing. 
![]()

|