Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Center area post/pages (http://forum.bytesforall.com/forumdisplay.php?f=32)
-   -   The post itself split in two columns (http://forum.bytesforall.com/showthread.php?t=18072)

ride2esc Jul 27, 2012 12:31 PM

The post itself split in two columns
 
1 Attachment(s)
Hello
Who can help me with a information?

I want some things.

The post (but only the post itself, not the category or other pages) to be split in 2 columns but by default.
In left column i want the text of the post, and in the right column i want to be the featured image with custom size as: 250x352.

Like in the printscreen I attached.
How i do that?
I use the latest WP and latest ATA.
Thanks in advance

Attachment 1961

lmilesw Jul 27, 2012 02:39 PM

Here are a couple of plugins that may help.
Site Layout Customizer
Drag and Drop Builder Plugin (their themes aren't as flexible as Atahualpa but I like their plugins)

ride2esc Jul 28, 2012 06:15 AM

Thanks lmilesw but i think is not what i would like.
I thought you can tell me what file i have to edit to arrange only the post to look like in my printscreen
Thank you

juggledad Jul 28, 2012 06:45 AM

if you want to do it within the theme, you will have to create a template to do it. You can use index.php as a basis and or look at the 'multi column/custom query' template (inclded as of 3.7.7) - you will have to do some custom editing.

ride2esc Jul 28, 2012 09:19 AM

I am not that good.
For index - i have a custom homepage.
I thought is like html:
A table:

<table width="500" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="250" height="94" valign="top">The left column for post with text and body..</td>
<td width="250" valign="top">The featured image with a custom width and height..</td>
</tr>
</table>

I just don't know what is the file to edit only for the post. Not for entire site. I like the categories and hompage.
Can anyone tell me how? or what will be the code to do that?
Thank you so much

lmilesw Jul 28, 2012 11:14 AM

It's not a matter of being "that good". That is the way a database driven site works. You would have to build a page template and apply it to the posts you want or use one of those plugins.

If you only want one post formatted a particular way though you could just use the HTML editor in the post and put in a table if you like.

ride2esc Jul 29, 2012 03:47 AM

Well no.
Those plugins dont help me.
I want my site to be ATA and to remain forever the posts in 2 columns.
Left column to be the text and right column to be the featured image.

I admit, I dont know codes, and wordpress insights.. but some html i know.
So if you're kind, please tell me this:
1. What file i have to modify to alter only the posts of my wp site?
2. What is the code for featured image, so I can insert it in right?
3. What is the code for text, where i insert the article in left side?

Thank you so much, for beeing so patience with dumbs like me :D

juggledad Jul 29, 2012 04:20 AM

Quote:

1. What file i have to modify to alter only the posts of my wp site?
you have two choices, you can modigfy index.php and wrap all your changes in a php test to see if you are dealing with a post or a page (remember a page is just a special type of post) or you can create a template and use that
Quote:

2. What is the code for featured image, so I can insert it in right?
off the top of my head, I don't know - you will need to read thru the wordpress codex to figure that out - same as I would have to do to tell you.
Quote:

3. What is the code for text, where i insert the article in left side?
the function for getting the post is 'the_content()' which is a wordpress function that is called to get the post.

If you are not a coder and don't know PHP then this could be a long process for you since you will have to learn them and do a bunch of testing and experimenting.

ride2esc Jul 29, 2012 04:50 AM

Quote:

If you are not a coder and don't know PHP then this could be a long process for you since you will have to learn them and do a bunch of testing and experimenting.
In this case..do you know where i can find a custom page to download with 2 column? i keep searching on google, but all of result are php tutorials..and as you anticipate in quoted text above, i don't know any php..

juggledad Jul 29, 2012 06:11 AM

Each theme is different an dtemplates are made for the theme. there is no template, that I know of, for Atahualpa that would do what you want becaues you have a unique situation.

the 'multi column/custom query' template can split the output to two column, but it splits the posts into two columns (post 1 goes in column 1 post 2 goes in column 2, post 3 goes in column 1 etc, etc) so it would not fill your needs

ride2esc Jul 29, 2012 06:59 AM

Somehow i made a few nice changes according to my needs.
I will post here what I have done, and maybe someone will get into the same issues as me.
And you ..correct me if I do something wrong or stupid.

So.
I add in function.php the following code:

PHP Code:

// Add support for Featured Images
if (function_exists('add_theme_support')) {
    
add_theme_support('post-thumbnails');
    
add_image_size('index-categories'6161false);
    
add_image_size('page-single'250352);
}
function 
InsertFeaturedImage($content) {
 
global 
$post;
 
$original_content $content;
 
    if ( 
current_theme_supports'post-thumbnails' ) ) {
 
        if ((
is_page()) || (is_single())) {
            
$content the_post_thumbnail('page-single');
            
$content .= $original_content;
            } else {
            
$content the_post_thumbnail('index-categories');
            
$content .= $original_content;
        }
 
    }
    return 
$content;
}
 
add_filter'the_content''InsertFeaturedImage' ); 


In CSS Insertion i add the following code:

PHP Code:

.attachment-page-single {
    
floatright;
    
margin12px 8px 8px 0px;   
    
max-width250px;
    
heightauto;
}
 
.
attachment-index-categories {
    
floatright;
    
margin12px 8px 8px 0px;
}
div.post-bodycopy  {
width:372px;



Then in ATA at Post & Pages > Post Thumbnails CSS i put:
PHP Code:

margin:-100px -265px 15px 0

After save.is almost ok.
However i have a few questions:
1. How i make the post featured image size to be width 250 and height as 352? (now is showing me a constrain proportions)
2. For home page, I have a custom homepage, where i insert 2 widgets, right and left. But how I make the featured image to dissapear from homepage?

The demo site is: http://erobu.eu/demo/tmevents3/

Thank you and I hope I did ok :D

So..i get somewhere. But i still have some issues.


All times are GMT -6. The time now is 07:52 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.