mirror of
https://github.com/vrana/adminer.git
synced 2025-08-08 07:36:44 +02:00
Escape JavaScript strings (bug #3093243)
This commit is contained in:
@@ -7,7 +7,7 @@ $table_pos_js = array();
|
||||
preg_match_all('~([^:]+):([-0-9.]+)x([-0-9.]+)(_|$)~', $_COOKIE["adminer_schema"], $matches, PREG_SET_ORDER); //! ':' in table name
|
||||
foreach ($matches as $i => $match) {
|
||||
$table_pos[$match[1]] = array($match[2], $match[3]);
|
||||
$table_pos_js[] = "\n\t'" . addcslashes($match[1], "\r\n'\\/") . "': [ $match[2], $match[3] ]";
|
||||
$table_pos_js[] = "\n\t'" . js_escape($match[1]) . "': [ $match[2], $match[3] ]";
|
||||
}
|
||||
|
||||
$top = 0;
|
||||
|
Reference in New Issue
Block a user