Hi,
I want a button, which when clicked sends you to another page in my asp.net
webapp. I currently use javascript:self.location to do this, but if
javascript is off in the client this wouldn't work. Is there a better way?
Thanks,
Martin 6 998
have you tryed using the onclick button event
eg
<input type="submit" name="next" value="next" onclick="yourpage.asp">
hope it helps
just a try
Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin
There is no need to try that code. It doesn't work.
The onclick property is an client script event. You can't put an url in
it and expect it to do anything with it. You have to put Javascript code
in it:
<input type="submit" name="next" value="next"
onclick="window.location='yourpage.asp';">
theo wrote: have you tryed using the onclick button event eg <input type="submit" name="next" value="next" onclick="yourpage.asp"> hope it helps just a try Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin
If Javascript is disabled you have only two options:
:: Use the asp:Button control which make a Response.Redirect in the
click event.
:: Use a link. You can use CSS to give it a button like apperance.
Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin
"Göran Andersson" <gu***@guffa.com> wrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl... If Javascript is disabled you have only two options:
:: Use the asp:Button control which make a Response.Redirect in the click event.
Doesn't that use javascript? (the __doPostBack function)
:: Use a link. You can use CSS to give it a button like apperance.
Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin
no. asp:buttons render as submit buttons, and do not use client script to
postback. not sure why you would not use an anchor for what you want.
-- bruce (sqlwork.com)
"Martin Eyles" <ma**********@NOSPAMbytronic.com> wrote in message
news:12*************@corp.supernews.com... "Göran Andersson" <gu***@guffa.com> wrote in message news:%2****************@TK2MSFTNGP04.phx.gbl... If Javascript is disabled you have only two options:
:: Use the asp:Button control which make a Response.Redirect in the click event.
Doesn't that use javascript? (the __doPostBack function)
:: Use a link. You can use CSS to give it a button like apperance.
Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin
"bruce barker (sqlwork.com)" <b_*************************@sqlwork.com> wrote
in message news:OF**************@TK2MSFTNGP04.phx.gbl... no. asp:buttons render as submit buttons, and do not use client script to postback. not sure why you would not use an anchor for what you want.
-- bruce (sqlwork.com)
Thanks,
I'll probably use anchors, as I think I can fix the styling. I just
wanted to be sure I'd covered all options, which I think have been now.
"Martin Eyles" <ma**********@NOSPAMbytronic.com> wrote in message news:12*************@corp.supernews.com... "Göran Andersson" <gu***@guffa.com> wrote in message news:%2****************@TK2MSFTNGP04.phx.gbl... If Javascript is disabled you have only two options:
:: Use the asp:Button control which make a Response.Redirect in the click event.
Doesn't that use javascript? (the __doPostBack function)
:: Use a link. You can use CSS to give it a button like apperance.
Martin Eyles wrote: Hi,
I want a button, which when clicked sends you to another page in my asp.net webapp. I currently use javascript:self.location to do this, but if javascript is off in the client this wouldn't work. Is there a better way?
Thanks, Martin This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Jan Tuxen |
last post by:
Jakob Nielsen in his most recent Alertbox
(http://www.useit.com/alertbox/20040503.html) tells web authors to
change the color of visited links.
I agree to his purpose: Help users understand...
|
by: deko |
last post by:
I'm trying to change the font style of a link when that link is clicked.
But the link (sometimes) includes a named anchor. So I need to test for a
given named anchor and apply style changes if...
|
by: Muffinman |
last post by:
Hi,
I have a webpage with two Iframe's. I want to be able to change the
target of all links in one frame so it will point to the other frame and
all this from the main page. Is this possible and...
|
by: rcmail14872 |
last post by:
I have a standard Access database with standard Forms and it is not
split. I am going to run the upsizing wizard to change the data tables
to SQL. I also need to split the database and I am going...
|
by: sastwhc |
last post by:
sastwhc wrote:
> *Hi all
> I try change language client side programatically.In my case farsi a
> Right to Left Language,the curser direction changed by dir=rtl TAG
> changed to correct direction...
|
by: vikramp |
last post by:
Hi,
I am storing theme in web.config using <pages theme="mytheme"/>.
I am then using the following code to read it from my webpage:
Configuration config =...
|
by: Andy |
last post by:
If I open, edit and save the web.config file directly on the
webserver, the
web server becomes unavailable. When I reset IIS, I get the 'Server
Application Unavailable' message appear for that...
|
by: spncc |
last post by:
i'm making Form authenticate page to let the user first logon before
using the application. However, like most security manner, the new
user is needed to first logon and forced to change password...
|
by: Keith G Hicks |
last post by:
I have a pretty small project right now that I just started last week. I
have one master page and several content pages based on that master. I had
originally neglected to set up the master with...
|
by: _Who |
last post by:
Seems to me that I should be able to do something like:
....runat="server" change from white.css to black.css...
Of course if I could have found out how, I wouldn't be bothering you.
Is...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
| |