joni2back / spachat

:speech_balloon: Single Page Application Angular Chat
https://spachat.zendelsolutions.com
49 stars 23 forks source link

Spachat on codeigniter #3

Open sdaverede opened 8 years ago

sdaverede commented 8 years ago

Hi guys! Thanks for making this awesome chat!

I'm having some serious troubles with the implementation of the chat on a codeigniter environment, i've got to work the chat outside the website with no single trouble, but when it comes to insert it into my codeigniter page, i get the popular "SyntaxError: Unexpected token < in JSON at position 0"

The problem itself is that i'm not able to see any message on the list, but i can normally send messages, and recieve them on realtime on an outside-my-web script working standalone connected to the same db.

Just in case, i'm placing it like this: <?php require_once("external/spachat.php"); ?>

(sorry in advance for my bad english)

joni2back commented 8 years ago

Hi @sdaverede , first of all, the idea of spachat project is to have just 1 file to do everything. If you want to include in an existant project or framework, you will need to migrate each class to new php files, then the same with the html template.. js and css. Regards