• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

    • 😌 This community is user driven. Be polite with other users.
    • 👉 Is required to purchase a Chevereto license to participate in this community (doesn't apply to Pre-sales).
    • 💸 Purchase a Pro Subscription to get access to active software support and faster ticket response times.
  • Chevereto Support CLST

    Support response

    Support checklist

Guest menu bar

seanbrai

Chevereto Member
I would like to add a custom link to the guest and member menu bar. (See attached image) Can someone tell me what file to edit to add this. I don't want to add something to about, I want to add a link before Upload.
Thanks,

Sean

From this
menu.png
to this
new menu.png
 
I have discovered how to add a new link to the navbar. However as a result of the link this has occured on my site. How do I get ride of it? I added
<?php { ?>
<li class="top-btn-el">
<a href="https://www.bdsmregistry.org/registration"><span class="top-btn-text"><span class="icon icon-file"></span><span class="btn-text phone-hide phablet-hide"><?php _se('Registration'); ?></span></span></a>
</li>
<?php } ?>
to the header.php in my theme and now I can't get this to go away. (black">)
Sean

wtf menu.png
 
The even weirder thing is, that when I undid all of the changes and put the file back to its original form, that (black">) won't go away.
 
To answer your original question
Via the following code at line: ~ 176
PHP:
            <?php if (is_upload_enabled()) {
Above the insert
PHP:
            <li class="top-btn-el phone-hide">
                <a class="top-btn-text"><span class="icon icon-cloud-upload"></span><span class="btn-text phone-hide phablet-hide">LINKNAME</span></a>
            </li>
You have to change the content itself.

Why is now with you black"> I can not tell you, this value does not exist in the file mentioned by you.
So this must be a value added by you.
 
That's the weird part, is that its not. It just appeared after I modified the header.php with the above code. I have even tried to search the entire for for black"> and nothing comes up. I am open to any possible suggestion, because the even more aggravating part is that I have restored the file back to its original and that black"> still won't go away. The only thing is to install the software on another domain and copy the file off a fresh install, because undoing all the changes isn't working.
 
To make things more interesting, it does not like that line of code. I replaced the header.php with the original and the black"> went away. As soon as I tried to put the code back in, the black"> came back.
 
Well I found out that simply putting a few spaces in the code caused the black"> to show up. I didn't add anything, just hit enter a few times.coding wtf.png

and then this shows up.

wtf menu.png
 
[CODE lang="php" highlight="19-21"] <?php if (get_system_notices()) {
?>
<li data-nav="notices" class="phone-hide pop-btn pop-keep-click">
<span class="top-btn-text"><span class="icon icon-notification color-red"></span><span class="btn-text phone-hide phablet-hide"><?php _se('Notices (%s)', count(get_system_notices())); ?></span></span>
<div class="pop-box anchor-center c8 arrow-box arrow-box-top anchor-center">
<div class="pop-box-inner padding-20">
<ul class="list-style-type-decimal list-style-position-inside">
<?php foreach (get_system_notices() as $notice) {
?>
<li><?php echo $notice; ?></li>
<?php
} ?>
</ul>
</div>
</div>
</li>
<?php
} ?>
<li class="top-btn-el phone-hide">
<a class="top-btn-text" href="#"><span class="icon icon-spinner3"></span><span class="btn-text phone-hide phablet-hide">LINKNAME</span></a>
</li>
<?php if (is_upload_enabled()) {
?>
<li data-action="top-bar-upload" data-link="<?php echo CHV\getSetting('upload_gui') != 'js'; ?>" data-nav="upload" class="<?php if (G\is_route('upload')) {
echo 'current ';
} ?>top-btn-el phone-hide"<?php if (!CHV\getSetting('guest_uploads')) {
?> data-login-needed="true"<?php
} ?>>
<<?php echo CHV\getSetting('upload_gui') == 'page' ? ('a href="'.G\get_base_url('upload').'"') : 'span'; ?> class="top-btn-text"><span class="icon icon-cloud-upload"></span><span class="btn-text phone-hide phablet-hide"><?php _se('Upload'); ?></span></<?php echo CHV\getSetting('upload_gui') == 'js' ? 'span' : 'a'; ?>>
</li>
<?php
} ?>[/CODE]
screenshot-2019.12.05-18-58-12.png
So I've tried it myself at one of my instances.
It works wonderfully at the designated location.

You may have to flush your cache or another file of the themes that has been messed up is responsible.

Sorry I can not help you with this.

Maybe it's up to your editor, which looks like it's an online variant.
I myself always used the Notepad ++ with an FTP, SFTP or SCP connection to the server.
and really always make sure that the document is formatted as UTF-8.
 
I put in the exact code in the exact place you did and this is what I get

new code wtf.png


Exactly as it appears

new menu wtf.png
 
You won't ever find a needle if you don't know where to look for, specially if you don't start backwards.

1. You got a black"> which is printed here in the HTML:

1575575014274.png

2. As you may notice, there's a meta tag inside the header class attribute. So you should check your editing near:

Code:
<header id="top-bar" class="top-bar

3. This is how the demo prints that section:

1575575165488.png

Hope you can identify the issue.
 
Problem: solved ☑

Please!

In the appendix the original file incl. The new button
 

Attachments

  • header.zip
    3.9 KB · Views: 12
Back
Top