-1

please help me solve this php version problem.
I had Centos 6.5 (32bit) and php 5.3.3 pre-installed on it, right before I decided to wreck it!
The need to upgrade was this warning:

Warning:  DOMDocument::saveHTML() expects exactly 0 parameters, 1 given in ...

and I found that it needs to be, at least 5.3.6 to work. Using this stackoverflow article, I upgraded to php 54w like this:

rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm
yum remove php-common       # Need to remove this, otherwise it conflicts
yum install php54w
php --version               # Verify version has been upgraded

but, after that I experienced some conflicts, and tried to remove the php and re-install it, and now I can not phpmyadmin opens nothing and SimpleXmlElement returns some errors like:

PHP Warning:  SimpleXMLElement::__construct(): Entity: line 2: parser error : Start tag expected, '<' not found in ...

or

PHP Warning:  SimpleXMLElement::__construct(): Fatal error: Call to undefined function mb_convert_encoding() in

or

PHP Warning:  SimpleXMLElement::__construct(): ^ in

or

PHP Fatal error:  Uncaught exception 'Exception' with message 'String could not be parsed as XML'

, which I had not before this (with the pre-installed 5.3.3).

Guys, Please help me with this. I googled alot and each stack-like article pushes me to variety of totaly different commands. I am realy with it :(


Problem Solved

Finally the problem solved!
A friend of mine, suggested installing php-mbstring like this:

sudo yum install php-mbstring

and atfer that the problem was solved (and phpmyadmin works fine again) and I am back at the state that have this warning:

PHP Warning:  DOMDocument::saveHTML() expects exactly 0 parameters, 1 given in ...

and now I need to upgrade at least to php 5.3.6. I will ask it in a seperate thread, after some googling.
I realy appreciate helps from "Nomad" and sorry for the insufficient reputaion to upvote your helpful answer.

1 Answers1

0

Try:

yum remove php
yum install php
yum install php-simplexml
Nomad
  • 128
  • 6
  • as I mentioned, I exactly tried this. But it seems to have some problems as I now recieve odd errors for `SimpleXmlElement` which I had not whit the pre-installed php5.3.3 – Peyman Mohamadpour Aug 07 '14 at 09:38
  • You didn't say you used these commands specifically. What is the output when you run them? You are being a bit vague... – Nomad Aug 07 '14 at 09:40
  • there is nothing wrong with the commands, but I realy think some libraries are not installed with them, as I have some errors on `SimpleXmlElement` which I did not with the pre-installed version. – Peyman Mohamadpour Aug 07 '14 at 09:43
  • Check my answer again, for php-simplexml installation. – Nomad Aug 07 '14 at 09:59
  • Just saying "you have some errors on SimpleXml" is very vague. How do you get the errors? If you want better help, provide information. – Nomad Aug 07 '14 at 10:00
  • Thanks for good comment. I will add it, but I think this was obviouse problem with php libraries. – Peyman Mohamadpour Aug 07 '14 at 10:04
  • I tried `yum install php-simplexml` too, but it says it has already this in php-common and nothing installed – Peyman Mohamadpour Aug 07 '14 at 10:45
  • So this is a problem with phpmyadmin and not PHP. Try to upgrade/reinstall phpmyadmin? – Nomad Aug 07 '14 at 11:20