Login  |  Register
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome, Guest. Please login or register.
Did you miss your activation email?

December 05, 2022, 01:39:31 PM

Login with username, password and session length
Members
  • Total Members: 3853
  • Latest: tty456
Stats
  • Total Posts: 193627
  • Total Topics: 21108
  • Online today: 83
  • Online ever: 3540
  • (September 02, 2022, 06:38:54 PM)
Users Online
Users: 0
Guests: 67
Total: 67

Author Topic: Elkarte TinyPortal Testing  (Read 19701 times)

0 Members and 1 Guest are viewing this topic.

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #160 on: March 09, 2022, 02:13:59 AM »
Addendum: No error is reported under PHP7, but no changes to block settings are applied, e.g.: the display of online time in the user block. Under PHP8, the error mentioned above then appears. :-\
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline tino

  • Developer
  • *
  • Posts: 2641
Re: Elkarte TinyPortal Testing
« Reply #161 on: March 09, 2022, 06:55:26 AM »
Addendum: No error is reported under PHP7, but no changes to block settings are applied, e.g.: the display of online time in the user block. Under PHP8, the error mentioned above then appears. :-\

Ok thanks, I hope to have some time this weekend to have a stab at fixing some of these errors.

Offline tino

  • Developer
  • *
  • Posts: 2641
Re: Elkarte TinyPortal Testing
« Reply #162 on: March 12, 2022, 06:35:53 AM »
Addendum: No error is reported under PHP7, but no changes to block settings are applied, e.g.: the display of online time in the user block. Under PHP8, the error mentioned above then appears. :-\

Pushed some small fixes for these issues. Seems most were typo's or me not using the correct variable so fairly easy.

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #163 on: March 15, 2022, 02:38:53 AM »
I just looked at the BlockAdmin.php on my test systems ... the line 498 that is replaced, or extended, in the fix is commented out there with two slashes. So nothing can work like that either. ;D
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #164 on: March 16, 2022, 12:03:19 PM »
I can't leave it alone.  ???

I noticed at the PHP calendar block the compressed bar with the month name. This is caused by a fixed declared height of 31 pixels in line 754 following for "h2.category_header, ...". This is due to the graphical gradient in the default SMF themes. But with the CSS gradients used by ELK this is no longer necessary. So I reduced "h2.category_header, ..." to the most necessary ("overflow: hidden;").

While briefly skimming other layout abnormalities, I came across quite a few padding with exactly one percent. Should better be changed to .3em to .5em. That way the margin depends on the font and not on the screen width.

In this context I also changed the function template_categories() to a tableless layout. :doh:

Code: [Select]
// Article Categories page
function template_categories()
{
global $context, $settings, $options, $txt, $scripturl, $modSettings, $boarddir, $boardurl, $language;

echo '
<form accept-charset="', 'UTF-8', '" name="tpadmin_news" action="' . $scripturl . '?action=admin;area=tparticles;sa=newcategory" method="post" enctype="multipart/form-data" onsubmit="syncTextarea();">
<input type="hidden" name="sc" value="', $context['session_id'], '" />
<input type="hidden" name="tpadmin_form" value="categories">
<div class="cat_bar">
<header class="category_header">
<div class="floatleft">' . $txt['tp-artcat'] . '</div>
<div class="floatright150 centertext">' , $txt['tp-actions'] , '</div>
</header>
</div>
<section id="edit-category" class="admintable admin-area">
<div class="information smalltext">' , $txt['tp-helpcats'] , '</div>';
if(isset($context['TPortal']['editcats']) && count($context['TPortal']['editcats'])>0)
{
$alt=true;
foreach($context['TPortal']['editcats'] as $c => $cat)
{
echo '
<div class="content padding-div">
<div class="floatleft">
' , str_repeat("- ",$cat['indent']) , '
<a href="' . $scripturl . '?action=admin;area=tparticles;sa=categories;cu='.$cat['id'].'" title="' .$txt['tp-editcategory']. '">' , $cat['name'] , '</a>
' , isset($context['TPortal']['cats_count'][$cat['id']]) ? '(' . ($context['TPortal']['cats_count'][$cat['id']]>1 ? $txt['tp-articles'] : $txt['tp-article']) . ': '.$context['TPortal']['cats_count'][$cat['id']].')' : '' , '
</div>
<div class="floatright150 centertext">
<a href="' . $scripturl . '?cat=' . $cat['id'] . '" title="' . $txt['tp-viewcategory'] . '"><img src="' . $settings['tp_images_url'] . '/TPfilter.png" alt="" /></a>&nbsp;
<a href="' . $scripturl . '?action=admin;area=tparticles;sa=categories;cu='.$cat['id'].'" title="' .$txt['tp-editcategory']. '"><img src="' . $settings['tp_images_url'] . '/TPconfig_sm.png" alt="" /></a>&nbsp;
<a href="' . $scripturl . '?action=admin;area=tparticles;sa=newcategory;child;cu=' . $cat['id'] . '" title="' . $txt['tp-addsubcategory'] . '"><img src="' . $settings['tp_images_url'] . '/TPadd.png" alt="" /></a>&nbsp;
<a href="' . $scripturl . '?action=admin;area=tparticles;sa=newcategory;copy;cu=' . $cat['id'] . '" title="' . $txt['tp-copycategory'] . '"><img src="' . $settings['tp_images_url'] . '/TPcopy.png" alt="" /></a>&nbsp;
<a href="' . $scripturl . '?action=admin;area=tparticles;sa=delcategory;id='.$cat['id'].';' . $context['session_var'] . '=' . $context['session_id'] . '" onclick="javascript:return confirm(\''.$txt['tp-confirmcat1'].'  \n'.$txt['tp-confirmcat2'].'\')" title="' . $txt['tp-delete'] . '"><img src="' . $settings['tp_images_url'] . '/TPdelete2.png" alt="" /></a>
</div>
</div>';
$alt = !$alt;
}
}
echo '
</div>
</section>
</form>';
}

