Solved

HTML Button

Posted on 2008-06-26
7
162 Views
Last Modified: 2010-04-21
I have a webpage with a button on a form, is there a way to when the user clicks on the button it will open up excel and the file located in \\wlls\208\bobby.xls.
0
Comment
Question by:ASOSWE
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 11

Expert Comment

by:asafadis
ID: 21872616
I'm not sure if the URL '\\wlls\208\bobby.xls' would work... but this is the idea:
<a href="\\wlls\208\bobby.xls"><button>Download Excel File!<button></a>

Open in new window

0
 
LVL 18

Accepted Solution

by:
carlnorrbom earned 500 total points
ID: 21872871
Hi,

A more smooth implementation might be:

<input id="btnOpenExcel" type="button" value="Open bobby.xls" onclick="Javascript:window.open('file://wlls/208/bobby.xls');"/>

Try it out and let me know.

/Carl.
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 21872885
asafadis: Never wrap a button in a link
Instead use a form or the onClick
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 
LVL 11

Expert Comment

by:asafadis
ID: 21874411
@mplungjan:
the form... ok
"onclick" has the risk of not working if javascript is disabled in the client's computer.  It's an unnecessary risk.  Using a form, for example, is a perfectly javascript-independent solution that does the same thing.


why not wrap a button with a link?  just curious...
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 21875403
because many browsers will not understand what you click, the link or the button
0
 
LVL 18

Expert Comment

by:carlnorrbom
ID: 21923757
Hi,

Did you manage to get this running or?

/Carl.
0
 

Author Closing Comment

by:ASOSWE
ID: 31470885
yes, thank you
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
website file permissions 4 55
PHP radio buttons with email not sending 24 89
CSS HELP 6 74
Element alignment and word wrapping 9 28
When you work with shopping cart / ecommerce relates web sites, you need to pass the certain form post details to the payment gateway process page with required details for the products items you give to order. Also you may need to track the ordered…
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now