sjol, this is fairly easy to do on some level. We have django integrated into a PHP site for the Python Conference: http://us.pycon.org/
All the django apps are under 1 root url '/apps07/' This is the easiest way to integrate things in the beginning. By having a specific root all the django stuff is under and have the rest of the site served up using other means. this means that you only need to make a minor config change to your apache config, or whatever server you are using. You can set up django as the root of a site and then pick out specific url's and subdirectories to be handled separately in your apache config, but this is much more work. Django can serve up static files, to spawn the applications, but this is not recommended in general. having mod_php do the work for the php files is MUCH better. For integrating with PHP I have a PHP template loader for django which spawns the PHP process to capture the base template. The output is then cached so yoyu are not spawning a php instance per request. The code is here: https://svn.python.org/conference/django/trunk/pycon/template/loaders/php.py And there is a screen capture which goes into a fair amoutn of detail on how to set this up: http://www.showmedo.com/videos/video?name=pythonNapleonePyConTech2&fromSeriesID=54 We are also working on a wget template loader for loading pages from other sites. Don't know if I want to give this out as it would make phishing a whole lot easier for some bad people. It is needed internally so we can have a single skin across multiple disjoint projects where we do not have access to the html code (gotta love big companies.... not...). Hope that helps! -Doug On Apr 12, 3:50 pm, "sjol" <[EMAIL PROTECTED]> wrote: > Hi, > > I would like to integrate Django to an "old" site. By this I mean that > reworking the whole site from scratch will not be possible I have to > change it piece by piece. But I would like the first piece to be the > root but other parts of the URL would stay the same ( it is all php > code or jsp ). The sort of behavior I am looking to mimick is that of > Pylons when a file in it's public directory will be found if no > function exists (it will even be looked for first ) > a concrete example is : django would be plugged into / but still be > able to dispatch the request to /contact.php or /movies/index.php . > > How would I go about doing this without to much overhead as this > structure may stay in place for a while? or if you have any other > suggestions on how to proceed I am open to ideas. > > Regards, --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [EMAIL PROTECTED] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---