zerocool

Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • in reply to: calendar widget – fast forward code problem and solution #750975
    zerocool
    Participant

    sorry, almost forgot that you replied.

    you can find the screenshot here https://www.dropbox.com/s/jhhyuij2ffziwlg/screenshot.jpg?dl=0

    the site in question is pcbeachspringbreak.com, about midway down the home page.

    obviously, the screenshot shows a slight difference in layout (the new version has thumbnails) … but i did the layout changes after i fixed the function. I replicated the problem and fixed it in the exact same way on another site too.

    in reply to: Week View for Widget #743799
    zerocool
    Participant

    This reply is private.

    in reply to: Week View for Widget #738731
    zerocool
    Participant

    i think i got it, the file i modified is widgets/mini-calendar/grid.php. Can someone take a quick look to make sure this is going to do what I want, whicch is to only show the row for this week? Here’s the code:

    <?php
    /**
    * Mini Calendar Widget Grid Template
    * This file loads the mini calendar widget grid
    *
    * Override this template in your own theme by creating a file at [your-theme]/tribe-events/widgets/mini-calendar/grid.php
    *
    * @package TribeEventsCalendar
    *
    */
    if ( !defined(‘ABSPATH’) ) { die(‘-1’); } ?>

    <?php
    $days_of_week = tribe_events_get_days_of_week(‘short’);
    $week = 0;

    ?>
    <div class=”tribe-mini-calendar-grid-wrapper”>
    <table class=”tribe-mini-calendar” <?php tribe_events_the_mini_calendar_header_attributes() ?>>
    <?php do_action( ‘tribe_events_mini_cal_before_header’ ); ?>
    <!–
    <thead class=”tribe-mini-calendar-nav”>
    <tr>
    <td colspan=”7″>
    <div>
    <?php tribe_events_the_mini_calendar_prev_link() ?>
    <span id=”tribe-mini-calendar-month”><?php tribe_events_the_mini_calendar_title() ?></span>
    <?php tribe_events_the_mini_calendar_next_link() ?>
    ” alt=”loading…” />
    </div>
    </td>
    </tr>
    </thead>
    –>
    <?php do_action( ‘tribe_events_mini_cal_after_header’ ); ?>
    <?php do_action( ‘tribe_events_mini_cal_before_the_grid’ ); ?>
    <!–
    <thead>
    <tr>
    <?php foreach($days_of_week as $day) : ?>
    <th class=”tribe-mini-calendar-dayofweek”><?php echo $day ?></th>
    <?php endforeach; ?>

    </tr>
    </thead>
    –>

    <tbody class=”hfeed vcalendar”>

    <tr>
    <?php while (tribe_events_have_month_days()) : tribe_events_the_month_day(); ?>
    <!–<?php if ($week != tribe_events_get_current_week()) : $week++; ?>
    </tr>
    <tr>
    <?php endif; ?>–>

    <?php if (tribe_events_get_current_week() == 1) : ?>

    <td class=”<?php tribe_events_the_month_day_classes() ?>”>
    <?php tribe_get_template_part( ‘pro/widgets/mini-calendar/single-day’ ) ?>
    </td>
    <?php endif; ?>
    <?php endwhile; ?>
    </tr>
    </tbody>
    <?php do_action( ‘tribe_events_mini_cal_after_the_grid’ ); ?>
    </table>
    </div> <!– .tribe-mini-calendar-grid-wrapper –>

    in reply to: calendar widget … change initial month #272868
    zerocool
    Participant
Viewing 4 posts - 1 through 4 (of 4 total)