but it doesn´t seem to work. I think it has to do with the "&", because if i adapt the desklet with this:
setting %Username%=external, %Password%=php, everything is OK.
Am i right? Or it has to do with sth else?
Posted 14 October 2006 - 06:26 AM
Posted 14 October 2006 - 08:19 AM
function init()
{
var val = "https://mail.google.com/mail/feed/atom?username=" + desklet.params("Username").value + "&password=" + desklet.params("Password").value;
desklet.params("SiteAddress").default = val;
desklet.params("SiteAddress").value = val;
}
Posted 14 October 2006 - 03:11 PM
<desklet> <bindthis>false</bindthis> <alpha>255</alpha> <resources></resources> <ctrlresources>Controls</ctrlresources> <language>JScript</language> <keypressanim>100</keypressanim> <include>parsers/yellowpages.js</include> <script>yp.js</script> <oncreate>onInitDesklet()</oncreate> // this is the magic line <onmouseenter>onDeskletEnter()</onmouseenter> <onmouseexit>onDeskletExit()</onmouseexit> </desklet>
Posted 17 October 2006 - 12:21 AM
<root> <skininfo> <name>Gmail</name> <author>Gabriel Guernik</author> <notes>Check your Gmail account</notes> <version>100</version> <reqversion>100</reqversion> <icon>icon</icon> </skininfo> <skindata> <desklet> <alpha>255</alpha> <resources></resources> <ctrlresources></ctrlresources> <language>JScript</language> <keypressanim>100</keypressanim> <script>main.js</script> <!--<onmousescroll>UpdateScrollPosition();</onmousescroll>--> <oncreate>CreateSetup()</oncreate> </desklet> <sides> <side id="0" width="128" height="128" closex="10" closey="10"/> <side id="1" width="266" height="225" closex="10" closey="10"/> </sides> <xmls> <xml src="%SiteAddress%" interval="2" usewintmp="yes" ongetdata="UpdateMails();"/> </xmls> <timers> </timers> <parameters> <param name="SiteAddress" default="https://mail.google.com/mail/feed/atom?username=%Username%&password=%Password%" save="yes" onupdate=""/> <param name="RefreshDelay" default="2" save="yes" onupdate=""/> <param name="Username" default="" save="yes" onupdate=""/> <param name="Password" default="" save="yes" onupdate=""/> <param name="Mails" default="0" save="no" onupdate=""/> </parameters> <layers side="0"> <layer name="FrontBG" x="0" y="0" width="128" height="128" src="Gmail_stamp.png" fontalign="LT"/> <layer name="Gotolink" x="0" y="0" width="128" height="100" src="!HITSPOT" mousecursor="IDC_HAND" onclick="GoToLink()"/> <layer name="FrontFlip" x="110" y="93" width="13" height="13" src="flipit.png" onclick="!FLIP:1" onmouseenter="!EFFECT:SHOW,SELF,255,10,10" onmouseexit="!EFFECT:HIDE,SELF,0" mousecursor="crDefault" alpha="0" fontalign="LT" fullhittest="yes"/> <layer name="NewMail" x="72" y="0" width="41" height="41" src="Mark1.png" visible="yes" fontalign="LT" /> <layer name="NroMails" x="72" y="-2" width="41" height="41" mousecursor="crDefault" fontname="Dungeon" fontsize="27" fontcolor="clWhite" fontstyle="" fontalign="CM" /> <!-- <layer name="Nro" x="22" y="22" width="100" height="41" src="!XMLTXT:[//fullcount]" mousecursor="crDefault" fontname="Dungeon" fontsize="27" fontcolor="clWhite" fontstyle="" fontalign="CM" /> --> </layers> <layers side="1"> <layer name="BackBG" x="0" y="0" width="266" height="225" src="backside.png" mousecursor="crDefault" fontstyle="" fontalign="LT" fontaa="No"/> <layer name="BackFlip" x="187" y="170" width="55" height="25" src="done.png" dsrc="done_pressed.png" onclick="ApplySettings();" mousecursor="crDefault" fontstyle="" fontalign="LT" fontaa="No" fullhittest="yes"/> <layer name="Msg1" x="25" y="19" width="230" height="20" src="!TXT:Username:" fontname="Lucida Sans Unicode" fontsize="12" fontcolor="clWhite" fontalign="M"/> <layer name="Box1" x="25" y="42" width="220" height="20" src="box.png" fontalign="LT"/> <layer name="Msg3" x="25" y="65" width="230" height="20" src="!TXT:Password:" fontname="Lucida Sans Unicode" fontsize="12" fontcolor="clWhite" fontalign="M"/> <layer name="Box3" x="25" y="88" width="220" height="20" src="box.png" fontalign="LT"/> <layer name="Msg2" x="25" y="130" width="230" height="20" src="!TXT:Refresh delay in mins.:" fontsize="14" fontcolor="clWhite" fontalign="LT"/> <layer name="Box2" x="190" y="128" width="50" height="20" src="box.png" fontalign="LT"/> </layers> <controls side="0"> </controls> <controls side="1"> <control name="Username" type="EDITBOX" x="27" y="43" width="210" height="23" fontname="Lucida Sans Unicode" fontsize="9" fontbg="clHighlight" fontalign="LT" value="%Username%" /> <control name="Password" type="EDITBOX" x="27" y="89" width="210" height="23" fontname="Lucida Sans Unicode" fontsize="9" fontbg="clHighlight" fontalign="LT" value="%Password%" /> <control name="RefreshDelay" type="EDITBOX" x="192" y="128" width="47" height="23" fontname="Lucida Sans Unicode" fontsize="9" fontbg="clHighlight" fontalign="LT" value="%RefreshDelay%" /> </controls> <menus> <menu showdefault="yes"> <menuitem name="-" type="S" /> <menuitem name="Refresh" onclick="this.Redraw();" /> <menuitem name="Update Data" onclick="this.ForceXDataFetch()" /> </menu> </menus> </skindata> </root>
// main.js
//Apply the settings
function ApplySettings(){
var UserParam = this.parameters('Username');
var UserVal = this.controls('Username');
var PassParam = this.parameters('Password');
var PassVal = this.controls('Password');
var RefreshParam = this.parameters('RefreshDelay');
var RefreshVal = this.controls('RefreshDelay');
RefreshParam.Value = parseInt(RefreshVal.Value);
if ((UserParam.Value != UserVal.Value) || (PassParam.Value != PassVal.Value))
{
UserParam.Value = UserVal.Value;
PassParam.Value = PassVal.Value;
//this.parameters('SiteAddress').Reset();
//this.xmls(0).Reset();
//ActAddress();
this.ForceXDataFetch();
GetMails();
}
this.FlipTo(0);
this.ReDraw(true);
}
//Go to the link
function GoToLink(){
var User = this.parameters('Username').Value;
var Pass = this.parameters('Password').Value;
var link = "https://www.google.com/accounts/ServiceLoginAuth?ltmpl=plnch<mplcache=2&continue=http%3A%2F%2Fmail.google.com%2Fmail%2F%3F&service=mail&rm=false<mpl=plnch&Email="+User+"&Passwd="+Pass+"&PersistentCookie=yes&rmShown=1&null=Sign+in";
if (link != '')
this.IO.ShellExecutes(link);
}
function GetMails(){
var Qmails = this.ConvertToValue('!XMLTXT:[//fullcount]');
var Nro = this.Layers('NroMails');
Nro.text = Qmails;
this.ReDraw();
}
function CreateSetup(){
//var val = "https://mail.google.com/mail/feed/atom?username=" + desklet.params("Username").value + "&password=" + desklet.params("Password").value;
//desklet.params("SiteAddress").default = val;
//desklet.params("SiteAddress").value = val;
GetMails();
}
function UpdateMails(){
GetMails();
this.ReDraw();
}
function ActAddress(){
var User = this.parameters('Username').Value;
var Pass = this.parameters('Password').Value;
var Site = this.parameters('SiteAddress');
Site.Value = this.ConvertToValue("https://mail.google.com/mail/feed/atom?username="+User+"&password="+Pass);
}
Posted 28 October 2006 - 10:00 PM
Posted 29 October 2006 - 01:32 AM
Posted 29 October 2006 - 01:33 PM