Facebook  Twitter 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 4239
Latest: 3dickulus
New This Month: 4
New This Week: 1
New Today: 0
Stats
Total Posts: 43126
Total Topics: 7500
Most Online Today: 83
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 1
Guests: 45
Total: 46

Author Topic: Error after php upgrade  (Read 837 times)

0 Members and 1 Guest are viewing this topic.

Offline wargamesillustrated

  • Member
  • *
  • Posts: 6
    • View Profile
Error after php upgrade
« on: January 26, 2021, 04:32:35 am »
Hi there, our host has moved our forum to PHP 7.3 everything seems to be working ok but we have the error at the top of the site:

Deprecated: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior in /homepages/7/d856305556/htdocs/leadadventureforum.com/public_html/Sources/adseller2.php on line 4351

Is this something that can be fixed?

Thank you

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16378
    • View Profile
Re: Error after php upgrade
« Reply #1 on: January 26, 2021, 01:45:25 pm »
This was fixed in an update.
Fixed function below
Code: [Select]
function AdSellerisMobileDevice()
{

$user_agents = array(
array('iPhone', 'iphone'),
array('iPod', 'ipod'),
array('iPad', 'ipad'),
array('PocketIE', 'iemobile'),
array('Opera Mini', isset($_SERVER['HTTP_X_OPERAMINI_PHONE_UA']) ?  'operamini' : ''),
array('Opera Mobile', 'Opera Mobi'),
array('Android', 'android'),
array('Symbian', 'symbian'),
array('BlackBerry', 'blackberry'),
array('BlackBerry Storm', 'blackberry05'),
array('Palm', 'palm'),
array('Web OS', 'webos'),
);

foreach ($user_agents as $ua)
{
$string = (string) $ua[1];

if (!empty($string))
if ((strpos(strtolower($_SERVER['HTTP_USER_AGENT']), $string)))
return true;
}

        return false;

}
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline wargamesillustrated

  • Member
  • *
  • Posts: 6
    • View Profile
Re: Error after php upgrade
« Reply #2 on: January 27, 2021, 12:37:06 pm »
Thank you, How do I apply this fix/ update?

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16378
    • View Profile
Re: Error after php upgrade
« Reply #3 on: January 27, 2021, 01:01:47 pm »
You can either replace the function in sources/adseller2.php with the above new code.

Or purchase a renewal at a lower price for which has updates for another year as well
https://www.smfhacks.com/index.php?action=license
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

 

Related Topics

  Subject / Started by Replies Last post
37 Replies
25334 Views
Last post December 27, 2007, 10:22:10 pm
by SMFHacks
2 Replies
3550 Views
Last post October 02, 2009, 06:59:00 pm
by SMFHacks
4 Replies
4945 Views
Last post November 17, 2013, 08:42:19 pm
by dan42101
1 Replies
997 Views
Last post July 30, 2021, 09:11:45 pm
by SMFHacks
2 Replies
438 Views
Last post October 31, 2022, 10:49:56 am
by Gus

+- Recent Topics

“Insert from Gallery” by apothocary
November 21, 2023, 07:25:28 am

SMFHacks Black Friday Sale 2023! by SMFHacks
November 19, 2023, 12:05:51 pm

File Count by SMFHacks
November 11, 2023, 11:46:46 am

Theme Changer by SMFHacks
November 09, 2023, 04:30:05 pm

Pretty Urls extras by SMFHacks
November 08, 2023, 05:23:14 pm

Member group access to emojis by SMFHacks
October 22, 2023, 07:24:12 am

Miscellaneous errors - don't know why by SMFHacks
October 13, 2023, 09:28:50 am

Follow / Follower Mod? by Nicole
October 06, 2023, 07:37:20 am

Mods supporting custom themes? by SMFHacks
October 02, 2023, 04:20:18 pm

Version 6.1.6 issues by SMFHacks
September 30, 2023, 07:54:52 am

Powered by EzPortal