6.0.0-beta1
7/5/25

[#3824] Filenames containing a ' produce javascript errors
Summary Filenames containing a ' produce javascript errors
Queue Gollem
Queue Version HEAD
Type Bug
State Resolved
Priority 1. Low
Owners
Requester gus (at) pbx (dot) org
Created 04/24/2006 (7012 days ago)
Due
Updated 04/24/2006 (7012 days ago)
Assigned
Resolved 04/24/2006 (7012 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
04/24/2006 07:55:03 PM Chuck Hagenbuch Comment #2
State ⇒ Resolved
Reply to this comment
Fixed in CVS.
04/24/2006 05:37:29 PM gus (at) pbx (dot) org Comment #1
State ⇒ Unconfirmed
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ Filenames containing a ' produce javascript errors
Queue ⇒ Gollem
Reply to this comment
When browsing a directory containing a file with a ' in it, in IE it 
gives javascript errors.



I believe the bug stems from:

gollem/manager.php line 400:



$item['link'] = Horde::link('#', '', '', '', "view('$url', '" . 
$val['name']  . "'); return false;") . $name . '</a>';



where it is passing $val['name'] .. I have tried wrapping this in 
addslashes() and htmlspecialchars(,ENT_QUOTES)  however neither one of 
them fixes the errors, however there are no longer any 's in the 
string..



The _EXACT_ error in IE is:



Error: Expected ')'



the line it presents is never near one of the lines that has a 
filename with a single quote (possibly javascript document.write 
somewhere)



investigating further...

Saved Queries