use of the <!--more--> tag (problems)

Soldato
Joined
26 May 2006
Posts
6,119
Location
Edinburgh
I have been asked to cut down the size of posts made on a website I designed using wordpress (Atahualpa 3.5.3 theme)

The client now wants post excerpts instead of full size news.

First I set the pages to be excerpts and to only be about 75 words.

They want there to be an image on the left and a consistent size of 180x180, then some text from the news with the rest being a "read more tag"

Now the problems I am having is this: I use tables to keep the alignment consistent.

so a general post for me is this:

<table>
<tr>
<td>
<180x180.image>
</td>
<td> (The full post of the text article here)
</td>
</tr>
</table>

If the text goes over 75 words, then it knocks the page completely to whack. The alignment goes off the page, which I think is due to the </table> tag getting cut off. due to the 75 word limit.

If I increase the word limit to fit the whole news article and try using a <!--more--> tag somewhere in the post. It doesn't work. The full post just continues to be posted.

Any ideas?

webpage is www.inveralmondchs.org

Working on the "news" section at the moment, but once I am happy with the format, this will be transferred to the home page.
 
First thing I would do would be to ditch the tables, they generally have no place in modern accessible web design (unless it's for a table of data) and are usually more hassle than anything as proven by your problem.

I always thought tables were recommended to keep alignments of text/pictures etc. How do you recommend I format a the text?
 
So do I add these two lines to my CSS page?

Code:
<div class="post-bodycopy clearfix" style="background: none repeat scroll 0 0 #F4F4F4;">
<div class="text" style="margin-left:200px">

?
 
Remove the style="" parts from the code above then to your CSS add:

Code:
.post-bodycopy {
background: none repeat scroll 0 0 #F4F4F4;
}

.text {
margin-left:200px;
}

(.text might be used elsewhere on the site, so to avoid that screwing everything up you might need to rename it)

Thanks for the help with the CSS. The problem remains with the <!--more--> tag being ignored unless the word limit is reached. :(
 
examplecode.jpg

themesettings.jpg

doesntwork.jpg
 
Last edited:
The strangest thing just happened, I removed the news page and instead added the posts to the "home page" Now all the more tags work and they don't go off the page etc any-more.
 
Back
Top Bottom