Title: receiving error on widget.php
Last modified: August 20, 2016

---

# receiving error on widget.php

 *  [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/)
 * Hi,
 * I am supposed to update a wordpress site which was made in 2009.
 * I have created a new theme based on twentyeleven on my local server and it is
   working well on my machine. (I changed some html/css only) then I uploaded only
   the theme to the server in the theme folder. I was expecting to activate the 
   new theme and be able to see it on the site. when I activated the new theme, 
   it gave me error in something with widget.php.
 * So, once I compared the old widget.php with my new widget.php, I noticed they
   MIGHT BE slightly different.
 * So, I switched the old widget.php with my new one. Still the site is giving me
   error with widget.php. So, I switched it back to old widget.php and still not
   working. when I type the url it gives me this error:Fatal error:
    Call to undefined
   function add_theme_support() in /home/wilmax1/public_html/wordpress/wp-includes/
   widgets.php on line 561
 * Does anybody knows how to solve this issue please?
    Hope I have explained it 
   OK. If need more info, let me know.
 * I’d really appreciate it.

Viewing 15 replies - 1 through 15 (of 25 total)

1 [2](https://wordpress.org/support/topic/receiving-error-on-widgetphp/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/receiving-error-on-widgetphp/page/2/?output_format=md)

 *  [fwoan](https://wordpress.org/support/users/fwoan/)
 * (@fwoan)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747796)
 * [http://codex.wordpress.org/Function_Reference/add_theme_support](http://codex.wordpress.org/Function_Reference/add_theme_support)
 * Support for something like widgets should be done in functions.php
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747797)
 * Thanks for response.
    I am really not familiar with php and how the files connected.
   I basically put the files back as it was and it is not working. Can it be broken
   just by deleting and uploading the files?
 * I just need to get it back to what it was. And then work away from there. The
   site is down now.
 *  [fwoan](https://wordpress.org/support/users/fwoan/)
 * (@fwoan)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747799)
 * Remove that function from widgets.php and place it into functions.php
 *  [kmessinger](https://wordpress.org/support/users/kmessinger/)
 * (@kmessinger)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747800)
 * Did you actually upgrade wp? This thread shows your version as 2.8.5.
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747801)
 * I haven’t upgrade it. It is still old. I have undone uploading the new theme 
   and new widget.php.
 * I am not sure what I have to replace here. I need to know why now that everything
   is back as it was, it is still not working.
 *  [kmessinger](https://wordpress.org/support/users/kmessinger/)
 * (@kmessinger)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747802)
 * Twentyeleven won’t run on a 2009 WordPress.
 * What is the url?
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747803)
 * Well, that is good to know. But I have deleted the new theme. What is causing
   problem still?
 * Url is wilmax.ca
 *  [kmessinger](https://wordpress.org/support/users/kmessinger/)
 * (@kmessinger)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747805)
 * Download a fresh copy of 2.8.5 here, [http://wordpress.org/download/release-archive/](http://wordpress.org/download/release-archive/)
 * Extract the widgets.php and upload it to the server. There is nothing on line
   561 in that version.
 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747806)
 * You are trying to use a WP 3 function (add_theme_support) to a WP 2.8.5 site.
   In short – your site is too old to support this function.
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747812)
 * I have the widget.php from the version that is old. I am using the right widget.
   php for my version I think, because I didn’t changes it.
 * I am not trying to add any function. I am just wondering why the old version 
   with its old widget.php is not working anymore.
 * By the way, I am not sure which version the old site was on. Is there any file
   that has this information that I can look up?
 * Thanks a lot
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747813)
 * Oh, by the way, I checked the widget.php and it doesn’t have anything in regard
   to that function in it, even on line 561.
    even in function.php, there is no 
   such thing!!
 * It is bizarre!
 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747815)
 * You cannot use add_theme_support() on a 2.8.5 WP install. The problem is in your
   theme.
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747817)
 * Which theme, the old one or new one? The new one is removed later.
 *  [kmessinger](https://wordpress.org/support/users/kmessinger/)
 * (@kmessinger)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747818)
 * > I am using the right widget.php for my version I think, because I didn’t changes
   > it.
 *  I don’t think so. The version of widget.php you are using has `add_theme_support('
   widgets');` Version 2.8.5 did not support that so you must have the wrong file.
 * > By the way, I am not sure which version the old site was on. Is there any file
   > that has this information that I can look up?
 *  wp-includes/version.php
 *  Thread Starter [Helen-kh](https://wordpress.org/support/users/helen-kh/)
 * (@helen-kh)
 * [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/#post-2747822)
 * So, the version is 2.8.4, that is for sure 🙂
 * I am sure I have put the right version of widget.php and when I looked for that
   function in it, there is nothing there.
 * I know I have put the old widget.php, because I had copied it already and I used
   the copy to upload it again.

Viewing 15 replies - 1 through 15 (of 25 total)

1 [2](https://wordpress.org/support/topic/receiving-error-on-widgetphp/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/receiving-error-on-widgetphp/page/2/?output_format=md)

The topic ‘receiving error on widget.php’ is closed to new replies.

## Tags

 * [Call to undefined function:](https://wordpress.org/support/topic-tag/call-to-undefined-function/)
 * [php-error](https://wordpress.org/support/topic-tag/php-error/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 25 replies
 * 4 participants
 * Last reply from: [esmi](https://wordpress.org/support/users/esmi/)
 * Last activity: [14 years ago](https://wordpress.org/support/topic/receiving-error-on-widgetphp/page/2/#post-2747934)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
