How to create a 'Download Button' in Blogger

You may have seen buttons which perform specific task when a user clicks.
For example, the button below allows you to download a file named "alltechland.txt"


Let's check out another example to see how diverse this button could be. This time, on clicking the button, you will be directed to the Gaming tab of Alltechland.



Now, I will show you how to create such button in very simple steps. Just follow me.

Step 1:


Goto Google Drive and sign in using your Google account.
  
Now click the upload button.



Then click files and select the file you want.

Now right click on the file you just uploaded and click "Share" and then again "Share".


Now a new window will appear. There will be a link in "Link to share" TextBox (See the picture below). Copy this link and paste it in notepad.


Now copy this red coloured link and paste it in the notepad.
https://docs.google.com/uc?export=download&id=PASTE-FILE-ID-HERE

Now Look In The First Link Which You Copied From Google Drive. It Will Be Having File ID which Looks Like 0B3s-Oiwdlw9tZDFpSGlUN1NZNVE
Copy this File ID and Replace It With PASTE-FILE-ID-HERE in The Second Link Which You Copied From Here.
Now, The Second Link Will Look Like This 
https://docs.google.com/uc?export=download&id=0B3s-Oiwdlw9tZDFpSGlUN1NZNVE

This whole process is demonstrated below:



Step 2:


Now go to blogger and create a new post.
Click HTML.







Step 3:


Now paste the following code there.

<FORM>
<INPUT Type="BUTTON" VALUE="Home Page" ONCLICK="window.location.href='PASTE-HERE-THE-LINK-YOU-CREATED-AT-THE-END-OF-STEP-1'"> 
</FORM>

This is it. You have successfully created a Button. Now you can reposition the button by click "Compose" (at left of the HTML button - see picture below)







If you want a specific webpage to appear when the user clicks the button (Like the 2nd example), paste the link of the website in the place of " PASTE-HERE-THE-LINK-YOU-CREATED-AT-THE-END-OF-STEP-1 " in the above code.

No comments :

Post a Comment

Share