Search the Community
Showing results for tags 'php upgrade'.
-
I am getting an undefined index that refers to this part of the code: $session_id = $_COOKIE[""]; $action = $_GET['action']; if ($action == "add" && !empty($HTTP_POST_VARS["artid"])) { $artid = $HTTP_POST_VARS["artid"]; do i need to change $HTTP_POST_VARS["artid"]; to $_GET["artid"] Thank you in advance.
-
Our sys admin upgraded to the most recent version of php and it broke many of our websites that we host. From the research that I have done, Function ereg_replace() is depreciated and no longer works in this version of PHP. originally the line of code was: $bio = ereg_replace("\n", "</p><p>", $row["bio"]); When i change it to: $bio = preg_replace("\n", "</p><p>", $row["bio"]); I get a new error: Warning: preg_replace(): Empty regular expression in/home/....../public_html/filename.php on line 70 what am i missing? Thank you in advance for any assistance.
-
after php upgrade to 5.4.12 some errors
BjoernG posted a topic in PHP Installation and Configuration
Hi "PHPFreaks" First I have to say, that I am not a php or any other language programmer.. I'd like to ask someone who as a "plan" about php codeing. But here is my question: After I setup a new Webserver, I moved my website on it. Everything works fine, just with one exception - I can't login on my Gallery Backend/Frontend. Here what I did: old system Server OS: FreeBSD 7.1-RELEASE FreeBSD 7.1 Apache Version: Apache/2.2.11 PHP Versoion: PHP 5.29 Expose: 4.6.3 alpha3c SEF: on or off it is working anyway Joomla Version: 1.5.26 NEW SYSTEM Server OS: FreeBSD 9.1-RELEASE FreeBSD 9.1 Apache Version: Apache/2.2.23 (FreeBSD) PHP/5.4.12 mod_ssl/2.2.23 OpenSSL/0.9.8x DAV/2 PHP Versoion: PHP 5.4.12 Expose: 4.6.3 alpha3c SEF: off, when it's on I also have some troubles with expose gallery, but this later... Joomla Version: 1.5.26 I guess it has to do with this error [Mon Mar 04 15:51:30 2013] [error] [client 10.114.52.60] PHP Fatal error: Uncaught exception 'VerboseException' with message 'Non-static method CharsetHandler::setMethod() should not be called statically, assuming $this from incompatible context' in /usr/local/www/www.myweb.com/components/com_expose/expose/manager/amfphp/amf-core/app/Gateway.php:127\nStack trace:\n#0 /usr/local/www/www.myweb.com/components/com_expose/expose/manager/amfphp/amf-core/app/Gateway.php(127): amfErrorHandler(2048, 'Non-static meth...', '/usr/local/www/...', 127, Array)\n#1 /usr/local/www/www.myweb.com/components/com_expose/expose/manager/amfphp/gateway.php(176): Gateway->service()\n#2 {main}\n thrown in /usr/local/www/www.myweb.com/components/com_expose/expose/manager/amfphp/amf-core/app/Gateway.php on line 127, referer: http://www.myweb.com/components/com_expose/expose/manager/manager.swf Attached the Gateway.php File and here you can download the whole gallery in a small zip (may you need more source files?...) here - Download I have both system online (just work with hosts file on my windows system to switch over) hope you guys have a better plan then I cheers BjoernGGateway.php- 6 replies
-
- php upgrade
- manager login
-
(and 2 more)
Tagged with:
-
Hi there, I wondered if there was anyone out there who could help. I did some PHP coding some years ago for a site, the site is hosted on oneandone and a couple of months back we went through the traumatic exercise of updating the site to the version 5 MySQL and now I'm going through a similar exercise to upgrade from version 4 to version 5.4 PHP. Now I know I should have done this ages ago but it's not really my site and I've just accepted the onerous responsibility of doing this upgrade - despite forgetting just about everything I know about PHP. Hey I've got to that age now :-) Basically though switching over to PHP 5.4 on oneandone is a doddle but once you do this then no-one can log in. I'm trying to switch on error reporting but that's not being very successful, but I have found a chink of light in that once one requests a new password then it still does not work, but the reasoning for it not working - it seems to me - is that it's not finding the username in the user database. So either it's not passing the username or its somehow just not finding the username in the database. This is the questionable function code: function notify_password($username, $password) // notify the user that their password has been changed { if (!($conn = db_connect())) return false; $result = mysql_query("select email from user where username='$username'"); if (!$result) { return false; // not changed } else if (mysql_num_rows($result)==0) { return false; // username not in db } else { $email = mysql_result($result, 0, 'email'); $from = "From: test@test.com \r\n"; $mesg = "Your Test.com password has been changed to $password \r\n" ."Please change it next time you log in. \r\n"; if (mail($email, 'Test.com login information', $mesg, $from)) return true; else return false; } } I reckon it fails at the: $result = mysql_query("select email from user where username='$username'"); if (!$result) { return false; // not changed bit. I could be wrong but I changed the "return false" to "return true" for this bit and it seemed to make things better, well at least it thought it was working. Any help would be very much appreciated but please be gentle as I'm not really a PHP freak, I'm more a PHP twiddler. Cheers, Bill