TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Recent posts

#21
Fixed Bugs / Re: Unable to delete article c...
Last post by lurkalot - August 23, 2025, 02:45:22 PM
You're on the articles page, not the categories page.

Click TinyPortal admin and then click the categories icon.
#22
Fixed Bugs / Re: Unable to delete article c...
Last post by davejo - August 23, 2025, 02:24:53 PM
Hi @rjen,

There is obviously something wrong with my install somewhere because both the mobile and desktop doesn't show the red crosses in either.

I had version 3.0.1 before 3.0.2 and before that 2.2.1 and 2.3.1, does that help?
#23
Fixed Bugs / Re: Unable to delete article c...
Last post by @rjen - August 23, 2025, 11:20:25 AM
In the page with Article Categories there is a Red Cross to the right : that will delete the category

#24
Fixed Bugs / Unable to delete article categ...
Last post by davejo - August 23, 2025, 11:04:02 AM
Link to my forum: http://www.quizland.co.uk
SMF version: SMF ver. 2.1.6
TP version: TP ver. 3.0.2
Default Forum Language: English
Theme name and version: Default
Browser Name and Version: Brave 1.81
PHP Version   8.3.19
Mods installed:


My Read_Topics   1.1   
Simple Referrals   1.4.7   
Members Online Today   1.0.1   
AutoPurge old Topics   2.0   
Contact Page   7.1   
SMF Arcade   2.7.0.7-RC15   
TinyPortal   3.0.2   
ST Shop   4.1.14-RC9   
SMF 2.1.6 Update   
Personalized BBC   
Image for Anti-Spam Verification Questions   1.6   
Image Attachment Thumbnail View   1.8   
Topic Solved Mod   2.0   
Banner Bar   1.7   
Say Thanks   2.6.0   
Welcome Topic Mod   2.3b   
SMF 2.1 Simple Insert Image   1.0   
Show Unread Private Messages   1.2   
Quick Spoiler   1.5   
SMF Quiz   2.0.3-BETA29   
SCEditor Max Height   1.0.1   
SMF-Snowflakes   1.85   
Login Menu Button   2.0   
PM Attachments   2.13   
Downloads System Pro   6.3a   
Ultimate Menu   2.0.2   
Email Inactive Users   1.2   
Custom Board Icons   2.0.0   
Simple Colorizer   1.4   
WordPress-XCloner-Manager   1.0-RC15
Force Topic Read On Login Mod   2.1
SMF-Quiz Integration   1.1
FancyBox 4 SMF 1.2.5
Related Error messages: As per the attachments


In the attached images you'll see that when I was trying to get the RSS working on my site I created an article category called 'test'.

It's not doing any harm sitting there but I want to delete it and cannot find a way to do that. I have been into the database to look in the tp-settings table but it doesn't show there.

If anyone goes to the Articles/Categories page it creates the errors as attached.

Could you tell me how to remove the 'test' category please?
#25
Support / Re: TP ERROR: Undefined array ...
Last post by @rjen - August 16, 2025, 10:09:09 PM
Not that I know
#26
Support / Re: TP ERROR: Undefined array ...
Last post by Michael Vail - August 16, 2025, 09:02:24 PM
Thank you Rjen! I'm getting old!!!!

Those responses really help and totally make sense. Much appreciated!

Is there somewhere online I can find which and when variables are removed from SMF versions? The public changelogs I've seen posted when SMF is updated haven't shown that level of detail.

Have a great weekend!
#27
Support / Re: TP ERROR: Undefined array ...
Last post by @rjen - August 16, 2025, 07:15:54 AM
As for the time offset I would suggest checking the user settings in both forums. I suspect in your test forum the user does not have a time offset set: if you are not checking the variable for being maintained in the code, an empty variable will result in this error
#28
Support / Re: TP ERROR: Undefined array ...
Last post by @rjen - August 16, 2025, 07:12:41 AM
Just some explanation:
these $txt stings are the language text that are found in the language files in SMF. If you use a $txt string like $txt['profile_of'] in your custom block code this must be loaded as part of the language files in your forum.
You were using an SMF txt string in your block that got removed in a later version of SMF, that's what caused the 'undefined' errors...

The profile_of text was removed from SMF after RC4 I believe.
I assume it was working before because you upgraded with patches. The string must have still been in the language files. When you refreshed the data it was apparently gone...

By the way, using text string  $txt['profile'] = 'Profile'; will change the displayed text in you block.
Instead of  "Profile of Username" it will now show "Profile Username"

You can also keep using your custom block if you add the txt string to your Modifications.english.php file.
Just add:  $txt['profile_of'] = 'Profile of';

