From: Erik <er...@bo...> - 2004-03-21 17:57:57
|
Hi I really like the edit_page online function but it misses some functions that I like to add.=20 First out; I don't like that it put links where each component ends. That placement gets a strange effects. I use several layers (divs) so the edit links get placed all over the place (and under some of my boxies). I propose that the edit links get placed collected on the page and the layout are up to the author of the page. My idea is that the links get placed where the tag <PKIT_EDIT_PLACEHOLDER> are. And if pkit_admin=3Don it includes pkit_edit/placeholder.tmpl. If there are no <PKIT_EDIT_PLACEHOLDER> It get placed last on the page. And if the=20 pkit_edit/placeholder.tmpl don't exist do one of: * nothing * warn the user that there are no file to include * use a simpel layout from within. The code in pkit_edit/placeholder.tmpl might look like this: <MODEL_IF name=3D"PKIT_EDIT_LINKS"> <div class=3D"menu-shadow"><div class=3D"menu-box"> <h2>Redigera sidan</h2> <ul> <MODEL_LOOP name=3D"PKIT_EDIT_LINKS"> <li> <a href=3D"/pagekit/<MODEL_VAR name=3D"PKIT_EDIT_URL">"> <MODEL_VAR name=3D"PKIT_EDIT_FILENAME"></a></li> </MODEL_LOOP> </ul> </div></div> </MODEL_IF> where PKIT_EDIT_LINKS generates from within pagekit::Edit or so and contains hashes with PKIT_EDIT_URL and PKIT_EDIT_FILENAME to be used in a useful way :) The reason to not to generate a hole link are as shown in the example that pagekit might not be the have control over the hole site (In my site I have two apache servers, one with and one without mod_perl).=20 Second; pkit_edit asume that it are the sole server and not as in my place on a different server and are called with /pagekit/ as a prefix. The sugested sulotion above fix that. Comments?=20 Suggestions?=20 ETA? :) =20 --=20 Erik G=FCnther <er...@bo...> |