简体   繁体   中英

Better for a chatroom app backend- Django or plain php?

I'm currently making the 2.0 version of my site that is currently a Django + ajax, php + ajax, and html + fake-ajax* based. Apart from the new features, I want to do allot of cleanup. My question is what do you think will put less load on the server, if I make my chat app backend using django or if I stick with php(what i have now)? My front end is html & jQuery, I would like to eventually do html5 sockets but my target audience are married to their ancient browsers. (I think with apple's denouncement of flash it will go extinct in a few years and for mobile only the latest android supports it and what i've seen dosen't really perform well, my current solution on the other hand runs EVERYWHERE! My friend could even use it from his ePaper Nook!). So I would like to do as much as possible in the same language rather than my hacked up solotion, but on the other hand my php stuff seems a little faster than the django stuff, but I don't have any direct app4app comparison, I only did the php chartroom because the flash 3rd party, service we had been using, sucked when it came to authorization. Also I didn't want to disturb my current django app until the whole rewrite(which is happening now!). Thanks for your input!

 *defination of fake-ajax(Read only if your curios):
 I was lazy and since content was small,
 I just have all my pages in vars on a single html page and us jQuery 
 to change the content of the content-div to whatever the user clicked from 
 the menu :-D(don't wory none of the content in vars needed to be seen by search engines)

Just use whichever language you're most comfortable with. Chances are the performance differences wont have a huge impact. Either way, with Python or PHP you can fix most of the performance stuff if you know what you're doing.

Django will give you ready-made authorization and registration. It will not help create the chat window itself, though.

If Django seemed too complex for me, I'd take a look at something smaller, like Flask or web.py .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM