News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Ant's Mutant Curve

Started by Antechinus, February 26, 2020, 11:02:14 PM

Previous topic - Next topic

Raumschiff

In Subs.php I made these changes:

         'login' => array(
            'title' => $txt['login'],
            'href' => $scripturl . '?action=login',
            'show' => $user_info['is_guest'],
            'sub_buttons' => array(
            ),
         ),
         'liebetroepfchen' => array(
            'title' => 'Liebetröpfchen',
            'href' => 'http://www.lebensrat-gottes.de/botschaftzeitlich.htm', [nofollow]
            'target' => '_blank',
            'show' => true,
            'sub_buttons' => array(
            ),
         ),
         'register' => array(
            'title' => $txt['register'],
            'href' => $scripturl . '?action=register',
            'show' => $user_info['is_guest'],
            'sub_buttons' => array(
            ),
            'is_last' => !$context['right_to_left'],
         ),

Could that be the reason?

Ok, i will make the changes.

Antechinus

Start by checking for the missing /> in the template. If that's not it, then we can look at Subs.php.

Raumschiff

I can't find that block of code.

Neither in the index.template.php file of your Theme, nor in the index.template.php file of the default Theme.

Antechinus

Well it's definitely there, otherwise you wouldn't have a log in form at all.

Ok, attach a copy of your template (for Mutant, not default) and I'll take a look. :)

Raumschiff


Antechinus

Line 323. Your template has:

<input type="submit" value="', $txt['login'], '" class="button_submit"

It should be:

<input type="submit" value="', $txt['login'], '" class="button_submit" />

Raumschiff

WOW! What the heck?

How could that happen?!?

It works now! Thank you very much!

But ... I am really curious ...  :o :o

Thanks again!  :D

PS: Now it really looks harmonic!

Antechinus

Funny things can happen when you start editing code. It's easy to miss a bit. ;)

Raumschiff

Oh yes! I love programming, (am a newbie), but if I don't know the source, (SMF is new for me), then it means searching and searching and searching!  :laugh:

If it is no effort for you,
could I ask you a second thing?

If I click onto "answer", then the "full editor" gets activated.
If I edit a written article, the small version of the editor gets activated.

But I often need/use the extra BBC-Buttons (were they called so?) and the smileys.

If I change to the full editor after I have written something, all the changes I made are gone.

I don't know, it was a bit more of "intuitive usability" to click onto the visible "edit" button.

??

Antechinus

I hid some buttons under the "More options" button. This was to save space on small screens, because having all of them visible can chew up a hell of a lot of space.

The visible one is the old "quick edit" that only has an icon by default. I restyled it to match the other buttons and sit in the same line.

The link to the full editor is in the "More options" drop menu, labelled "Full edit page" in English.

Raumschiff

Yes, I know it.
But to be honest, if a user changes his own article, writes half an hour, and then decides to make formattings, bold or whatever and switches and all his changes are gone ...

I would like to switch those buttons. Not for me (because I know where to find that button) but for the users.

How can I do that? ;D

Antechinus

I'll have to test it to make sure it doesn't look funny, and I suspect it will need some CSS tweaking when they are swapped. I can test it tonight my time, but I'll be spending the rest of the day working outside (Australian east coast time zone).

The basics are you'd find these two li's in Display.template.php, and swap them.

// Can the user modify the contents of this post?
if ($message['can_modify'])
echo '
<li class="quick_modify_button"><img src="', $settings['images_url'], '/theme/quick_edit_hd.png" alt="', $txt['modify_msg'], '" title="', $txt['modify_msg'], '" class="modifybutton" id="modify_button_', $message['id'], '" style="cursor: pointer; display: none;" onclick="oQuickModify.modifyMsg(\'', $message['id'], '\')" />', $txt['quick_modify'], '</li>';

// Can the user modify the contents of this post?
if ($message['can_modify'])
echo '
<li class="modify_button"><a href="', $scripturl, '?action=post;msg=', $message['id'], ';topic=', $context['current_topic'], '.', $context['start'], '">', $txt['modify'], '</a></li>';

Antechinus

Righty o. Only took me an extra day to get around to it. :P

You swap the li's as shown in the previous post, then for the CSS tweaks you find this:

.quickbuttons .quick_modify_button {
position: relative;
margin: 6px;
padding: 0 2.8rem 0 .8rem;
overflow: hidden;
color: #414f72;
line-height: 2.2rem;
}
.quick_modify_button img {
position: absolute;
top: 0;
right: -3.2rem;
height: 2rem;
padding: .1rem 3em;
}


And replace it with this:

.quickbuttons .quick_modify_button {
position: relative;
overflow: hidden;
width: 8.4rem;
padding: 6px 2.8rem 6px .8rem;
background: #f3f6f9;
color: #414f72;
text-align: start;
border: solid #0000;
border-width: 1px 0;
}
.quick_modify_button:hover {
background: #fff;
border-color: #aaa;
}
.quick_modify_button img {
position: absolute;
top: 0;
right: 0;
height: 2rem;
padding: 6px .3rem 6px 11rem;
}


You might want to change the text strings as well, but you can mess with those to suit yourself.

shadav

i haven't kept up with this but wow....
just saw it in the theme download so of course I had to try it....
great work
looks good on both pc and mobile

off to go play with it now  ;D

Antechinus

Bonzer. I'm sure there's a bug or two I missed. :)

shadav

not really your theme issue but...though i'd give you a heads up
with the avaters on board and/or message index mod
it gets a bit wonky

Antechinus

That doesn't surprise me. I thought it would, but that mod's not something that interests me. I prefer the cleaner look, so I figured anyone who wanted that mod could sort out their own presentation. :D

Sir Osis of Liver

#57
Having a problem with modify inline, editor opens and you can edit text, but it doesn't save, I brieflly get the Loading... thingy across the top, but the text box just sits there and doesn't save.  I vaguely recall seeing a similar glitch on an earlier version, believe I fixed it by removing inline edit and replacing with full edit from dropmenu (moved it over), but don't remember what caused it.  I'm using the current download.

Actually, it does save it, but you have to go somewhere else and come back to see it.

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Antechinus

#58
Ok, I'll take a look. AFAIK it was fine on local last I checked, but I may have missed something.

ETA: Just gave it a quick test on local. Works perfectly there. That's running the 1.04/1.05 version of the theme (same in terms of this functionality) on 2.0.17. But IIRC I haven't changed the quick edit code since before this theme was officially released.

Just in case it's relevant, my local is also running Apache 2.4.37 with PHP 7.1.24 and MySQL 5.7.24.

The local site also has no mods installed apart from my page index mod. It's possible one of your site's mods could be the issue.

Sir Osis of Liver

Theme version is 1.0.5.

Forum version: SMF 2.0.17 (more detailed)
Current SMF version: SMF 2.0.17
GD version: bundled (2.1.0 compatible)
Database Server: MySQL
MySQL version: 5.6.19-67.0-log
PHP: 7.2.23
Server version: Apache/2.4.41

Not a mod problem.  Will see if I can replicate it on test install.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Advertisement: