nav bar homepage and search problems

Cleopatra

Addicted
Joined
Sep 23, 2013
Messages
971
Reaction score
0
FP$
1,697
hi i have a nave bar that contains a lot of things
everything redirects to the right page except home page and search buttons they keep redirecting me to the index page

this is my header template

<!-- begin wrapper -->
<div id="wrapper">

<!-- begin logo -->
<div id="logo">
<a href="{$mybb->settings['bburl']}/"><img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" class="logo" /></a>
<a name="top" id="top"></a>
<div id="panel">
<div id="panelcontent">{$welcomeblock}</div>
</div>
</div>
<!-- end logo -->
<br/>
<div class="clear"></div>
<!-- begin navbar -->
<div id="navbar">
<ul id="nav">
<li><a href="{$mybb->settings['bburl']}/index.php" class="current">Forum Home</a></li>

<li><a href="{$mybb->settings['bburl']}/home/">HomePage</a></li>
<li><a href="{$mybb->settings['bburl']}/search.php">Search</a></li>
<li><a href="{$mybb->settings['bburl']}/ezgallery.php">Gallery</a></li>
<li><a href="{$mybb->settings['bburl']}/memberlist.php">Member List</a></li>
<li><a href="{$mybb->settings['bburl']}/announcements.php?aid=6">Points System</a></li>
<li><a href="{$mybb->settings['bburl']}/announcements.php?aid=5">Global Rules</a></li>
<li><a href="{$mybb->settings['bburl']}/misc.php?action=help">Help</a></li>
<li><a href="{$mybb->settings['contactlink']}">Contact Us</a></li>

</ul>
</div>
<!-- end navbar -->

<!-- begin content wrap -->
<div id="contentwrap">
<div id="container">
<hr class="hidden" />
<br class="clear" />
<div id="content">
{$pm_notice}
{$bannedwarning}
{$bbclosedwarning}
{$unreadreports}<!-- NewCommentInImage -->
{$alertprofilealbums}<!-- /NewCommentInImage --><!-- ProfileComments -->
{$comments_alert}<!-- /ProfileComments -->
{$pending_joinrequests}
<navigation>
<br />
 
Why don't you contact mybb support? Or you can just upload the new mybb files again >.>
I am not good with php (_ _)
 
Well for the HomePage one, you may not have a HomePage generally speaking. You may be on about the portal. Try adding:

Code:
<li><a href="{$mybb->settings['bburl']}/portal.php">Homepage</a></li>

Also, instead of the search part. You could add this (Under </ul>)

Code:
 <div class="menu_search float_right" >

						<form method="post" action="{$mybb->settings['bburl']}/search.php">
						<input type="hidden" name="action" value="do_search" />
						<input type="hidden" name="postthread" value="1" />
						<input type="hidden" name="forums" value="all" />
						<input type="hidden" name="showresults" value="threads" />
						<input type="text" name="keywords" value="{$lang->toplinks_search}" onclick="if(this.value=='{$lang->toplinks_search}')this.value='';" onblur="if(this.value=='')this.value='{$lang->toplinks_search}';"/>
						<input type="submit" class="menu_btn" name="submit" value="" />
						</form>
					</div>

That will add a working search bar instead. 🙂
 
For the homepage link you have this:

Code:
<li><a href="{$mybb->settings['bburl']}/home/">HomePage</a></li>

If you look, it is directing the user to a directory named "home" that is within your forum's root directory. Is that directory actually there?

For instance, if your forum's URL (address) is http://somedomain.com/forum/ then the homepage (according to your code) is located at http://somedomain.com/forum/home/

Also, for search you have this:

Code:
<li><a href="{$mybb->settings['bburl']}/search.php">Search</a></li>

It is directing the user to a file named search.php that is within your forum's root directory. Is that file actually there?

For instance, if your forum's URL (address) is http://somedomain.com/forum/ then the search page (according to your code) is located at http://somedomain.com/forum/search.php

Verify that the links are correct.
 
Everything is on my root And they wirk great if you changed to onther theme
Try changing the theme to fancy black
And check you will find them working
But with my default theme they don't
 
Then the variable "{$mybb->settings['bburl']}" isn't being set. Why don't you replace that with the actual URL to your forun?
 
But it is working with other pages
The problem is only with homepage and search page<br /><br />-- 06 Aug 2014, 18:16 --<br /><br />But it is working with other pages
The problem is only with homepage and search page
 
Back
Top Bottom