Web Forms :: Rewriting The URL / Change This Www.mydomain.com/Default.aspx?
Apr 15, 2010I need to change this www.mydomain.com/Default.aspx towww.mydomain.com/Home i tryed this:
[Code]....
in web.config but nothig happend
I need to change this www.mydomain.com/Default.aspx towww.mydomain.com/Home i tryed this:
[Code]....
in web.config but nothig happend
I know this post is the same than other around but I can't get it to work the way I want, the thing is that the Login.aspx page have it in a folder not in the root of the directory, also the page that I want to redirect the user to is in the same folder, so far I got this in my web.config file
[Code]....
All pages contained in the Admin folder want it to be protected, the administrator needs to authenticate first, so my question is what I am doing wrong? need to take the Login.aspx and the admin.aspx out of the admin folder?
I'd like change masterpage.aspx "body" element style from default.aspx.cs. how can I do It?
View 15 RepliesHow to display text in another Web form
In Default.aspx I have a GridView. How to Default2.aspx, show data from Default.aspx?
I have a textbox on Default2.aspx.
In Default.aspx I have a GridView.
Data from the GridView I want to show the textbox (Default2.aspx).
I am using asp.net 4 with server 2008 r2 and I am trying to get Routing working how I want.Lets say I have a website which allows my customers to create there own page within the site. I could us something like routes.MapPageRoute("Businesses", "business/{businessName}", "~/Business/BusinessDetail.aspx");Which works ok if I want mydomain.com/business/mybusinessname. Is it possible to create mybusinssesname.mydomain.com instead?I dont want to have to make changes everytime in IIS,is it possible to do this with routing?
View 1 RepliesI have a classic ASP page which is actually written in server-side JavaScript (I need to do number base conversion and JavaScript handles this really well). Unfortunately once it has performed its number base conversion it needs to access a protected folder on our site and our ISP won't let us use ASP for this, although they do allow ASP.Net to access protected folders.
I know slightly less than nothing about ASPX but I have some sample VB code which can read content in the protected folder, and I am comfortable with VBScript and JavaScript so how hard can it be...but my questions are:
1. Is there any way that I can (server-side) utilise my existing JavaScript functions within an ASPX page?
2. Are there any built-in functions accessible to VB which will provide number base conversion (for example, provide a number and return it in Base36 or any other base, or provide a Base36 number and return it as an integer)? This option would lead me down the path of rewriting the whole thing (oh joy).
3. Or would it be easier to keep the ASP page and use that to perform the calculation and then make an AJAX like call from the ASPX page to the ASP page to return the information I need and keep the ASPX page for just accessing the protected area?
I am trying to secure very mixed content that is located in an ASP.NET directory. For purposes of this question, it can be ~/MyApp/.
I want all of the content in the directory and its subdirectories restricted to authenticated users. The default.aspx page, though, should be accessible to everyone. This is the web.config in that directory:
[Code]....
Now if you are an unauthenticated user, everything works fine if you request [code]....
The problem occurs in that visitors do not always request "Default.aspx". We have a default document configured so that they get Default.aspx even if they just request "/MyApp". An authenticated user works fine, but an unauthenticated user is directed to the login page.
Now I know that essentially this happens because even though the request for "/MyApp/" will actually end up serving up "/MyApp/Default.aspx", the security system is only checking for "/MyApp/" since that is what I requested. That is then getting the default security for the directory.
How can you configure an exception to allow access when no particular file is requested in the directory??
Is there some dependency between DefaultDocumentModule and UrlAuthorizationModule? In this environment, the UrlAuthorizationModule has been removed and re-added in order to make sure it fires for non-managed requests. I would not expect that to change the order of execution, though, since UrlAuthorizationModule usually goes after DefaultDocument.
A workaround could be to set up the opposite security with the directory being open, and then trying to secure individual files. Because of the (changing) number of files, and extensions, etc, and the fact that you cannot use wildcards in a <location>, this is not really a workable solution for me.
How to redirect Default.aspx to Default.aspx?id=1
View 7 RepliesFor example, I have master page MyMasterPage.aspx and content page MyDefault.aspx. I have many UpdatePanels at MyMaterPage.aspx, and also I have many UpdatePanels at MyDefault.aspx.
[code]....
I want JavaScript functionClickMenu(this) at input button [id="ButtonMaster1" @ MyMasterPage.aspx] pass its value ["Menu-1"] into text box [id="TextBoxDefault1" @ MyDefault.aspx], and then performing update / doing post-back to server ONLY FOR UpdatePanelDefault1.
I am looking forward an example code for JavaScript functionClickMenu(this).
how can i get the the Full URL in this Case "default.aspx#innerpages/Conferences.aspx"
View 4 RepliesFirst of all, thank you for the attention.
I am having some trouble, I am very new to asp.net, and the last problem I had, I spent about 59 hours trying to solve, Now I have a new one !
:D well, I guess this is part of the learning process...
Well, in Visual Studio 2010, I clicked New Website. @ C# language, ... The template it gives is pretty nice, it creates a database MDF file, and a login/register setup ready to go !...
You guys can see it live AT CLICK HERE ...
Everything is working, well at least here at the local machine...
There are 2 pages in there, Default.aspX, and About.aspx ... I want to allow ONLY logged in users to view those 2 pages... I tryed a few things, added my account to a role called ADMIN,
In the web.cong I changed Allow"*" to allow"ADMIN" ... still didn't work.. Also, I was trying to avoid using roles for now, and I was trying to find a way to do this for individual pages in the same directory as well... If possible with out touching the web.config file...
I want to display index.aspx instead of default.aspx in the root of folders in my ASP.NET app but can't figure out where to set this.
View 4 RepliesI am trying to implement URL rewriting technique in my Web application.I have found some articles on net 2 rewrite URL. But i m not able to understand. tell me any API or DLL which will take care of all url rewriting techniques in my Web applications.
I have heard something abt UrlRewriter.ddl . But i have not used it yet. provide me the easiest way to do that. If any sample application is there then it will be better ti understand
Here is my scenario.In default.aspx page user selects the country, state, city from drop down list, and store them in cache for further use. but when other user open the web site from other computer it shows the same country, state, and city selected by user 1. Is there any problem related to cache? I have stored data as following.
cache["ctryID"] = ctryID;
cache["stateID"]= stateID;
cache["cityID"]= cityID;
I want to show default country, state , city at page load of default.aspx
When I update a js file in my asp.net project, I refresh the browser and the change shows up as expected. If I change a css file or an .aspx file, the change does not show in the browser. Not when I clear the browser's cache, not when I restart IIS (iisrestart). What could this possibly be?
PS. I have tried chrome and firefox
I'm very new to .net and Visual studio. When u create a new website, a blank page default.aspx is displayed. Then u click on add new item & select master page. How to add this masterpage to default.aspx?
View 4 RepliesI was wondering if I can create a method or textbox in an .aspx page (such as 'Default.aspx') and from a different class (e.g 'MyClass.vb') insert values into the textbox?
View 6 RepliesHow can I hide the Default.aspx page from within a folder[URL] It does not show the /Default.aspx
but when validating any empty textbox then it shows as follow
[Code]....
First i had taken Default.aspx Page .after that i added master page to my project.Now i want to include this master page into default.aspx page I was mention master page attribute in Page directive of defult.aspx.
Now problem is i am not able to Get the attribute of <asp:contentplaceholder>.
I would like to create different folders in my .net project with following scheme;
+ students
- default.aspx
- query.aspx
+ teachers
- default.aspx
- pictures.aspx
- groupname.aspx
- default.aspx
- login.aspx
- getresult.aspx
and i would like to let it be reached as
[URL] (goes to the it's local default.aspx page, not default.aspx of at the root) [URL](goes to the it's local default.aspx page, not default.aspx of at the root) [URL] (goes to the root's default.aspx page) I hope i could tell my question understandable.
We made some changes to the default.aspx page our website, but those are not taking effect. If changes are made to pages in sub-folders it just works fine. Only that the default.aspx page is acting weird even though they are just changes to the markup.
View 4 RepliesI have created a web application. I have a page "Default.aspx" and some other page say"test.aspx". In test.aspx, I am setting some values in a collection object and then setting this object in session. I am not getting but somehow during execution of test.aspx, the default.aspx gets called where the session containing object gets reset. Its very important for me to know whey this default.aspx gets called even I am not making any call to it. I have other pages also like a.aspx,b.aspx, c.aspx, d.aspx and many more. All other pages work fine.
View 5 Repliesi added css and skin file path inside a usercontrol
if register this u.control to a aspx page
is css will apply to aspx page ? ,if i not apply any style sheept to aspx page
How is the color and background set for a Default.aspx form? My web looks 'dull' and needs color and stuff.
View 2 RepliesI was wondering if it is possible to find a control in a standard web form that is using a masterpage.
So for example I have two pages - default.aspx and information.aspx. Both these web forms have label controls (lblDefault and lblInfo respectively). This information is stored in a database along with the content that the label controls should be populated with. Instead of having to program a method to retrieve the content text from the database for the relevent controls on these two pages would it be possible to find the controls in the masterpage codebehind file - something like Page.Form.FindControl("lblDefault")? So for each webform using a masterpage a check is done to see if any of the controls should be populated with content from the database.