Edit:
I just noticed you already reported the exact same issue here in 2022 and fixed it yourself: https://www.tinyportal.net/index.php?topic=36753.msg302400#msg302400

This fix you have now overwritten when you replaced all files with the original ones...
#29
Support / Re: TP ERROR: Undefined array ...
Last post by Michael Vail - August 15, 2025, 10:44:47 PM
Thank you to both Lurkalot and Rjen. I tried removing the Avatar mod but the problem persisted so I uninstalled every SMF mod except TP. Still no go. I then disabled each TP block as Rjen suggested and found the error was being generated by the custom calendar block I've been using for 3+ years. What's bizarre is the log entries only began after running the SMF Large upgrade and reloading the mods on my forum.

The code section of the TP Calendar block that was generating the problem was this one:

Quote// BIRTHDAY SECTION
    if(($flag == 'B') && $show_bdays)
    {
        if($show_bdays_to_guests || !$user_info['is_guest'])
        {
            if (!empty($bdays))
            {
                echo '<tr'. (isset($list_label_class) ? ' class="'.$list_label_class.'"' : '') .'><td colspan="7" class="smalltext" align="center" style="font-weight: bold;">'.$list_label_bdays.'</td></tr>';
                $ctr = 0;

                foreach($bdays as $startdate => $bday_date)
                {
                    if (($startdate >= smf_strftime('%Y-%m-%d', $low_date_ts)) && ($startdate <= smf_strftime('%Y-%m-%d', $now + $modSettings['cal_days_for_index'] * 24 * 3600)))
                    {
                        foreach ($bday_date as $member)
                        {
                            $class_to_use = isset($list_entry_class) ? ( !is_array($list_entry_class) ? ' class="'.$list_entry_class.'"' : ' class="'.$list_entry_class[($ctr++) % count($list_entry_class)].'"') : '';
                            $birthdate = strtotime($startdate);
                            $text_start = !isset($month_nam['12']) ? date("M j",$birthdate) : substr($month_nam[smf_strftime('%m', $birthdate)],0,3) . date(" j",$birthdate);

                            echo '<tr'.$class_to_use.'><td colspan="7" class="smalltext" style="padding: 0px 0px 0px 0px;" width="100%" align="'.$align_list_entries.'">';
                            echo '<a href="', $scripturl, '?action=calendar;year=' . date("Y") . ';month=' . substr($startdate,5,2) . '">' . $text_start . ':</a> ';
                            echo '<a href="' . $scripturl . '?action=profile;u=' . $member['id'] . '" title="' . $txt['profile_of'] . ' ' . $member['name'] . '">' . '<span class="'.$hilite_bday_class.'">' . ( ($nowdate == $startdate) ? '' : '') . $member['name'] . (isset($member['age']) ? '(' . $member['age'] . ')' : '') . ( ($nowdate == $startdate) ? '' : '') . '</span>' . '</a>';
                            echo '</td></tr>';
                        }
                    }
                }
            }
        }
    }

On a whim, I changed the code from 'profile_of' to 'profile' and the errors stopped. I tried to get more info on this variable but found little info that helped. Perhaps it's deprecated in SMF 2.1.6 or PHP 8.0+??? I don't even know if the replacement I used is correct, but it doesn't generate errors and the block still appears to do what it's suppose to do, so I guess it's correct?

On a side note, I had created an nearly identical forum with the same plugins and versions to isolate the issue. Upon using the exact same Calendar block code on the test site on the same server and same conditions, I do not get the profile_of errors but do get an Undefined array key "time_offset" instead when displaying the same calendar block! I don't get it!  As with the other forum, the block works as intended, it just displays the time_offset errors in the log every time the calendar block is displayed. The code for that section is below:

Quote// use forum's date/time
// include user's time offset to forum date/time
$now = time() + (($user_info['time_offset'] + $modSettings['time_offset']) * 3600);

Just curious if you have any idea why this strange error behavior for two different arrays are occurring and only on one similar forum to the other? Are both the variables deprecated now? Why is only one forum displaying each error in the log and not both errors?

If you have an ideas, I'd love to know to satisfy my curiosity.

Warm Regards and thank you for the help!

#30
Support / Re: TP ERROR: Undefined array ...
Last post by @rjen - August 15, 2025, 02:28:36 PM
Based on the error it seems to me that this error is triggered wehen a certain block is rendered. To track it down you can try disabling blocks one by one and check if the message stops. The block you disabled will then be triggering the problem.

I suspect it is some mod that does something to profiles, and then the blocks to check are the ones that contain profile information.. i would suggest recent topics or user blocks.
You may also have custom coded blocks to check...

This website is proudly hosted on Crocweb Cloud Website Hosting.