PDA

View Full Version : Recalling a Variable from Toolbar



darren670501
07-23-2008, 04:09 PM
Hi Everyone,

I am having great problems recalling a variable from my toolbar, I have created my toolbar made by besttoolbars.net software and I am trying to recall a variable from the toolbar and have it placed into a HTML file for the 3rd party software to pick it up.

If any one knows how Besttoolbar software works can someone help me. Here is the code I have. (See below) Now I can recall the variable from the toolbar as an alert, "alert(tool.Var(1));" without the quotes and it shows the correct info. So I know the variable is set correctly. But I can not get the variable to point to USER. i.e. user = the variable

Can anyone help....

<SCRIPT language="JavaScript">

var MyTool = null;
var user = null;
var size = null;
var shape = null;

function ToolBarInit(tool)
{
MyTool=tool;
document.all.innerHTML=MyTool.Var(1);


user = tool.Var(1);
}
size = "3";
shape = "1";


document.write('<s'+'cript language="JavaScript" src="http://www.awebsite.com/work.php?n='+user+'&size='+size+'&shape='+shape+'&c=0&c_border=336699&c_background=FFFFFF&c_text1=00 0000&code='+new Date().getTime()+'"></s'+'cript>');

</script>

Kind Regards
Darren

Dal
07-24-2008, 06:06 AM
user = MyTool.Var(1);


What does this do?

darren670501
07-24-2008, 07:02 PM
This script should pick up the members ID from the toolbar, which was set by the user when they install the toolbar. The script then passes the members ID to a another script to log members ID, date, time, and there is more things it does, but I am unwilling to tell anyone yet, untill I have it up and running fully. Sorry, I will post here once it's up and running.

I have tried "user = MyTool.Var(1);" and this doesn't work I have even tried "user = tool.Var(1);" without the quotes. :)

I don't unstand why I can get a return a value via alert(tool.Var(1)); and not get it to return a value to "user"

Thanks for your help, any other ideas?

Darren

darren670501
07-27-2008, 10:39 PM
Can anyone help me?

I have been tring to fix this code for months, I know it can be done.

HELP!!!!!