riceman0
asked on
How to make MaintainScrollPositionOnPostBack work on Safari browsers
I am creating an ASP.NET web page, which is working great, a big layout of all sorts of webform buttons. The problem is every time I press a button, it reloads and goes back to the top of the page. This is really annoying. Some wise man told me about the MaintainScrollPositionOnPo stBack flag
https://www.experts-exchange.com/questions/22913286/After-ASP-NET-button-is-pressed-how-to-return-to-exact-scroll-position-on-web-page.html
this fixes the problem from IE and firefox, but frustratingly, it doesn't seem to work when I browse to the page from safari (which is actually from where I would be most accessing the site). I found what sounds like the problem at:
http://forums.asp.net/p/1094179/1651390.aspx
but the guy is vague about his solution, says
" However we have fixed it, and posting the solution for others. All we needed to do was to edit the Browser Capabilities file, and explicitly set it so that MaintainScrollPositionOnPo stback is supported on Safari Browsers."
I am too novice to know how to do this. Can anyone help me "edit the Browser Capabilities file, and explicitly set it so that MaintainScrollPositionOnPo stback is supported on Safari Browsers"?
https://www.experts-exchange.com/questions/22913286/After-ASP-NET-button-is-pressed-how-to-return-to-exact-scroll-position-on-web-page.html
this fixes the problem from IE and firefox, but frustratingly, it doesn't seem to work when I browse to the page from safari (which is actually from where I would be most accessing the site). I found what sounds like the problem at:
http://forums.asp.net/p/1094179/1651390.aspx
but the guy is vague about his solution, says
" However we have fixed it, and posting the solution for others. All we needed to do was to edit the Browser Capabilities file, and explicitly set it so that MaintainScrollPositionOnPo
I am too novice to know how to do this. Can anyone help me "edit the Browser Capabilities file, and explicitly set it so that MaintainScrollPositionOnPo
ASKER
Under "add new item" to my project, I did see Browser File so I added it. It does seem to contain XML that describes browser capabilities. It also refers to the folder you specify, which contains XML for various browsers. But no safari!! Do you see safari info in your folder?
What version of Safari are you working with?
Here are some possible user agent strings:
Safari FAQ
http://developer.apple.com/internet/safari/faq.html#anchor2
Bob
Here are some possible user agent strings:
Safari FAQ
http://developer.apple.com/internet/safari/faq.html#anchor2
Bob
ASKER
I am a complete novice at this. I mean very novice. Do I enter a new "user agent string" into my default Browser file below? Any idea where?
****
<browsers>
<browser id="NewBrowser" parentID="Mozilla">
<identification>
<userAgent match="Unique User Agent Regular Expression" />
</identification>
<capture>
<userAgent match="NewBrowser (?'version'\d+\.\d+)" />
</capture>
<capabilities>
<capability name="browser" value="My New Browser" />
<capability name="version" value="${version}" />
</capabilities>
</browser>
<browser refID="Mozilla">
<capabilities>
<capability name="xml" value="true" />
</capabilities>
</browser>
</browsers>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
2) Maybe they were talking about the .browser files in the C:\WINDOWS\Microsoft.NET\F
3) There is a place where you can get an update browscap.ini:
http://browsers.garykeith.com/downloads.asp
Bob