Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Forum: Fixing WordPress
    In reply to: Any Ideas
    Thread Starter Chris

    (@chris2k12)

    Hi Geoffrey

    Thank you for the fast reply, much apprecaited, it didn’t look right to me and I checked the core files from a fresh downloaded version and it didn’t have it.

    I’ll follw your suggested links and see how we go.

    Once again Thank you

    Hi Guys
    I have been trying to do the same and have found a solution, took ages to find it.
    go to general-template.php, around about line 1241

    change this:

    if ( $day == gmdate('j', current_time('timestamp')) && $thismonth == gmdate('m', current_time('timestamp')) && $thisyear == gmdate('Y', current_time('timestamp')) )
    			$calendar_output .= '<td id="today">';
    		else
    			$calendar_output .= '<td>';
    
    		if ( in_array($day, $daywithpost) ) // any posts today?
    				$calendar_output .= '<a href="' . get_day_link( $thisyear, $thismonth, $day ) . '" title="' . esc_attr( $ak_titles_for_day[ $day ] ) . "\">$day</a>";
    		else
    			$calendar_output .= $day;
    		$calendar_output .= '</td>';

    to:

    if ( $day == gmdate('j', current_time('timestamp')) && $thismonth == gmdate('m', current_time('timestamp')) && $thisyear == gmdate('Y', current_time('timestamp')) )
    			$calendar_output .= '<td id="today"';
    		else
    		    $calendar_output .= '<td';
            if ( in_array( $day, $daywithpost ) ) // any posts today?
               $calendar_output .= ' class="with-post"';
               $calendar_output .= '>';
    
    		if ( in_array($day, $daywithpost) ) // any posts today?
    				$calendar_output .= '<a href="' . get_day_link( $thisyear, $thismonth, $day ) . '" title="' . esc_attr( $ak_titles_for_day[ $day ] ) . "\">$day</a>";
    		else
    			$calendar_output .= $day;
    		    $calendar_output .= '</td>';

    in this case the class is class=”with-post”
    now you can style the <td> with post in them.
    I got the solution from this clever dude
    All the Best

    Chris

Viewing 2 replies - 1 through 2 (of 2 total)