QUICK NEWS

{NEW} - A new css video is up.

{OLD} - New video courtesy of Skhilled, Thanks for posting it up.

Video of the moment:


Internal Links

SMF Sites

Quick Info

Theme help

Started by lesmond, Jul 19, 2021, 03:24 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

lesmond

So I have been working on converting one of Crips themes (Ambassador) to work with SMF RC4, and come across and few glitches.

I moved the header section inside the wrapper, which worked ok and looks good,. but now the header or menu link wont show in mobile view.

I made the changes in index.template.php

Can anyone help sort this out please?  :dontknow

Link to theme https://host-for.top/smfrc4/index.php

Mobile view




You cannot view this attachment. file here if that will help

The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

Is there not a mobile.css or files of some sort somewhere....I think there is. Maybe you forgot to include an edit in one. I'm just thinkin off the top of my head here, so I could be wrong.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

lesmond

Quote from: Bigguy on Jul 19, 2021, 04:30 PMIs there not a mobile.css or files of some sort somewhere....I think there is. Maybe you forgot to include an edit in one. I'm just thinkin off the top of my head here, so I could be wrong.

There is 'responsive.css' cant see anything in that file :emb

The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

Any other files for mobile. I haven't seen all the files lately and I can't remember right now.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

lesmond

#4
QuoteAny other files for mobile. I haven't seen all the files lately and I can't remember right now.
I'm sure the problem lies in index.template.php I need to move it to the right place...


The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

Ok, I will try to look at this tonight. I'm a bit rusty and don't use my phone on websites other than for weather, but I will try to check it out later tonight if I can. Tomorrow at the latest.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled

#6
What exactly did you change? What was it originally and what did you change it to?

EDIT: I just had a look at that file and it appears that you are missing this:

<a class="menu_icon mobile_user_menu"></a>
So, the code should be like this:

// Show the menu here, according to the menu sub template, followed by the navigation tree.
// Load mobile menu here
echo '
<a class="menu_icon mobile_user_menu"></a>
<div id="main_menu">
<div id="mobile_user_menu" class="popup_container">
<div class="popup_window description">
<div class="popup_heading">', $txt['mobile_user_menu'], '
<a href="javascript:void(0);" class="main_icons hide_popup"></a>
</div>
', template_menu(), '
</div>
</div>
</div>';

theme_linktree();

In the code you've posted you can see the double spacing after the first line of code... ;)

lesmond

Quote from: Skhilled on Jul 20, 2021, 08:55 AMEDIT: I just had a look at that file and it appears that you are missing this:


<a class="menu_icon mobile_user_menu"></a>

Sorry I posted the wrong code above, that section is in mine.

The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

#8
I downloaded your index.template.php file and this is the code I found:

    // Load mobile menu here
    echo '
               
                <div id="main_menu">
                    <div id="mobile_user_menu" class="popup_container">
                        <div class="popup_window description">
                            <div class="popup_heading">', $txt['mobile_user_menu'], '
                                <a href="javascript:void(0);" class="main_icons hide_popup"></a>
                            </div>
                            ', template_menu(), '
                        </div>
                    </div>
                </div>';
    theme_linktree();


Seems you are missing a line.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

lesmond

sorry here is the correct index.template.php I should really sort them out better  :emb

You cannot view this attachment.

The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

I can't find any errors with that at all.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

lesmond

#11
No errors, I want that section moving into the header/wrapper  :dontknow

at the moment it looks like this in Mobile view



but it should look like this, notice the logo and menu bar


The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

Why does the logo not show. :???
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

lesmond

Quote from: Bigguy on Jul 20, 2021, 04:26 PMWhy does the logo not show. :???

That's what I am trying to figure out all along.

something to do with this section of code needs to be moved...

// Show the menu here, according to the menu sub template, followed by the navigation tree.
// Load mobile menu here
echo '
<a class="menu_icon mobile_user_menu"></a>
<div id="main_menu">
<div id="mobile_user_menu" class="popup_container">
<div class="popup_window description">
<div class="popup_heading">', $txt['mobile_user_menu'], '
<a href="javascript:void(0);" class="main_icons hide_popup"></a>
</div>
', template_menu(), '
</div>
</div>
</div>';

theme_linktree();

The only person who got all his work done by Friday was Robinson Crusoe

Bigguy

I don't play with mobile a lot. Do you have an unedited copy of index.template.php
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin