> -----Original Message----- > From: Ashley Sheridan [mailto:ash@xxxxxxxxxxxxxxxxxxxx] > Sent: Thursday, February 05, 2015 1:42 AM > To: Christoph Becker > Cc: hadi; php-general@xxxxxxxxxxxxx > Subject: Re: connecting php long-polling to the database > > On Wed, 2015-02-04 at 22:36 +0100, Christoph Becker wrote: > > hadi wrote: > > > > > SCRIPT1014: Invalid character > > > File: jquery.min.js, Line: 4, Column: 15725 > > > > So, obviously, there is an error in jquery.min.js. You should inspect > > the file, and maybe download it again. > > > > -- > > Christoph M. Becker > > > > > > If you notice from the original post, the jQuery in use here is actually coming > from an external CDN, so not likely to be serving up a bad file. > > The main problem with JavaScript is that error messages are useless in the > language, as shown here. > > I'm not sure what the actual issue is though, the code appears to be ok. > Have you tried commenting out the parts of it at a time to see where any > issues might lie? Ash, In firefox debugger it show the error in sql query. Can you have a look please I opened firefox and inspect the error . Here is the error from firefox Error: http://code.jquery.com/jquery.min.js is being assigned a //# sourceMappingURL, but already has one The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must be declared in the document or in the transfer protocol. index.html GET http://192.168.206.129/record/server.php [HTTP/1.1 200 OK 7ms] SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data <br /> <b>Parse error</b>: syntax error, unexpected T_WHILE in <b>/var/www/html/record/server.php</b> on line <b>53</b><br /> Here the error in pointing to line 53 at my server.php script which is sql query 53 $data = while($row = mysqli_fetch_array($result1)) 54 55 56 { 57 58 echo "<tr>"; 59 echo "<td>" . $row['name'] . "</td>"; 60 echo "<td>" . $row['lastname'] . "</td>"; 61 echo "</tr>"; 62 63 64 65 66 67 68 } > > -- > Thanks, > Ash > http://www.ashleysheridan.co.uk > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php