# PHP error with contact form plugin

**URL:** <https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734>\
**Category:** Questions\
**Tags:** v2\
**Created:** [April 8, 2015, 8:10am UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734 "2015-04-08T08:10:41Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![rhjp](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/rhjp/32/420_2.png) [@rhjp](https://forum.getkirby.com/u/rhjp)\
**Post date:** [April 8, 2015, 8:10am UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734/1 "2015-04-08T08:10:41Z")

</div>

Hi there,

I downloaded and installed the Contact form Plugin & Snippet on my site, however I’m running into this issue when I hit the send button:

```
Fatal error: Call to undefined function error() in /www/site/plugins/contactform/contactform.php on line 42

```

I haven’t touched any code in that script so I’m not sure what the issue would be.  
The only code I tweaked in the snippet was the ‘to’, ‘from’ and ‘subject’ in the new ContactForm array.

Could anyone offer some insight?

Thanks for your time.

p.s. At the moment I’m just running this on localhost using MAMP

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [April 8, 2015, 8:19am UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734/2 "2015-04-08T08:19:54Z")

</div>

What contact form plugin is that? You probably downloaded a plugin for Kirby 1, which won’t work with Kirby 2 anymore?

---

<div class="post-metadata">

**Author:** ![rhjp](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/rhjp/32/420_2.png) [@rhjp](https://forum.getkirby.com/u/rhjp)\
**Post date:** [April 8, 2015, 8:25am UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734/3 "2015-04-08T08:25:16Z")

</div>

Oh yeah, I think you might be right.

Unfortunately it doesn’t look like there is a contact form plugin for Kirby 2 at [getkirby-plugins.com](http://getkirby-plugins.com/) so I guess I’ll just have a crack at doing it myself.

Thanks!

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [April 8, 2015, 8:28am UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734/4 "2015-04-08T08:28:23Z")

</div>

You may want to have a look at the uniform plugin (listed at [getkirby-plugins.com](http://getkirby-plugins.com)) if you don’t want to do it yourself [https://github.com/mzur/kirby-uniform](https://github.com/mzur/kirby-uniform)

And there’s this contact form example: [https://gist.github.com/bastianallgeier/c396df7923848912393d](https://gist.github.com/bastianallgeier/c396df7923848912393d)

---

<div class="post-metadata">

**Author:** ![distantnative](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/distantnative/32/11319_2.png) [@distantnative](https://forum.getkirby.com/u/distantnative)\
**Post date:** [February 6, 2025, 5:04pm UTC](https://forum.getkirby.com/t/php-error-with-contact-form-plugin/734/5 "2025-02-06T17:04:32Z")

</div>


