Modify

Opened 15 years ago

Closed 15 years ago

#6025 closed enhancement (fixed)

[Patch] Headings should contain ids for anchors to work

Reported by: Mitar Owned by: osimons
Priority: normal Component: FullBlogPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

Posts and lists sections headings (h*) should contain ids for anchors to work.

Then it is possible to add to site.html to <head> something like:

<script type="text/javascript">
  jQuery(document).ready(function($) {
    $("#content").find("h1,h2,h3,h4,h5,h6").filter("[id]").addAnchor("Link to this section");
  });
</script>

to enable anchors.

Attachments (1)

anchor.patch (1.6 KB) - added by Mitar 15 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 15 years ago by Mitar

I am attaching a patch which adds ids. Post names are unique. Also sections in listings are. So we just have to take care of proper anchor names.

Changed 15 years ago by Mitar

Attachment: anchor.patch added

comment:2 Changed 15 years ago by Ryan J Ollos

Summary: Headings should contain ids for anchors to work[Patch] Headings should contain ids for anchors to work

I'd find this to be useful as well. Would you consider integrating into the trunk?

comment:3 Changed 15 years ago by Ryan J Ollos

It looks like this patch did not upload, as in #6022.

comment:4 Changed 15 years ago by osimons

Resolution: fixed
Status: newclosed

(In [7225]) FullBlogPlugin: Adding anchors to listings. Works for regular listings, archive and listings using macro. Thanks to mitar for suggestion and patch. Closes #6025.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain osimons.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.