WordPress.org

Forums

Bookmarks on another page (3 posts)

  1. Daven
    Member
    Posted 10 years ago #

    Okay, I have a slight problem. I can solve it, but I would like to be able to use the WordPress solution if I can.

    I'm using WordPress 1.5. I have been writing blog entries using it and then I had an idea, a page of terms I use a lot, defined. That would let me define the word on the fly, bookmark that definition and then link that definition to the post I'm making.

    When I implemented this through WordPress' "pages" feature, all seemed to go well. I used the Page function, defined the terms, put < a href = "whatever" > defined term < /a> (obviously without the spaces) and posted them all.

    What happened is that since I'm using the Permalinks feature too, I don't have a real page to link from.

    The glossary winds up looking like this: http://davensjournal.com/wordpress/glossary/#vanity Now normally it would be http://davensjournal.com/wordpress/glossary/PAGE.EXTENSION#vanity, but since it's in MySQL tables, there is no page to reference. So while it's pulling the proper page up, it's not moving to the bookmark referenced.

    Right now, there are less than 8 terms defined, but as I go it may turn into hundreds, and that would be a pain to scroll through. So I need a solution to this.

    Any help would be appreceiated.

  2. Kafkaesqui

    Posted 10 years ago #

    href is known as a hyperlink reference attribute, and only provides the link to a web document or other resource. What you need is what's referred to as a "fragment identifier" (the # in #vanity denotes it's a 'fragment' you're linking to).

    Change the definition headers on your glossary Page to:

    <strong id="whatever">defined term</strong>

    You could also use:

    <a id="whatever">defined term</a>

    Though the results are not always as expected... (for the text's formatting; the id will work).

    Note: You can use just about any HTML tag you choose with the id attribute.

  3. Daven
    Member
    Posted 10 years ago #

    THANK YOU Kafkaesqui! That's the ticket and it works exactly like I want it to.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.