one TMLH footer page to show all my web page - html

i am making side all pages static html
i want to make footer another page and i want to show all my web page
because when i have to make change in footer then i will have to change all of my web pages its so difficult i want when i change one page it will appear all pages
how can i do it please help me i am using html pages
Thank's

There is no way to use this using straight HTML - you will need some server side technology - PHP, ASP, Server Side Includes, etc.
Here is a pretty basic break down of some of the options. http://webdesign.about.com/od/ssi/a/aa052002a.htm

Sure no problem. when testing from your hardrive IE will bring the content in, google will not. from a website all browsers will work.
add this to the bottom of your html pages:
<span id="include_footer"></span>
then add a jquery ajax call to get the footer data and replace the span content in the head of html page:
<script type="text/javascript">
$(document).ready(function () {
//include the footer html
$.ajax({
url:"footer.html",
context: document.body,
success: function(response){
$("#include_footer").html(response);
},
error: function(response) {
alert('error loading file');
}
});
});
</script>
Enjoy :)

I see that you're using HTML. Have you considered using PHP? All you need to do is change your page to .php instead of .html and you have a php page. Now, if you make a page, say footer.php, on each of your pages your can add this line:
<?php include 'my/file/path/footer.php'; ?>
Anything that you have in your footer.php file will be included in that page.

Common web servers allows you to prepend or append contents to all pages on particular web app.
For instance in IIS, you can select a an html file for every document you web server returns:
it could be found in the IIS website/app properties then in Documents tab.
For Apache Server:
http://perl.guru.org/scott/hobbies/apache/

For purely static HTML, some IDEs can handle this effectively. In Dreamweaver, you can create a template that your site will use. This template can include an editable section and a non-editable section that contains your footer. You then create pages based on this template. When you update the template, Dreamweaver will handle updating all other pages on your site that are based on that template.
Edit: This is an example of a template in Dreamweaver that I made a couple years back for a group project.
The Bobs (Screenshot)
The area surrounded by the blue-green rectangle is the editable region (for pages created based on this template).

Related

Is it possible to create an internal html page to my index.html?

I'm creating a new website and I will have different pages on it. However, instead of creating new HTML files for each page and an anchor for each, I want all my pages contained in one HTML file. Is it possible in any way?
You can try Vue js or React js or many js frameworks ... which contain components.
Using HTML
You can control HTML page section how tabs working in HTML, take a look in Bootstrap Tabs, or you can hide/show sections using CSS or using JS, you may store HTML for each page in array of js and load that HTML to Body based on URL you create
Using Server Side Language
Also if you need single page application with multiple pages you need a Server Side language, where Database contains your website configurations and you can load based on the URL each page's layout or text like heading forms etc...

Creating a plain html home page AMP with WordPress running the other pages

Gday
I like to know how you would go about creating a home page in plain html and have WordPress run the other pages?
The reason is I’d like to create a solely plain html website but I need WordPress for my contact page it has a large form on it and I use a plugin to generate it and forms are a bit beyond my knowledge at the moment to create a contact page myself.
(I have tried creating a template page but then WordPress adds unnecessary code [from plugins ] and makes the AMP invalid)
Honestly I'd try and keep it self contained in WordPress itself.
If for some reason you really want a separate HTML/PHP Homepage, follow these steps:
Add a my-homepage.php file to your /wp-content/themes/ACTIVE-THEME directory
Inside that file put the following code:
Add a new page (Pages > Add New)
Give it a recognizable name like "My Homepage"
In the "Template" selector on the right hand side, pick "My HTML Homepage" and click Publish
Go to Settings > Reading, change Your homepage displays to A static page and pick the page you just made
Now you can add your own code as you see fit. Nothing "WordPress" related will get loaded or hooked in since there's no functions on that file - so you're free to code HTML (or PHP) to your heart's content.
You can see a bit more indepth answer over on WPSE: https://wordpress.stackexchange.com/questions/296592/how-to-use-custom-html-file-instead-of-wordpress-homepage

Navigation html pages liferay portlet

I'm new in liferay, into my portlet i have html pages with angularJs not jsp.I would ask about how to navigate between these html pages into my portlet..thanks.
I think you are bit confusing about technology.
JSP pages always generate HTML page for your browser.
It means that you create a JSP page containing just HTML nothing changes (this is correct from a developer point of view... thinking to server job this is not true... but think it is true for our purpose).
Client side technology you are going to use is not relevant from a portlet point of view (it can be a problem if your theme uses some not compatible libraries...) but in general whatever library you use (angularjs, backbone etc.).
It means that you can create html or jsp pages containing all the angularjs code you want... and everithing should work fine.
If you want to manage navigation between "pages" in the same portler (e.g. from view.html to details.html) then you have to mind, simplifying, that portlets haven't pages: your portlet will be added in a page of the portal (with its own URL).
So you can rename your html files in jsp files (as I told, nothing changes), then you can tell to portal what is the correct URL to load by JSP code.
For example for making a link to "details.jsp" in your "view.jsp" you can write a code like following:
<a href="<portlet:renderURL>
<portlet:param name="jspPage" value="/path/to/your/details.jsp" />
</portlet:renderURL>">Text</a>
Obviously you can use the <portlet:renderURL>...</portlet:renderURL> code wherever you want... because it will be translated in a string before sending to browser... like in javascript var url = "<portlet:renderURL>....</portlet:renderURL>"
You shouldn't forget to put these lines at the beginning of yout jsp files:
<%# taglib uri="http://java.sun.com/portlet" prefix="portlet" %>
<portlet:defineObjects />

meteor - change contents of HTML <head> section for different templates?

I have a scenario in which I want to test four different versions of a page, each with different javascript content loaded in the HTML head section.
I would like switching between the templates to behave as though the page has been re-loaded, clearing the state and re-running the JS in the head and body of the HTML file.
Can I do this with four different Meteor templates?
The way I'd do this is to append the JS to the head from within the template's onRendered method, like so:
Template.templateName.onRendered(function() {
$('head').append("insert your script here");
});
So I'd keep the default head free of any of these js files, and just add them in depending on what template the user is on. You can also manipulate the user experience from within the onRendered method as well, using things like $(window).scrollTop(0) to make it appear as though the page has refreshed.

Insert Code Into HTML

I have a web site that gets a new page every couple weeks, and that means I need to update the menu to have the new page in every single one. I'm wondering if there is a way to have an external text or .htm file that I can basically insert into the web page. That way I can put the menu in the external file and call it wherever I want it. So I only have to edit one thing when I get a new page.
Thanks in advance.
Edit: This is a drop-down menu with ul and li tags with an external style sheet for them. So this needs to work for that too. Thanks
Have a single HTML page like so:
<html>
<head></head>
<body>
HTML OF LINKS HERE
</body>
</html>
Then save it as my_links.html and into the page you want to insert it... do the following. Copy and paste the whole page and it as FILENAME.PHP and then use this code:
<?php include("my_links.html"); ?>
Congratulations, you have just used PHP! Learn more about the including pages here.
This is very easy and common to do on sites that use a server-side language behind them (PHP, ASP.NET, etc.)
If you don't want to use a server side language, than an <iframe> is your only option.
If you want to use HTML, and only html (no server side programming or javascript), you can use Server Side Includes embedded into your html files. Your web server may need to be configured to accept them.
If you are using server side include and you had navigation in a separated file, yes you can just edit things separate.
You can also do this using jQuery.
$('#elementid').load('page.html');
http://api.jquery.com/load/
But this will not be SEO friendly.
Also if someone has scripts turned off in their browser, then this will not work.