Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image posting not working #211

Open
73james93 opened this issue Apr 25, 2018 · 1 comment
Open

Image posting not working #211

73james93 opened this issue Apr 25, 2018 · 1 comment

Comments

@73james93
Copy link

Everytime I try to post a image on my board it says "Fatal error: Cannot redeclare imagecreatefrombmp() in xampp/vichan/inc/image.php on line 584"

I also get "count(): Parameter must be an array or an object that implements Countable" in the dashboard and the configuration page is all empty.

@p810
Copy link

p810 commented Sep 28, 2018

imagecreatefrombmp() is a function that's built-in to PHP. I guess the author was trying to polyfill this function for environments where the GD extension is unavailable.

Wherever you get an error complaining about redeclaring a function, try wrapping it in an if block:

if (! function_exists('imagecreatefrombmp') {
    function imagecreatefrombmp($image) { /* ... */ }
}

There may be more instances of this throughout the code (I noticed at least one a few lines down, imagebmp()).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants