Uncaught SyntaxError: Unexpected token ILLEGAL

Gabriele Santise

Nuovo Utente
1 Set 2014
1
0
0
Ciao a tutti, sono nuovo di questo forum . Il mio problema è il seguente: ho messo in piedi un piccolo sito web per la consultazione e l'aggiornamento di un Db. La tecnologia usata è:
- Mysql 5.5
- Apache Server 2.0
- PHP 5.2.11
- come frontend ho utilizzato un opensource

ho un problema Javascript con una schermata (quella che dovrebbe consentire di visualizzare le tabelle, fare ricerche tra i record, inserire nuovi record, ecc); utilizzando la Console Jvs di Chrome i messaggi di errore sono i seguenti:

1)Uncaught SyntaxError: Unexpected token ILLEGAL scheda.php:56
2)Uncaught ReferenceError: tendineAttese is not defined proto-scheda.js:1169
inizializza_pulsanti_modifica proto-scheda.js:1169
(anonymous function) scheda.php?oid=1:490
3)Uncaught ReferenceError: fck_attivo is not defined proto-scheda.js:2272

il numero 1) si riferisce alla seguente stringa (copio da Console jvs):

var pathRelativo='\';

nel file sorgente lo script riporta:

var pathRelativo='".$pathRelativo."' (riga 1192)

alla riga 1144 trovo, sempre nel file sorgente, :

$pathRelativo = (dirname($_SERVER['PHP_SELF'])=='/') ? "" : dirname($_SERVER['PHP_SELF']);

Come posso risolvere?

grazie
 

criric

Super Moderatore
Membro dello Staff
SUPER MOD
MOD
21 Ago 2010
5.607
54
48
TN
Ciao, stai confondendo javascript con php
var pathRelativo='".$pathRelativo."'
var pathRelativo : dichiarazione javascript di una variabile
$pathRelativo : dichiarazione php di una variabile

ps:
duplicare la stessa discussione in più sezione del forum è vietato dal nostro regolamento. dagli una letta
 
Ultima modifica:
Discussioni simili
Autore Titolo Forum Risposte Data
R Aiuto: Uncaught SyntaxError: Unexpected token WordPress 2
A Uncaught Error: jQuery 1
F Uncaught (in promise) Error: 3000ms timeout exceeded Javascript 0
T [PHP] aiuto....Fatal error: Uncaught Error:non riesco a capire PHP 1
G Fatal error: Uncaught Error: Call to undefined method UserController PHP 0
V Uncaught TypeError: Failed to execute Javascript 0
Marcolotto HTMLCollection: Uncaught TypeError: Illegal constructor Javascript 0
B Uncaught TypeError: Cannot read property Javascript 7
A Uncaught TypeError: Object [object Object] has no method 'cycle' jQuery 1
G Fatal error: Uncaught exception 'PDOException' PHP 12
N [PHP] ERRORE: SyntaxError: Unexpected token N in JSON at position 1 PHP 0
W Parse error: syntax error, unexpected '$result' (T_VARIABLE) PHP 4
B Errore unexpected '$variabile' (T_VARIABLE) in your code on line PHP 2
G unexpected '$conn' (T_VARIABLE) PHP 2
G [WordPress] [PHP] Parse error: syntax error, unexpected '$x332cbce1' WordPress 2
T [PHP] errore unexpected T_LNUMBER che non so interpretare PHP 6
U [PHP] Parse error: syntax error, unexpected variabile (T_VARIABLE) PHP 8
ANDREA20 [PHP] syntax error, unexpected PHP 4
ANDREA20 [PHP] syntax error, unexpected T_ELSE [era]urgentissimo] PHP 15
A [PHP] syntax error, unexpected T_STRING su html PHP 11
G Parse error: syntax error, unexpected '=' PHP 2
gandalf1959 Parse error: syntax error, unexpected T_VARIABLE PHP 2
Z Parse error: syntax error, unexpected 'parts' (T_STRING), expecting ',' or ';' PHP 2
O unexpected 'â' PHP 4
T Nuova installazione vB: Parse error: syntax error, unexpected T_STRING ... CMS (Content Management System) 0
K Parse error: syntax error, unexpected $end PHP 2
H Parse error: syntax error, unexpected T_SL in /membri/sito/pagina.php... PHP 2
M parse error:syntax error,unexpected T_STRING PHP 2
IerardiMario Unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' PHP 6
L syntax error, unexpected T_VARIABLE ??? PHP 1
P Parse error: syntax error, unexpected T_STRING on line 5 PHP 7
J Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in PHP 3
N Parse error: syntax error, unexpected T_VARIABLE Piccolo Aiutino :) PHP 0
L Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' PHP 1
M Errore unexpected T_VARIABLE PHP 0

Discussioni simili