/    Sign up×
Community /Pin to ProfileBookmark

java script + java script

Hi All

/lib/js1.js
…….

function MsgBox(msg) {
alert(msg);
}

/menu/js2.js
…………….

function Save(id) {
MsgBox(‘success’);
}

js2.js…MsgBox(‘success’); – is not working…

Thanks

Madhu Alagu

to post a comment
JavaScript

6 Comments(s)

Copy linkTweet thisAlerts:
@FangNov 19.2007 — When and where are you calling [I]MsgBox('success');[/I] ?
Copy linkTweet thisAlerts:
@almadhuauthorNov 19.2007 — /menu/js2.js

................


function Save(id) {

MsgBox('success');

}
Copy linkTweet thisAlerts:
@FangNov 19.2007 — so when do you call [I]Save(id)[/I] ?
Copy linkTweet thisAlerts:
@almadhuauthorNov 19.2007 — <html>

<body>

<script type="text/javascript" src="/menu/js2.js"></script>

<input type="text" id="id" value="125">

<button onclick="Save('123')">Copy Text</button>

</body>

</html>
Copy linkTweet thisAlerts:
@FangNov 19.2007 — &lt;html&gt;
&lt;body&gt;
[COLOR="Green"]&lt;script type="text/javascript" src="/lib/js1.js"&gt;&lt;/script&gt;[/COLOR]
&lt;script type="text/javascript" src="/menu/js2.js"&gt;&lt;/script&gt;
&lt;input type="text" id="id" value="125"&gt;
&lt;button onclick="Save('123')"&gt;Copy Text&lt;/button&gt;
&lt;/body&gt;
&lt;/html&gt;
Copy linkTweet thisAlerts:
@almadhuauthorNov 19.2007 — Thanks
×

Success!

Help @almadhu spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...