Forums

[resolved] [Plugin: SubHeading] subtag :) (5 posts)

  1. blazeblaze
    Member
    Posted 2 years ago #

    Hi again :D

    Now this will be outrageous idea :) Prepare yourself :)

    I'm asking you about this, because you've managed to create plugin that displays subheading in the front page, where all posts are grouped together (thanks).

    Please look at this screen: http://img10.imageshack.us/img10/3268/mwsnap016.jpg

    Is it possible to do that with SUBheading? :)

    Cheers :)
    Tom

    http://wordpress.org/extend/plugins/subheading/

  2. Steve
    Member
    Posted 2 years ago #

    Hello again :)

    I think this may be above and beyond the capability of SubHeading unfortunately. It seems a little too abstract to extend it this far.

    Are there not any other possible plugins to achieve this?

    Maybe something along the lines of http://wordpress.org/extend/plugins/post-links/ - although I have not used this myself.

  3. blazeblaze
    Member
    Posted 2 years ago #

    Hi 36flavours :)

    It works! :O I've managed to wrap the links in a div tag. Now I'm struggling like Sisyphus with attaching span tag to each of those two links :|

    Here’s a test page:
    http://gry-rekreacyjne.pl/recenzje/zrecznosciowe/a-ball-recenzja/

    At the botton there are two links genrated by post-link plugin: gry rekreacyjne and gry casual.

    Unfotunately I have no idea how to make links wrapped by span tag each. For example the first link would ALWAYS have span tag=”pobierz” and the second one =”online”.

    If you know how to do that, please teach me by an example.

    Ultimately we would like to separate those two links so they are in one line but one of them would be on the right styled with button and the other one on the left, but I think I will manage to do it (hopefuly!) by reading tutorials online, after they have different span classes.

    I've wiritten about it on author's homepage, but if you are able to help and have time to write about it, please drop a line here.

    Also thanks again for pointing to this plugin! It works on WP 2.8.4 :)

  4. blazeblaze
    Member
    Posted 2 years ago #

    Hi!

    Unfortunately this plugin didn't help me because I couldn't customize the output in any way.

    So I was reading about custom fields like crazy, tried a dozen of possibilities and... my site stopped working :)

    Luckily I had a backup and couple of hours after that and a few another crashdowns I've finally found a sollution.

    A very simple one :O

    at the begining of index.php you just have to put the loop code and then for example

    $something = get_post_meta($post->ID, 'Name of the custom field', $single = true);

    close the loop

    and then in any part of index.php you want it's enough to write:

    <?php if($something !== '') { ?>
    <a href="<?php echo get_post_meta($post->ID, 'Name of the custom field', true); ?>"><img class="url_img" src="/wp-content/picture.gif"/></a>
    <?php } ?>

    The if is necessary if you don't want to have this button all over your site :)
    The a href gives you already the output in a form of hyperlink so in the custom field you just write an url(!) and the img clas allows you to customize the button however you want via CSS.

    Repeat in single.php

    Voila! :)

  5. blazeblaze
    Member
    Posted 2 years ago #

    Sorry for the mistakes : /

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags