PAGE2GO2 HOME | INTERNET NEWS

LeighExchange - Free Advertising Network Stock Research at Internet Speed

Re: How to work out which script to call to Save


>> >
>> >
>> >
>> >
>> >
 List
Subject: Re: How to work out which script to call to Save
Poster: ErwinMollersince_humans_read_this_I_am_spammed_too_much@spamyourself.com
Date: Fri, 23 Mar 2007 16:29:25 +0100
Related Postings: 1 2 3
Angus wrote:


> On 23 Mar, 14:57, "femto" wrote:
>> I don't get you, if you want to call a method in .js,
>> you just call it. Check out the reference.
>>
>>
>>
>> Angus wrote:
>> > I have a web page with a toolbar containing a Save button. The Save
>> > button can change contextually to be a Search button in some cases.
>> > Hence the button name searchsavechanges.
>>
>> > The snippet of html is:
>>
>> >
>> > style="position:static">
>> >


>> >

>>
>> > I want to call a script which will save the 'record' if you understand
>> > me. But all I see is .js files. Can I call these .js methods from
>> > javascript? If so how? Or if not is there any way, in javascript or
>> > some code I can save the 'record' (obviously, I can manually click on
>> > the Save button - but want to achieve this in code).
>>
>> > The full page appears below:
>>
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> > style="display:none">
>>
>> >
Current mode:
>> > class="TBTopBarStatusMode">

>> >
>> > src="../../../../resources/images/tb_right.gif" />
>> > src="../../../../resources/images/tb_down.gif" />

>> > cellpadding=0 cellspacing=0 class="Toolbar">

>> > class="TBGroup TBGroup0">
>>
>> >
>> > style="position:static">
>> >
Search

>> >

>>
>> >

>> >
>> > style="position:static">
>> >
Status history

>> >

>> >

>> >
>> > style="position:static">
>> >
Home

>> >

>> >

>> >
>> >

>> >

>> > class="arfid1020 ardbnCustomResultsList" style="top:2; left:2; width:
>> > 636; height:60;visibility:hidden;z-index:0;"
>> > ARCols="536890911,536890912,536890913,536890914,536890915,536890916,5368909­ 17"
>> > ARColWs="112,70,112,112,140,70,140" ARDrill=1 ARServer="@"
>> > ARSchema="@" ARMaxRows=0 ARDType=1 ARCSize=0 ARFixHdr=1 ARSelRows=0
>> > ARSelInit=0 ARSelRefresh=0 ARAutoFit=0 ARSort=""
>> > ARQual="{qual:"", ids:[],extids:[]}">
>> > >
>> > class="TableSortImgDown" ARInDOM=1 />

>> > class='TableHdr' cellpadding=0 cellspacing=0>

>> > valign=middle class='TableHdrL'>

>> > class='TableHdrR'>

>> > class='TableInner'>

>> > cellpadding=0 cellspacing=0>

>> > class='TableFtrL'>

>> > td>

>> >
>> >

>> >

>> >

>> >

>> > >> > /
>>
>> >

>> >
 

>> >

>> >
>> >

>> >

>> > class="df arfid240000005 ardbnRequesterLoginName+" style="z-index:
>> > 1041;top:86; left:136; width:236; height:21;">
>> >
>> >

>> >

>> >
>> >

>> >
>> > ARDBN="O2_btnAuthenticate" class="btn btn3d arfid660000281
>> > ardbnO2_btnAuthenticate" style="top:157; left:177; width:78; height:
>> > 21;z-index:1044;">
Authenticate

>> >

>> >

>> >
>> > ARDBN="O2_btnAuthenticationNotReq" class="btn btn3d arfid660000500
>> > ardbnO2_btnAuthenticationNotReq" style="top:157; left:288; width:78;
>> > height:21;z-index:1045;">

>> >

>> >
>> > ARDBN="btn_OrdersNew" class="btn btnurl arfid640000007
>> > ardbnbtn_OrdersNew" style="top:200; left:4; width:128; height:20;z-
>> > index:1030;background-color:transparent;">

>> > style="top:0; left:0; width:128; height:20;">

>> > style="text-align:left;;width:128">New Order

>> >

>> >

>> >
>> > ARDBN="btn_OrdersSearch" class="btn btnurl arfid640000008
>> > ardbnbtn_OrdersSearch" style="top:230; left:4; width:128; height:20;z-
>> > index:1031;background-color:transparent;">

>> > style="top:0; left:0; width:128; height:20;">

>> > style="text-align:left;;width:128">Search Order

>> >

>> >

>> >

>> >
>> >

>> >

>> > class="arfid300000050 ardbntxt_banner trimdiv" style="z-index:
>> > 1005;background-color:transparent;top:15; left:250; width:410; height:
>> > 35;">
>> >
>> > cellpadding=0 cellspacing=0>
>> >
>> >
>> >
Remedy IT Service Management for the&nb­ sp;Enterprise>> > td>
>> >

>> >

>> >
>> > ARDBN="O2_btnOrganisation" class="btn btn3d arfid750000000
>> > ardbnO2_btnOrganisation" style="top:87; left:376; width:45; height:-
>> > Hide quoted text -
>>
>> - Show quoted text -...
>>
>> read more »
>
> But what function do I call? If the function is not defined on the
> web page, can I still call it - eg it is a script on the server? If
> so how?

Hi,

Without looking through your huge script, a few pointers: If you need some JS functions in your script, include them. Two ways: 1) serverside: when you spit out the HTML make sure you output the JS functions too. 2) Clientside Let the browser get the needed JS. Simply add this:

Now all the JS defined in that file is included in your script.

PS: using is not advised.

Regards, Erwin Moller

 

Page2Go2.com is not responsible for content of this message.