SMFHacks.com

SMF Classifieds => Support => Topic started by: Saftek on June 30, 2022, 03:51:23 pm

Title: Trying to access array offset on value of type null
Post by: Saftek on June 30, 2022, 03:51:23 pm
I am getting numbers of entries into the error log "Trying to access array offset on value of type null". Apparently this happens when someone attempts to access a listing which as been deleted for whatever reason.

I would assume these links would eventually be purged from search engine listings, etc. But some seem to hold them forever. So I get many such entries.

Am I doing something wrong by deleting old listings? Is there a way to prevent the log entries for dead products?

(Note: this happens on the Store too -just not as often.)

Thanks.
Title: Re: Trying to access array offset on value of type null
Post by: SMFHacks on June 30, 2022, 03:58:54 pm
Please all errors and line numbers along with the filename for us to look into.
Title: Re: Trying to access array offset on value of type null
Post by: Saftek on July 03, 2022, 03:33:51 pm
#0: smf_error_handler()
Called from /home/xxxxxx/public_html/forum/Sources/classifieds2.php on line 664
#1: Classifieds_ViewMore()
Called from /home/xxxxxx/public_html/forum/Sources/classifieds2.php on line 192
#2: ClassifiedsMain()
Called from /home/xxxxxx/public_html/forum/index.php on line 191


==================================


Type of error
General
Error message
8: Trying to access array offset on value of type null
File
/home/xxxxxx/public_html/forum/Sources/classifieds2.php
Line
653
URL of page causing the error
https://www.xxxxxx.com/forum/index.php?action=classifieds;sa=viewmore;id=324
Title: Re: Trying to access array offset on value of type null
Post by: SMFHacks on July 03, 2022, 03:37:52 pm
Is that only one? If you have other locations let me know to so I don't have to do a bunch of new releases.
Title: Re: Trying to access array offset on value of type null
Post by: Saftek on July 04, 2022, 12:00:37 pm
Those are the two I've seen the past couple of days. It will happen for other deleted products, same error info.

Thanks.
Title: Re: Trying to access array offset on value of type null
Post by: SMFHacks on July 04, 2022, 08:14:20 pm
Posted an update that should fix those two.
Title: Re: Trying to access array offset on value of type null
Post by: Saftek on July 05, 2022, 12:45:10 pm
Thanks. That works.