Skip to content

Ajax.Request does nothing with empty url in some browsers #234

@jwestbrook

Description

@jwestbrook

previous lighthouse ticket #597
by Spezi


When calling

new Ajax.Request('', { parameters: 'do=something' })

(empty string for the first argument) the request is not sent, even no JavaScript error message appears. This also happens if the first argument is null. I wanted to use this to send an XHR to exactly the same page used for generating the output. If the first argument is ' ' (space) or '.' (dot), the request is sent, but that's just a workaround.

Tested with prototype 1.6.0.3 on Windows. In Firefox 3.0.7 and IE 7 the behavior is as described. For Opera 9.64 and Safari 3.2.2 the request is sent even with '' (empty string) but not with null for the first argument.

I attach a simple test environment for this using PHP. Just add prototype-1.6.0.3.js and call index.php.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions