#7182 closed defect (fixed)
Editor: link dialog should insert http:// if user doesn't type it
Reported by: | bill | Owned by: | Jared Jurkiewicz |
---|---|---|---|
Priority: | high | Milestone: | 1.4 |
Component: | Editor | Version: | 1.1.1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
In 1.0, the link dialog inserts http://
when the user doesn't type it, so that typing "www.dojotoolkit.org" into the dialog produces a valid URL.
See http://bugs.dojotoolkit.org/browser/dijit/trunk/_editor/plugins/LinkDialog.js?rev=11172
getValue: function(){ if(!/^(https?|ftps?)/.test(this.textbox.value)){ this.textbox.value="http://"+this.textbox.value; } return this.textbox.value; }
This regressed in 1.1, and should be added back.
The negative side is that if a site wants to allow users insert a relative URL they need to customize that plugin or write their own. But I'm OK w/that restriction since in that case almost all the time there should be a different kind of dialog, querying the server for available choices.
Change History (13)
comment:1 Changed 14 years ago by
comment:2 Changed 14 years ago by
Milestone: | 1.3 → tbd |
---|
comment:3 Changed 14 years ago by
Milestone: | tbd → 1.3 |
---|
comment:4 Changed 13 years ago by
Milestone: | 1.3 → 1.4 |
---|
1.3rc1 has been release; bumping remaining tickets to 1.4 (except for documentation/testing tickets)
comment:5 Changed 13 years ago by
Owner: | changed from Adam Peller to Jared Jurkiewicz |
---|
comment:8 Changed 13 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
(In [20305]) Unit tests for LinkDialog?. fixes #7182
comment:9 Changed 13 years ago by
(In [20307]) Unit tests for LinkDialog?, timing tweaks. fixes #7182
PS: seems like it would be easier/more portable to test for : but anything is OK w/me.