Last modified: 2011-03-13 18:05:44 UTC
Verifiable links to anchors would allow a "What links here" function for anchors and would allow to mark references to nonexistent anchors like links to nonexistent pages. This would make setting and removing links to anchors in pages much more convenient. Optionally: * A move/rename section function could allow to move a section/anchor into another page or to raise it to an independent page or sub-page, optionally redirecting all references in other pages to the new name.
*** This bug has been marked as a duplicate of 8955 ***
I don't know the database structure but assuming ever page has a primary key sequence called p_id you would just have to CREATE TABLE anchor ( a_id int primary key, p_id int references page (p_id), a_name varchar (100), a_deleted boolean ); CREATE TABLE anchor_ref ( a_id int references anchor (a_id), p_id int references page (p_id), ); The changes to database structure mentioned in bug #8955 seem to be very minor. I'm not suggesting the same (supposedly extremely fragile interface) as in bug #8955. I'm suggesting a "What links here" function as for pages. If that interface is bad why is it in use? The suggested method would even allow to pick up dangling pointers to deleted anchors, because once an anchor entry existed and had anchor_refs pointing to it it could not be deleted, the anchor would merely be set to "a_deleted = true". I do think it is worth the effort. Broken references to anchors can be a nuisance for editors.
You wouldn't have to guess what "the same section is" (see bug #8928#c2). An editor could rename a section and pick up the dangling pointers afterwards or use a function to rename a section.
It has been established that the database schema changes this requires will not be made.