I have created a bootstrap navigation bar that works perfectly in its own html file. The dropdowns on this file will open and close like they should. I want to include this file onto my other pages so that I don't have to update every single page's navigation bar if I ever change it. I have chosen to do this through using server side includes. My other pages are saved as asp files to allow for server side includes.
When I use
<!-- #include virtual="/navigation.html" -->
the dropdowns in the navigation are able to be expanded, but they will not go back up. Any ideas what may be going wrong?
I figured out the problem. My include files only needed the html code, no links to javascript, css, or opening and closing html,head, or body tags.
Related
I copied a mobile menu from "https://www.100percent.com/" (mobile version). My HTML local page it works fine, but when I put the code in the PHP "header.php", the solution does not work completely.
The DIV that contains the Drawer Is Visible is not created and does not appear.
The site is "https://m.intensebikeshop.com.br".
These pictures show the difference.
A: My PHP page online
B: My local HTML page
The method create 2 divs before </body>, but this tag is the footer.php file. Maybe this is the problem I am not sure.
My page is composed by 3 files (header, home-page and footer.php).
I tried using the z-index. But I think the problem is the method. I see the JS file is not creating the DIVs.
The JS file is: Theme file JS
I have just started this small project for a website and I thought i should use only one menu bar for the whole site, since it's kinda tedious to have to change all the links for all the pages in the menu bar.
I have found the following code for loading my menu bar:
<div id="nav-placeholder"></div>
<script type="text/javascript">
$(function(){
$("#nav-placeholder").load("navbar.html");
});
</script>
It works fine and I do get my menu, however I find that the links basically work the same as if I just had the menu on the page instead of loading it.
So for example if I am on the root directory everything loads fine, but as soon as I move up one directory the links wont work anymore.
I know this can be fixed by simply changing them, but then I would have to make more than a couple of navbars for the whole site?
Any fix around this?, hope you guys get my idea, would appreciate any help.
If you're using anything that can dynamically create pages on the fly like ASP or PHP then you could make a separate page with just the menu in and include it in each page that needs it. For example:
ASP:
<!-- #Include virtual="menu.aspx" -->
PHP:
<?php include 'menu.php';?>
Hi and thanks in advance for any help.
I'm working on a multilanguage joomla! website that runs some roksprocket mosaic modules positioned right after single article content.
When I navigate the site by using the default language everything works great, but when I switch to a non-default language I experience URL problems with content loaded inside the roksprocket module by the "load more" button or by the filtering tags.
The first block of visible items, loaded with the page, link to the correct articles. But when I filter the items or click the load more button, the new loaded articles links are not working. Default language tags are automatically added to the url of the links. So I get:
www.mysiteurl.com/default_language_tag/alias_of_the_current_page_tag/category_tag/article_tag
This happens both with and without SEF URLS activated.
I would try to avoid these added tags by cutting them out from the html with javascript, but I don't know what is triggered after the loading of the new content.
Any suggestion?
Thanks a lot for your answers.
I started using bootstrap recently, and I saw that this page: components highlighted which section of the page you were on in the sidebar. How do they do this?
This can be done with scrollspy, a script which is now included in the bootstrap.js file.
All the script does is watch where you are on the page based on where you place an id on a containing tag.
You can also enable scrollspy for a specific element using:
$('body').scrollspy();
Take a look here: http://jsfiddle.net/adamp/LWWCb/3/
i use bootstrap twitter 2 in my page.
I have a dropdown menu that works without problems except when i load the openlayers.js file.
When i navigate to other pages it works, but when i got access in the page where i load the openlayer.js file it crashes (the style is ok but the dropdown functionality is not working)
I believe that is an openlayers conflict because if i don't load this js file then the menu works without problems.
How can i solce this conflict ?
Thank you in advance!