In addition still a little CSS extended:

Code: [Select]
.floatright150 {
float: right;
min-width: 150px;
width: 20%;
}

Just had a look at the index.css of ELK an changed a little bit. Some declarations were redundant.
« Last Edit: March 18, 2022, 01:16:48 AM by McFly »
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline tino

  • Developer
  • *
  • Posts: 2641
Re: Elkarte TinyPortal Testing
« Reply #165 on: March 16, 2022, 01:36:12 PM »
Thanks!! CSS is definitely not my forte. I’d like to change to flex or a grid layout but no idea if or when I will.

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #166 on: March 16, 2022, 02:34:56 PM »
Thanks!! CSS is definitely not my forte. I’d like to change to flex or a grid layout but no idea if or when I will.

Hm ... I have already tried an exclusively tableless layout only with DIVs around for TP 1.3 and still some of it is in the back of my mind. And also somewhere in the nirvana of my work computer.  ^-^
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #167 on: March 17, 2022, 10:53:39 AM »
Had some time during the break today.  :)

I hope I have not overlooked anything. The layout is further adapted to the standard ELK theme. <header> for the headers and <section> for the content for example. Nothing had to be changed on the CSS for this except one:

Code: [Select]
.tp_block21 {
margin: 1px 0 0 0;
padding: 4px 8px 8px 8px;
}

Edit:

Ah ... Command back. It's not so easy to eliminate the sins of the forefathers of a round design with all its nestings of <tr>, <td> and countless <span> ...

There's a bit more work waiting.  :o
« Last Edit: March 18, 2022, 01:02:13 AM by McFly »
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline McFly

  • Jr. Member
  • **
  • Posts: 71
    • Die Annoholiker
Re: Elkarte TinyPortal Testing
« Reply #168 on: March 18, 2022, 01:25:28 AM »
By the way, after applying the last changes, the following result appears. All settings, for example, visibility of avatars in the user block or users online in the stastistics block, are deleted and can no longer be activated.  :hmm:
"I'm not going to censor myself to comfort your ignorance."

Testsites (may be online or not ;-) )
ElkArte 1.1.x & TP on Apache2.4.48, PHP 8.1.2 FPM/FastCGI, MariaDB 10.5.12

Offline tino

  • Developer
  • *
  • Posts: 2641
Re: Elkarte TinyPortal Testing
« Reply #169 on: March 18, 2022, 05:28:02 AM »
By the way, after applying the last changes, the following result appears. All settings, for example, visibility of avatars in the user block or users online in the stastistics block, are deleted and can no longer be activated.  :hmm:

Is that my changes or yours for the display?