Showing posts with label url. Show all posts
Showing posts with label url. Show all posts

Saturday, March 31, 2012

the beginner-examples

http://samples.gotdotnet.com/quickstart/aspplus/

I went to the url above, and I am following there pages
to get knowledge.

But several examples, "run sample", is not working.
How come they couldnt manage to keep them
working ?

I feel it is a little harder to learn, since it really isnt
a fully working tutorial-site.

/ martin kHi Takemeaway,

I noticed the same stuff but I learnt they've got heavy traffic on the site that hampers their performance!
Which ones didn't work? I just tried a few on that site and they seemed to work. More importantly, is there a specific question you had about one of those tutorials?
Try here, these all work:

http://asp.net/Tutorials/quickstart.aspx

The best solution of URL rewriting method

Hi,
I want rewrite url, but I don't know, whoch method is the best:
    ISAPI filters at the IIS Web server levelor HTTP modules
    or HTTP handlers
Which method is the best solution?
Thanks
You may want to read this >>http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/urlrewriting.asp

Looks like URL rewriting using http modules seems to be a better idea...

Wednesday, March 28, 2012

The clicking twice hair pulling doesnt do anything problem!

I have a single page in which everything is loaded from user controls based upon a specific value in the URL. The user controls are dynamically loaded (only load the user controls I need based upon the key in the URL). Within the user control is a form with a single button. When I click the button, nothing happens. When I click it again it does a full postback but all user controls are gone and I haven't the slightest idea if it upated or not. Now the form is in an update panel so it shouldn't be doing a post back.

To reiterate:

1. single page (call it default.aspx)
2. click a link with the key in the url (kind of like "?k=1048")
3. default.aspx runs through a case statement and find the key value that matches the URL then loads the user control.
4. user control has form on it
5. click the submit button, nothing happens. Click it again and it does a postback and all user controls are gone (AJAX didn't work).

So, any ideas about having to click twice and also why the update panel doesn't seem to be working?

thanks

^_^

ps. if i put the user control in a completely separate page where it isn't dynamically loaded, things work as intended.

To start with, when using Dynamic Controls, you should already know that you should RECREATE your controls on every page request. Keeping this in mind, you should keep track of which UserControl was loaded before and then reload it again!

Hope this helps,
Regards


That's nice but didn't help at all nor directed me to even an idea

What I did find was that when I removed the triggers from the update panel then the double-clicking went away and it operated as intended. but I wonder what will happen when I have multiple controls on a page that each have an update panel and I update one, will it cause the others to fire as well even with the mode set to conditional.

Does anyone have an idea of this cause that knows what they are talking about.

thanks

Saturday, March 24, 2012

The dreaded back button

Within an application, is there any way to "tamper" with the history of URLs retained by the browser, so that I can control the URL associated with the back button?

I guess this would entail deleting the last page from the linked list that the browser holds for pages that I do not wish to revisit.

Is this possible?Because of security reasons, you can't get the history from the client.

Tuesday, March 13, 2012

The Icon on the URL Textbox on Browsers: How do you do that?

Some sites like Cnn.com, Google, and MySpace have their own icons that show up on the URL TextBox of browsers, just to the left of http://. If you go to a site that doesn't have such an icon, the blank piece of paper with the top-right folded and the IE logo icon shows up as a default.

In regular HTML, how do we declare/specify the icon that shows up on a browser's URL TextBox? (Do you even do it in HTML?)

How do we do that in ASP.net?

Note: The icon I'm talking about also shows up on the tabs in IE 7.

You have to insert this line after the <head> tag in your html.

<linkrel="shortcut icon"href="images/MyComp.ico">

Make sure the image is file type .ico (for icon). Also, after inserting this line, the image may not appear immediately. Refresh the page by taking your mouse pointer to the little IE icon in the address bar (left most), click it and drag it outside the address bar (just a little bit so that you stay on the page) and then release it. This will refresh the page.

Heres an article for that:

http://msdn2.microsoft.com/en-us/library/ms537656.aspx


You must havefavicon.ico file in your root folder. You can generate your favicon.ico here:http://www.favicon.co.uk/


Is this an alternative way to associate your website with the icon? I'm not really following this one.

I went to the site and all it seems to do is to create a .ico file for you in the size you indicate, then you can download the file.

Does an ASP.net application then know about favicon.ico and to look for it in your root folder so that it'll render on people's browsers?


When you put favicon.ico in your root folder browser will show it. It doesn't matter if your web site is done with ASP.NET or you only have html pages. Only thing you have to add to your page is this:

<link rel="shortcut icon" href="http://links.10026.com/?link=favicon.ico">


I also just found out that if you're using master pages, the <link rel="shortcut icon" href="http://links.10026.com/?link=favicon.ico"> should be the master page file, and in the <head> tag of that master page file.