Closed (duplicate)
Project:
Drupal core
Version:
7.x-dev
Component:
base system
Priority:
Normal
Category:
Task
Assigned:
Reporter:
Created:
18 Aug 2005 at 17:23 UTC
Updated:
17 Mar 2008 at 12:50 UTC
Jump to comment: Most recent file
This is a patch which changes significantly the work of autocomplete. Instead of loading the full Drupal and using the menu system to find out the correct handler, we only bootstrap to the PAGE_CACHE phase, and load the necessary module only. Autocomplete functions need to check for permissions themselves!
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | autocomplete_14.patch | 11.12 KB | chx |
| #4 | autocomplete_0.php | 969 bytes | chx |
| #3 | autocomplete_13.patch | 11.14 KB | chx |
| #1 | autocomplete.php | 971 bytes | chx |
| autocomplete_12.patch | 11.08 KB | chx |
Comments
Comment #1
chx commentedHere is the autocomplete.php which makes this work.
Comment #2
walkah commented+1 for the functionality *BUT*
I'd like to see something similar used for files as well (i.e. private and/or permisisons on files) ... *and* i'd really rather see this incorporated into index.php ... i.e. a single end point. perhaps some $_GET (or safer for $_SESSION?) triggers that indicate bootstrap levels .
note gallery2 (i.e. http://gallery.menalto.com) uses a system sort of like this ... i.e. there is 2 init processes and for "item downloading" (i.e. fetching an image) only a partial init is done (enough to verify permissions).
that is to say - let's see if we can't generalize this to accomodate file fetching as well as ajax stuff, etc.
Comment #3
chx commentedI made a grave error which would've blown a security hole.
Comment #4
chx commentedautocomplete function name is hardwired.
Comment #5
chx commentedDoh, I left in a mention of $function.
Comment #6
praseodym commentedA more general solution would be prefered but I think it's a good thing to have this in as soon as possible. Main reasons are faster AJAX response (that is what AJAX is all about, isn't it?) and decreased server load.
Comment #7
chx commentedWhat you do not want is to load all modules. That means -- full menu can't be used, neither can be full node_access. This needs quite some thought.
I think the functionality here needs to be in Drupal 4.7 but more general stuff now needs to wait a release.
Comment #8
moshe weitzman commentedi can't decide if this is needed for 4.7 or not. i do agree that we need a more broad solution for 4.8.
how about we add a new bootstrap hook which is guaranteed to run during PAGE_CACHE phase? modules can handle the request from there. this idea is less than halkf baked but i think it is general enough to handle anyone who wants to do these mini page requests.
Comment #9
drummNo longer applies.
Comment #10
coreb commentedmoving from x.y.z to 6.x-dev version queue
Comment #11
wim leersMoving to 7.x-dev
Comment #12
wim leersIIRC, Drupal 7 will be able to set special menu callbacks, which will result in automatic light-weight bootstrapping. That would make this issue obsolete.
Comment #13
moshe weitzman commentedWell, it will if we can convince Dries to commit the registry patch. We are having trouble. Please add a thoughtful review at http://drupal.org/node/221964