• gsiener

    (@gsiener)


    https://thesoundof.pullingthingsapart.com/
    That’s the site I’m building, it’s going to be an online music club for discussing music with friends (who are now scattered across the globe…) Anyway, the idea is that the post will have the album cover and possibly some text, but then we will use comments to discuss. I wanted an easy way to add thumbnails of the covers for use in the menu bar, and realized I could put thumbnails in the excerpts. I then saw Matt’s code for posting excerpts instead of the whole post, and pretty much shoehorned it into the menu.
    If you look at my site, you will quickly see the shortcomings. First, I put a functional version of this code on the page https://thesoundof.pullingthingsapart.com/covers.php, which I can then use with ?cat= to show different categories. I’m not really sure how to do this within the actual code. Second, I want the excerpts to link to their posts, but the only way I know of doing this is copying the permalink and making the link. Is there some code that I can paste in to automatically link the excerpt to the main post?
    Lastly, I want the excerpts being shown to be from a random category, and not related to the current posts. For example, the thumbnails shown correlate to the posts shown, because they are linked. How can I sever this tie between the posts and the menu excerpts?
    Any other suggestions would be greatly appreciated. Thank you
    Graham

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter gsiener

    (@gsiener)

    Well, I figured out the last problem. I added the code for permalinks and removed the hyperlink from the excerpts, and now the link represents the permalink even if I change the date or post title. Cool.

    Moderator Matt Mullenweg

    (@matt)

    What was your first problem?

    Thread Starter gsiener

    (@gsiener)

    Sorry for not being clear. The first problem is that when you click a specific post, the sidebar filters the thumbnail excerpts accordingly, so it only shows the excerpt of the current post. What I’d like to do is have the sidebar be independent of the content.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Controlling excerpt behaviour, help me with php’ is closed to new replies.