Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jquery
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
夏彬
jquery
Commits
32f688d3
Commit
32f688d3
authored
Jan 17, 2007
by
Jörn Zaefferer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplified check for XMLHttpRequest (saving a few bytes) and fixed load()-test
parent
b98898d9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
ajax.js
src/ajax/ajax.js
+1
-1
ajaxTest.js
src/ajax/ajaxTest.js
+2
-2
No files found.
src/ajax/ajax.js
View file @
32f688d3
...
@@ -132,7 +132,7 @@ jQuery.fn.extend({
...
@@ -132,7 +132,7 @@ jQuery.fn.extend({
});
});
// If IE is used, create a wrapper for the XMLHttpRequest object
// If IE is used, create a wrapper for the XMLHttpRequest object
if
(
jQuery
.
browser
.
msie
&&
typeof
XMLHttpRequest
==
"undefined"
)
if
(
!
window
.
XMLHttpRequest
)
XMLHttpRequest
=
function
(){
XMLHttpRequest
=
function
(){
return
new
ActiveXObject
(
"Microsoft.XMLHTTP"
);
return
new
ActiveXObject
(
"Microsoft.XMLHTTP"
);
};
};
...
...
src/ajax/ajaxTest.js
View file @
32f688d3
...
@@ -70,8 +70,8 @@ test("load(String, Object, Function) - inject without callback", function() {
...
@@ -70,8 +70,8 @@ test("load(String, Object, Function) - inject without callback", function() {
test
(
"load(String, Object, Function) - check scripts"
,
function
()
{
test
(
"load(String, Object, Function) - check scripts"
,
function
()
{
expect
(
7
);
expect
(
7
);
stop
();
stop
();
var
testFoo
=
undefined
;
window
.
testFoo
=
undefined
;
foobar
=
null
;
window
.
foobar
=
null
;
var
verifyEvaluation
=
function
()
{
var
verifyEvaluation
=
function
()
{
ok
(
foobar
==
"bar"
,
'Check if script src was evaluated after load'
);
ok
(
foobar
==
"bar"
,
'Check if script src was evaluated after load'
);
ok
(
$
(
'#ap'
).
html
()
==
'bar'
,
'Check if script evaluation has modified DOM'
);
ok
(
$
(
'#ap'
).
html
()
==
'bar'
,
'Check if script evaluation has modified DOM'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment