Title: WP-Cal Hack &#8211; PHP help
Last modified: August 18, 2016

---

# WP-Cal Hack – PHP help

 *  Resolved [laphlegm](https://wordpress.org/support/users/laphlegm/)
 * (@laphlegm)
 * [18 years, 8 months ago](https://wordpress.org/support/topic/wp-cal-hack-php-help/)
 * I am trying to use the old plugin WP-Cal, but the plugin uses an old function:
 * user_can_edit_post
 * which is in the code:
 * if(user_can_edit_post($user_ID, $post->ID)){
    $canedit = true; echo “[Add event](https://wordpress.org/support/topic/wp-cal-hack-php-help/onclick=addevent($_GET[date]);?output_format=md)
   <div class=’clear’></div>”; }
 * Originally, the code only let admins edit, but since the function is no longer
   used, it makes it so that anyone can edit. How would I change this so that only
   the administrator is allowed to do this using the functions which are supported
   now?

Viewing 1 replies (of 1 total)

 *  Thread Starter [laphlegm](https://wordpress.org/support/users/laphlegm/)
 * (@laphlegm)
 * [18 years, 8 months ago](https://wordpress.org/support/topic/wp-cal-hack-php-help/#post-604841)
 * Seems that the plugin author is out of town, but someone else seemed to fix the
   bugs and it seems to work on wordpress 2.2. It can be found here:
 * [http://goudendouche.com/2007/03/23/calendar-plugin/](http://goudendouche.com/2007/03/23/calendar-plugin/)

Viewing 1 replies (of 1 total)

The topic ‘WP-Cal Hack – PHP help’ is closed to new replies.

## Tags

 * [wp-cal](https://wordpress.org/support/topic-tag/wp-cal/)

 * 1 reply
 * 1 participant
 * Last reply from: [laphlegm](https://wordpress.org/support/users/laphlegm/)
 * Last activity: [18 years, 8 months ago](https://wordpress.org/support/topic/wp-cal-hack-php-help/#post-604841)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
