#5822 closed (invalid)
Integration of Django and Ajax
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | Uncategorized | Version: | 0.96 |
Severity: | Keywords: | ||
Cc: | kalnasha@… | Triage Stage: | Unreviewed |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | UI/UX: |
Description
Hi,
This is Anusha. I am a beginner in using Django. My project's goal is to display dynamic webpages i.e, update the page contents periodically using AJAX technology. I am getting several doubts in the process.I created an application in which I am able to query a database and display the results (http://localhost/cricketInfo/Sachin would display all Sachins profile). But I dont understand how to dynamically update these contents. Assuming that the data modifications occur frequently, so providing dynamic views is of higher priority.
My first doubt is that, I didn't understand the underlying client-server architecture i.e, what modules are comprised by the server and client respectively.
Secondly,I am using LAMP virtual machine to run my application. Once I start the server(python manage.py runserver 8000), the requests are being accepted only on local machine i.e, I am able to view output only on local machine (http://localhost:8000/cricketInfo/Sachin). I am not able to view the results from any other machine browsers(http://IP:port/cricketInfo/Sachin). Is this because, I am using a virtual machine or should I make any modifications to settings.py or so?? What should I do to make the application accessible from anywhere as www.anu.com/cricketInfo/Sachin like a website.
Thirdly, I want to make automatic updates to the page contents periodically using AJAX. For this, should we integrate our AJAX code in templates i.e, html files i.e, html files act as clientside script? Does views.py act as serverside script? If it is so, in case of dynamic updates when we make a xmlHttpRequest how does the server make out which function should be executed in the views.py? [ As the AJAX request : xmlHttp.open("GET","server-side script -- views.py",true) ]
I donno if they are very silly doubts, but I am not able to proceed further. I would be very glad if you can clarify them for me.
Regards,
Anusha
Change History (2)
comment:1 by , 17 years ago
comment:2 by , 17 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Please don't ask this kind of end user support questions to the Django ticket system, it's used to track bugs to the source code of django itself. Post them to the django-users mailing list instead.