How to get images to display next to Categories
How to get images to display next to Categories
I have added an image, but it does not display on the main page... should i refresh a template or something? how do i get the images to display next to the categories?
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact:
yes i have added an image to an category. there where you create a new category, if you edit that new one, it gives you the option "image". Then i uploaded a small pic via the media, into the gallery, then from the "IMAGE" option in the category edit page i select that image. but nothing is displayed in the categories sidebar, and thats where i actually want them.
i am using i3theme
i am using i3theme
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact:
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact:
Wow,
http://www.optional-necessity.com/uploa ... plates.png
and.. what is the default dimensions here [[ 60px × 64px ?? ]] like yours?
or s9y will automatically resize it?
will it be always listed on top right corner of each post? can i change that to bottom left?
Thanks
http://www.optional-necessity.com/uploa ... plates.png
and.. what is the default dimensions here [[ 60px × 64px ?? ]] like yours?
or s9y will automatically resize it?
will it be always listed on top right corner of each post? can i change that to bottom left?
Thanks
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact:
There is no default to the category image/icon. I created my own using images from the same icon pack s9y used on the backend combined with a bit of my own tinkering in photoshop.
Placement is dependent on a) your template's entries.tpl file, and b) css. I wrote my own template based on bulletproof, however, the default template has this code for the category icons:
Immediately after that, is the entry body:
The default template's stylesheet has this (don't ask me why, but its in the stylesheet twice...):
So, if you put that all together, the icon will be rendered first, then entry body. Since the icon is floated right, it will appear exactly the same as my own site.
If you wanted it left, you would float it left. I personally feel it would be confusing at the bottom of the entry, but if that is where you wanted it, I think simply placing the code to occur after entry body should be sufficient, but I have not tested that.
Placement is dependent on a) your template's entries.tpl file, and b) css. I wrote my own template based on bulletproof, however, the default template has this code for the category icons:
Code: Select all
{if $entry.categories}
<span class="serendipity_entryIcon">
{foreach from=$entry.categories item="entry_category"}
{if $entry_category.category_icon}
<a href="{$entry_category.category_link}"><img class="serendipity_entryIcon" title="{$entry_category.category_name|@escape}{$entry_category.category_description|@emptyPrefix}" alt="{$entry_category.category_name|@escape}" src="{$entry_category.category_icon}" /></a>
{/if}
{/foreach}
</span>
{/if}
Code: Select all
<div class="serendipity_entry_body">
{$entry.body}
</div>
Code: Select all
img.serendipity_entryIcon {
float: right;
border: 0px;
}
If you wanted it left, you would float it left. I personally feel it would be confusing at the bottom of the entry, but if that is where you wanted it, I think simply placing the code to occur after entry body should be sufficient, but I have not tested that.
=Don=
thats where i saw it. I hope that im not breaking any laws by wanting my blog to look very close to that of pigslipstick...akremedy wrote:
I've recently moved to Serendipity from what became a mostly home-grown (by way of re-invention) blog package. I became tired of the monumental, and lonely dev effort. So much effort went into development, that there was no time/interest in actually posting content.
I'm very satisfied with the flexibility, performance, and feature/functionality of Serendipity.
I'm still doing a lot of fine tuning, but figured I'd go ahead and post a link here: http://www.pigslipstick.com
Hi Werner,
I'm happy to help - BTW, check your email for a couple of items that I sent off this morning regarding the login and calendar styling...if you didn't receive anything from me, please let me know.
Here's a post that explains the categories.tpl mod that I made to get the category icons to show up in the Categories list (see item 2 in the post):
http://www.pigslipstick.com/index.php?/ ... hacks.html
... as well as to reposition the corresponding category icon to float right of the blog entry title:
http://www.pigslipstick.com/index.php?/ ... -edit.html
Just remember to stick with icons that consistent in size, and you should be all set.
Hope that helps!
Adam
I'm happy to help - BTW, check your email for a couple of items that I sent off this morning regarding the login and calendar styling...if you didn't receive anything from me, please let me know.
Here's a post that explains the categories.tpl mod that I made to get the category icons to show up in the Categories list (see item 2 in the post):
http://www.pigslipstick.com/index.php?/ ... hacks.html
... as well as to reposition the corresponding category icon to float right of the blog entry title:
http://www.pigslipstick.com/index.php?/ ... -edit.html
Just remember to stick with icons that consistent in size, and you should be all set.
Hope that helps!
Adam