We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

reinstalling Phalcon

Hi,

I was using the safe build and it was working ok. After having a very unpleasant customer-user experience with amazon web service I'm switching to Linode, so everything from scratch. I installed centOS 7 and install Phalcon the regular way as the way written in doc; I then found out the result is so different than what I have before.

  • cannot instanciate a model class (same code that works perfectly on safe built)
  • the echo from beforeDispatch (and it's sort) is not executed if view is executed successfully

I'm not sure if it is because I'm using different Linux distro or I'm installing different build, but I would try if my code can work again by installing the safe build on CentOS 7. So how may I reinstall Phalcon? Or how to uninstall?

thanks in advance, Chi

Can you show the exact error/exception?

the echo from beforeDispatch (and it's sort) is not executed if view is executed successfully

This should be the correct behavior, I'm not sure how did it work before.

To remove the old phalcon library (.so file) you can go to /usr/lib64/php/, in that folder (or one of the subfolders) there should be all the php extensions. From there you can remove the phalcon.so. Then you can remove the phalcon.ini you added when you followed the instructions.



25.7k

Thanks Max, I found out it is I'm using ::class for the is_a PHP function inside model class, before I was using PHP 5.5 and now my installation is PHP 5.4, when I instanciate a model it is the unsupported ::class break the flow. Apology, my first post may be inaccurate,

the echo from beforeDispatch (and it's sort) is not executed if view is executed successfully

This should be the correct behavior, I'm not sure how did it work before.

Seem like Max is correct, I was confused at the moment I encountered the errors. I still have a few more questions regarding this issue; when the beforeDispatch event forward the flow and execute a view, the echo from the beforeDispatch and the forwarded view both execute, I still don't understand why there's a different.