Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Montezuma Theme (http://forum.bytesforall.com/forumdisplay.php?f=53)
-   -   Remove date on pages and posts (http://forum.bytesforall.com/showthread.php?t=19834)

letsfigurethisout Mar 6, 2013 11:33 AM

Remove date on pages and posts
 
I'm trying to remove pages on posts and pages on the Montezuma Theme (1.1.3).

I'm not too savvy with code, but I really like the theme and am trying to figure out how to remove the date.

Can anyone help?
Please...thanks!

juggledad Mar 6, 2013 12:09 PM

look thru the theme options

letsfigurethisout Mar 6, 2013 12:48 PM

Hi,

Can you please be a bit more specific. I have and I can't seem to find anything.

lmilesw Mar 6, 2013 12:53 PM

In the theme option look at the postformat.php in "Sub Templates".

letsfigurethisout Mar 6, 2013 01:20 PM

Ah, I see it. Can you tell me exactly what code I am supposed to remove?

Thanks so much for your help!

This is what i see:
<div id="post-<?php the_ID(); ?>" <?php post_class( 'cf' ); ?>>

<h2>
<span class="post-format"></span>
<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>" rel="bookmark"><?php the_title(); ?></a>
<?php bfa_comments_popup_link( '0', '1', '%' ); ?>
</h2>

<?php bfa_thumb( 620, 180, true, '<div class="thumb-shadow"><div class="post-thumb">', '</div></div>' ); ?>

<div class="post-bodycopy cf">

<div class="post-date">
<p class="post-month"><?php the_time( 'M' ); ?></p>
<p class="post-day"><?php the_time( 'j' ); ?></p>
<p class="post-year"><?php the_time( 'Y' ); ?></p>
</div>

<?php bfa_excerpt( 55, ' ...' ); ?>

</div>

<div class="post-footer">
<a class="post-readmore" href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
<p class="post-categories"><?php the_category( ' &middot; ' ); ?></p>
<?php the_tags( '<p class="post-tags">', '', '</p>' ); ?>
</div>

</div>

juggledad Mar 6, 2013 02:45 PM

take a look of that code and tell me what part you think has to do with the date.

letsfigurethisout Mar 6, 2013 03:40 PM

So I removed:

<div class="post-date">
<p class="post-month"><?php the_time( 'M' ); ?></p>
<p class="post-day"><?php the_time( 'j' ); ?></p>
<p class="post-year"><?php the_time( 'Y' ); ?></p>
</div>

and it didn't work. I then went back in and did something wrong and had to access my database to restore wordpress (thanks to youtube video).

Did I take out too much? Not enough?

juggledad Mar 6, 2013 05:17 PM

that is exactly the code you should have taken out. (good job, pat your self on the back)

What did you do that was wrong causing you to need a db restore?

What is the url?
did you have a caching plugin active?

angelosbg Mar 10, 2013 12:28 AM

Sorry for getting into the conversation but this topic proved to be very helpful to me. I had also a problem with a cashing plugin and every time I was making changes I had to log out and login again in order to take effect.

What I would like to do is remove the date in the beginning of the article but put it in the end. In the beginning my code was like this

<div class="post-bodycopy cf">

<div class="post-date">
<p class="post-month"><?php the_time( 'M' ); ?></p>
<p class="post-day"><?php the_time( 'j' ); ?></p>
<p class="post-year"><?php the_time( 'Y' ); ?></p>
</div>

<?php bfa_excerpt( 55, ' ...' ); ?>

</div>

<div class="post-footer">
<a class="post-readmore" href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
<p class="post-categories"><?php the_category( ' &middot; ' ); ?></p>
<?php the_tags( '<p class="post-tags">', '', '</p>' ); ?>
</div>


Should I do it like this? Or else where should I put the date text?

</div>


<div class="post-bodycopy cf">

<?php bfa_excerpt( 55, ' ...' ); ?>

</div>

<div class="post-date">
<p class="post-month"><?php the_time( 'M' ); ?></p>
<p class="post-day"><?php the_time( 'j' ); ?></p>
<p class="post-year"><?php the_time( 'Y' ); ?></p>
</div>

<div class="post-footer">
<a class="post-readmore" href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
<?php _e( 'read more &rarr;', 'montezuma' ); ?></a>
<p class="post-categories"><?php the_category( ' &middot; ' ); ?></p>
<?php the_tags( '<p class="post-tags">', '', '</p>' ); ?>
</div>

</div>


Thanks a lot

juggledad Mar 10, 2013 04:43 AM

why don't you try it and report back?

angelosbg Mar 10, 2013 08:05 AM

But this way I noticed that we can remove the date from the articles on main page and not in the article. What I am interested to do is put the date inside the article at the end of it.

juggledad Mar 10, 2013 11:38 AM

the 'index.php' is used when looking at a multi post page. The 'single.php' is used when looking at a single post page.

angelosbg Mar 10, 2013 05:02 PM

Thanks a lot once again for your quick replies. The thing is that I still do not know how I can put the date of the post in the end of it.

juggledad Mar 10, 2013 06:21 PM

ok you have to understand how the WordPress hierarchy works and how this relates to Montezuma.

on a multi post page, index.php is run and it calls postformat.php
when a single post is displayed, it calls single.php
when a page is displayed, it calls page.php

so if you want to change the location for single posts and pages, you have to modify both single.php and page.php.

I hope this helps, now play with things, move some code around and remember is you really mess a template up, you can always press the button to reset that template (don't accidentally press the 'Reset all' button because that will reset everything.


All times are GMT -6. The time now is 08:11 PM.

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