How to create html page for using it in android Application??? (For Creating Apps like Shayri App, Jokes App)

If you will learn to create html page then you can easily make Professional Shayri Apps, Jokes Apps and Many Other Apps.

First and for most you don’t need to have any spacial software to create html web pages to make Professional Shayri Apps. you can create html page on your notepad, notepad++, textpad etc. which are generally available in each computer. After opening note pad first you have to do is open a new tab and save it as html file. you can do it simply by writing your file name followed by .html or by choosing file type html.

Now when you save html file successfully now you have to write some codes which is easy, don’t worry i will tell you everything. while you start coding first you have to declare document type in starting. you can do it simply writing this: <!doctype html>

Now you will start you main html page coding. In html you almost for everything you have to write an starting tag and a ending tag. Just like brackets in English, if you start brackets you have ti close it somewhere. For starting html page write this tag: <html>  and for ending html page write this tag: </html>

Now inside these html tag you have to start your head tag simply by writing this tag: <head> and close this head with this tag: </head>

Now inside these head tag you have to write your page title like this: <title> XYZ </title>    here XYZ is the page title. you can write your own page title it will look like this:

 

Now after head tag got end you can start your body tag. Start the body with this tag: <body> and end the body with this tag: </body>   Everything you want to show in your html page will have to write inside these body tag.

In any page first thing is heading. so for writing heading you can write like this:  <h1> Write Your Heading Here  </h1>

Now if you want to customize your heading you can add your customization requirements in the same line before Heading tag starts. just like this:  <font color=”red” align=”center”> <h1> Write Your Heading Here </h1>

you can change properties according to your requirement. like font color, font size, font style etc… you can use <h2> </h2> tags for sub-heading which will automatically reduse the text size from the main heading <h1> </h1> . if you will write <h3> </h3> it will automatically become smaller than <h2> </h2>. So if you want same size ho headings you have to write same heading tags.

After you write heading and customized it. Now you want to write paragraph so for paragraph we use p tag like this: <p> </p> For starting paragraph write this tag:  <p>  and for ending Paragraph write this tag:  </p>

And if you want to perform any function like copy paste or something you have to give paragraph id inside starting tag of paragraph like this: <p id=”p1″>

For Example:

Result:

 

In Coding section i have used <br> at the end of each line. This <br> tag breaks the line and comes in next line. So if you want to go in next line you have to write <br> at the end. if you will simply press enter button of keyboard it will come in next line in coding section but it will not come in next line in real html page. It will show in same line in real html page. so we have used <br> for line breaking.

 

This was the whole story of creating a page in html. Now if you want to create a button to copy any of your paragraph then you have to simply copy and paste below given code inside your body at the starting of your body. this will create a copy function in your page.

<script src=”https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js”></script>
<script>
function copyToClipboard(element) {
var $temp = $(“<input>”);
$(“body”).append($temp);
$temp.val($(element).text()).select();
document.execCommand(“copy”);
$temp.remove();
}
</script>

 

After pasting this code at the starting of the body, Now you have to create a button for clicking to get copy the text inside the paragraph. For this copy and paste this code anywhere inside body tag:

<style>
.button1 {background-color: white; color: blue; width: 48%; text-align: center; cursor: pointer; padding: 3px 2px; border: 2px solid #2445a2;}

</style>

Inside this code you can customize your button. You can change all the properties of button according to you demand.

 

After you customized your button now you have to paste below code everywhere, where you want to show your button in the page.

<div align=”center”>
<button onclick=”copyToClipboard(‘#p1’)”; class=”button1″>Copy Shayari</button>
</div>

 

Only you have you have to change in this code id paragraph id. In this case we want to copy paragraph 1 so we have written  (‘#p1’)

if you want to copy paragraph 5 then you can write it as (‘#p5’)

if you want to copy paragraph 6 then you can write it as (‘#p6’)

Example: (For paragraph 5th)

<div align=”center”>
<button onclick=”copyToClipboard(‘#p5’)”; class=”button1″>Copy Shayari</button>
</div>

(For paragraph 6th)

<div align=”center”>
<button onclick=”copyToClipboard(‘#p6’)”; class=”button1″>Copy Shayari</button>
</div>

 

Now you can Create your own html page with Confidence…

Download HTML Page Sample

For more Details watch this Video on LunaticApps 

 

, , , , , , , , , , , , , ,

Post navigation

4 thoughts on “How to create html page for using it in android Application??? (For Creating Apps like Shayri App, Jokes App)

  1. Thanks on your marvelous posting! I certainly enjoyed reading
    it, you can be a great author.I will be sure to bookmark your blog and definitely will come back in the future.
    I want to encourage you to continue your great posts, have
    a nice afternoon!

  2. Hi, i feel that i noticed you visited my weblog so i came to “return the prefer”.I am attempting to find things to enhance my website!I assume its adequate to make use of a few of your ideas!!

Leave a Reply

Your email address will not be published. Required fields are marked *