marcodeltongo / thematic

Automatically exported from code.google.com/p/thematic
0 stars 0 forks source link

adding a class to a post #30

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I would like to add a class to all posts that already have the class p2 p4
p6 and so on (in opposition to p1 p3 p5, i can't remember the word, damn!)
I would like to float the div containers (two on every row) and I have to
set a proper margin only for one of the overmentioned divs. 

I don't know if this function already exists, I haven't found it anywhere
(it's probably my fault)...
at this moment, a post shows these classes and no one is useful:

hentry p1 post publish author-admin category-uncategorized untagged y2009
m02 d06 h22 

I know i could declare in the css p2, p4, etc but i would like to make it
indipendent from the number of posts people would like to show on a page.

any ideas?

Original issue reported on code.google.com by dannydam...@gmail.com on 7 Feb 2009 at 5:15

GoogleCodeExporter commented 9 years ago
Do you mean a class that's either 'even' or 'odd' depending on the post-id?

Original comment by chris.gossmann@googlemail.com on 7 Feb 2009 at 6:22

GoogleCodeExporter commented 9 years ago
that's right, even or odd(I haven't found the words!). but not only odd or 
even: a
custom class to a post (maybe in functions.php)

Original comment by dannydam...@gmail.com on 7 Feb 2009 at 6:45

GoogleCodeExporter commented 9 years ago
by the way: it could resolve also issue 18

Original comment by dannydam...@gmail.com on 7 Feb 2009 at 6:46

GoogleCodeExporter commented 9 years ago
Ok .. still haven't got it .. give me some more details .. is it a class 
depending on
the post-id, or on p(x) (which is post number on page)

.. These are the posts on your first page .. give me an example:

<div id="post-599" class="hentry p1 post publish author-danny
category-child-theme-per-thematic category-download-gratuiti
category-temi-per-wordpress category-thematic category-wordpress tag-child-theme
tag-thematic y2009 m02 d07 h17 slug-smoking-blue-e-disponibile-per-il-download">
</div>
<div id="post-593" class="hentry p2 post publish author-danny
category-segnalazione-articoli category-wordpress tag-wordpress-plug-in y2009 
m02 d07
h16 alt slug-plugin-per-social-bookmarking">
</div>
<div id="post-588" class="hentry p3 post publish author-danny
category-child-theme-per-thematic category-download-gratuiti
category-temi-per-wordpress category-thematic category-wordpress tag-child-theme
tag-thematic y2009 m02 d06 h22 slug-smoking-blue-child-theme-per-thematic">
</div>
<div id="post-576" class="hentry p4 post publish author-danny category-tutorial
category-wordpress tag-browser tag-css tag-css-naked-day y2009 m02 d06 h14 alt
slug-css-naked-day-2009">
</div>
<div id="post-568" class="hentry p5 post publish author-danny 
category-localizzazioni
category-wordpress tag-wordpress-plug-in y2009 m02 d06 h12
slug-aggiungere-alice-ok-notizie-a-sociable-per-wordpress">

and now the second page ..

<div id="post-565" class="hentry p1 post publish author-danny category-browsers
tag-css tag-iphone tag-safari y2009 m02 d06 h12
slug-webkit-supporta-ufficialmente-le-animazioni-css">
</div>
<div id="post-558" class="hentry p2 post publish author-danny
category-segnalazione-articoli category-wordpress tag-blogger y2009 m02 d05 h18 
alt
slug-wordpress-e-la-piattaforma-di-blogging-piu-usata">
</div>
<div id="post-501" class="hentry p3 post publish author-danny 
category-tipografia
tag-css y2009 m02 d05 h05 
slug-proprieta-font-weight-solo-un-browser-la-supporta">
</div>
<div id="post-495" class="hentry p4 post publish author-danny
category-download-gratuiti category-sfondi tag-pattern y2009 m02 d05 h03 alt
slug-web-design-ledger-pattern-per-tutti-i-gusti">
</div>
<div id="post-468" class="hentry p5 post publish author-danny
category-download-gratuiti category-tutorial category-wordpress 
tag-trucchi-wordpress
tag-wordpress-plug-in y2009 m02 d03 h16 slug-come-fare-numeriamo-i-commenti">

Original comment by chris.gossmann@googlemail.com on 7 Feb 2009 at 7:25

GoogleCodeExporter commented 9 years ago
Damn, I've just noticed the class "alt". 

so the odd or even question is closed.

Sorry Chris for wasting your time.

Danny

p.s: I owe you a beer

Original comment by dannydam...@gmail.com on 7 Feb 2009 at 7:34

GoogleCodeExporter commented 9 years ago
.. with Issue 18 still open :-)

Original comment by chris.gossmann@googlemail.com on 7 Feb 2009 at 7:41