mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-05-10 08:55:00 -04:00
Added Sanitization logic for custom PadIDs
This commit is contained in:
parent
2d91d8e185
commit
8204b52f55
1 changed files with 2 additions and 1 deletions
|
@ -171,7 +171,8 @@
|
|||
<script>
|
||||
function go2Name()
|
||||
{
|
||||
var padname = document.getElementById("padname").value;
|
||||
|
||||
var padname = document.getElementById("padname").value.replace(/[^a-z0-9_\-]/gi, '_');
|
||||
padname.length > 0 ? window.location = "p/" + padname : alert("Please enter a name")
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue