Compressing ASPX Pageview In Code Or Compress HTTP In IIS?

Dec 30, 2010

In the past, with pages with large viewstate I have overridden the PageStatePersister class so when the state is saved I compress it. On Load I decompress it. I have haven't really thought about it, but could IIS handle something like this better? The reason I did this was to keep my pages slimmer because I have a lot of custom controls on the page and the viewstate was huge. This is where I got my original code from:[URL]

View 1 Replies


Similar Messages:

C# - Stretch A PageView To Fit The Height Of A RadWindow?

Feb 21, 2011

I have a RadPageView which I use with a RadMultiPage and RadTabStrip inside of a RadWindow. The problem is that my RadPageView does not stretch to fill the RadWindow. I set the Height and Width to 100%, and for the Width it works fine... (when I resize the window, the PageView is also resized). However, the height of the PageView only stretches down to the height of the controls that it contains. I spent a lot of time playing with the properties trying to get this to work... Is there an easy way to achieve this? Or do I have to handle client side OnResize events... It works for the width though.. shouldn't it be easy to also work for the height?

View 1 Replies

PageView Duplication Inside A Multipage

Jan 23, 2012

I have a web page containing a multipage and 3 pageviews filled with controls... linked to VB server side code.All I want to do, and I imagine it's pretty simple intuitively, is to grab all the controls from one of the 3 pageviews and add it to the multipage.

Now I have 4 pageviews. The 4th one being a copy of either pageview 1, 2 or 3.I looked everywhere and I understand I need to deep copy the PageView and stick it to the Multipage, as I already do for a blank PageView, but I am missing the rest.

View 8 Replies

C# - Compressing Parameters In The URL?

Jan 13, 2010

The urls on my site can become very long, and its my understanding that urls are transmisted with the http requests. So the idea came to compress the string in the url.From my searching on the internet, i found suggestions on using short urls and then link that one to the long url. Id prefere to not use this soltuion because1) I would have to do a extra database check to convert between long and short url.

That leaves in my head 2 options1) Hashing, i dont think this is a option. If you want a safe hashing algorithim, its going to be long.2) Compressing the url string, basicly having the server depress the string when when it gets the url parameters.3) Changing the url so its not descriptive, this is bad because it would make development harder for me ( This is a 1 man project ).Considering the vast amount posible amount of OS / browsers out there, i figured id as if anyone else has tried this or have some clever suggestions.If it mathers the url parameters can reach 100+ chars.Example: mysite.com/Reports/Ability.aspx?PlayerID=7737&GuildID=132&AbilityID=1140&EventID=1609&EncounterID=-1&ServerID=17&IsPlayer=True

EDIT:Let me clarify atm this is NOT breaking the site. Its more about me learning to find a good solution ( Im well aware this is micro optimisation, my site is very fast atm ) and making my site even faster ( To challage myself, and become a better coder ).There is also a cosmetic issue, i personaly think that a URL longer then the address bar looks bad.

View 8 Replies

Web Forms :: Compressing Of Pics?

Nov 26, 2010

i m using photo gallery in a website but pics takes much time to be view than any other sites like facebook or orkut. hw can i overcome this problem. i m resizing the image on file upload btn. you can check the url www.sanskarbhartipublicschool.com/photogallery

View 1 Replies

Web Forms :: Gzip Compressing?

Jan 25, 2010

How I Can Underestand That My WebSite Uses Gzip Compressing?[URL]

View 1 Replies

C# - When Is It Worth Compressing The ViewState

Nov 16, 2010

I agree that the best way to shorten the ViewState is to disable it on the ASP.Net controls that don't need it. Keeping it small from the beginning is a great habit.I have also heard that it is already compressed (although can be true... there are ways of compressing it even more, has described in this Stack Overflow question).

My question here is not if it should be compressed... is: when should ViewState be compressed?If we have a ViewState of 410 characters it will weight 410 bytes in a page, while a ViewState of 13.843 characters equals 13.5 KB.13.5KB is a considerable weight already. And if I compress a CSS file that height 10KB, I think it is also worthy compressing a ViewState of 13.5KB, even if that means a little extra "thinking" on the server.But is 410 bytes of ViewState worth the extra processing on the server?

View 2 Replies

VS 2005 / Compressing JPEG Image?

Nov 18, 2011

I need to write a routine which uploads a largish (2-4 meg) jpg photo and shrink it down to a small size. Adobe image ready does what I need but I need to develop it in my web application. Basically I need to reduce the image file size so it is web friendly.

View 9 Replies

How To Catch Non-aspx Files With A Http Module

Sep 21, 2010

If I make a http module it only catches .aspx files. Files with other extensions (.js, .htm) are ignored.

Does this have anything to do with IIS?

Strangely enough all extensions are caught on the ASP.net Web Development Server but not when hosted in IIS.

View 1 Replies

Web Forms :: Access Code In App_code From Aspx (not Aspx.cs)

Jul 2, 2010

I put common code in the app_code directory. I access classes in the code all the time from aspx.cs files by "using" the name space from the C# file in app_code and then referencing the class. Now I want to access a class from an app_code file a aspx file. How do I do this?

View 8 Replies

Changing The View (.aspx) From The Code-behind (.aspx.cs) Class?

Nov 1, 2010

I have a 'classic' ASP.NET app (.NET 3.5) with a pretty standard runat="server" style form with server-side controls and an 'Execute' asp:button. In the code-behind, the executeButton_click handler processes some of the other controls, runs a report, and drops the result into an asp:label. So the effect of pressing the Execute button is that the entire page reloads with the report inserted into the label.

I need to change this so that when the Execute button is pressed, the report pops up in a new window with a different layout (ie without the controls and form). If I was doing this in an MVC framework I would just change the view template in the 'execute' action, so the analogue for ASP.NET would be change the code in front, ie the .aspx file that gets used, from the code-behind class.

Is this possible? I know the link between the .aspx and the .aspx.cs isn't extremely tight as it is possible to reuse a code-behind class in multiple .aspx files. So can I set the .aspx file to render from the code-behind?

View 2 Replies

Display Aspx And Aspx.cs Code Onto A Page Without The Browser?

May 29, 2010

i have to give the user the option to upload his own aspx and aspx.cs files on to the server, adjust the hyperlink to point to a page which would do the following display the aspx and aspx.cs files code onto the page without actually rendering the code the browser should not understand anything, and while reading the files to display them the method be such that nothing is processed on the server regarding the code within the files to prevent from unnecessary problems many user would try to cause.

i have tried many ways of displaying it but it ends up on displaying the actual comments instead of the code. how to achieve the above. note main concentration is on asp.net and c# using vs08, so j script and ready-made tools be avoided if feasible

View 2 Replies

Aspx Page Giving 404 On HTTPS While Working Fine On HTTP

Mar 17, 2011

Other pages (aspx) are working fine on both http/https, only ashx gives response 404 on https, I used firefox firebug to investigate it.

I have two same virtual directory on IIS, one is mapped for https where this ashx is not working.

I guess some kind of mapping is missing for https on server, not sure where this kind of mapping is stored?

View 1 Replies

Is It Possible To Call Aspx Page Via HTTP Endpoint In SQL Server 2008/2005

Nov 22, 2010

Is it possible to call (Post to) a Method in a ASPX (Code behind) page via HTTP endpoint in Sql server 2008/2005.

View 1 Replies

Web Forms :: Uploaded Http://www.mymrt.net/trigASP3/cos.aspx And The File Cant Be Found?

Aug 7, 2010

I uploaded http://www.mymrt.net/trigASP3/cos.aspx and the file cant be found. I have an asp.net website in VS2008.In the app_code folder I have class files.It all works fine no problem on my PC so there is no issue on my PC.I uploaded the whole website to my host and I get a file not found due to the code behind using a class fileI take away the class file refernce from the code behind and it works.

View 6 Replies

DataSource Controls :: Binding An ObjectDataSource To A Property In Aspx Code, Not Code-behind

Dec 3, 2010

I want to bind an ObjectDataSource to a property in my asp page and I want to do it in the page's aspx code, not in code-behind. I've already done it in code-behind, as follows:

[Code]....

I'd prefer to get rid of the ugly code-behind and just do this in mark-up. Something like
[Code]....

This gives me a run-time error: Cannot create an object of type 'System.Object' from its string representation 'SelectedBook' for the 'DataSource' property.Is there a way of doing this declaratively and not in code-behind? Further, what if what I want is to actually use a child property of the property in question? For example, if my Book object has a ReaderComments collection, can I databind to it decaratively in the aspx mark-up?

View 1 Replies

Http Status Code 401 - Customerrors For 401.2

Jan 13, 2010

I successfully implemented role based authorization in ASP.NET. When a person does not have the needed role he gets to see an error page for 401.2 not authorized.

What I would like to accomplish now is to have a custom 401 page in my application and have it redirected there via settings in the web.config. I tried this:

<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="401" redirect="NoAccess.htm" />
</customErrors>

But this does not get caught. Do I have to override it in IIS instead? I hope not as that would make getting things deployed harder.

View 1 Replies

Making Http Request From Code Behind

Mar 3, 2011

I am trying to implement Message API

I am not sure how I will be calling this from code-behind and in their snippet it says:

https://platform.3cinteractive.com/api/send_message.php

POST
username=aRDSe3vcaMzh06YrMcxcQw==&password=1BSvQc6lpNlnp4ufWgRLPHNJ7RMrL8CcaWCzL1Vtw+Y=&phone_number=+11234567890&trigger_id=1105&message=howdy

View 2 Replies

.net - Get Description For HTTP Status Code?

Aug 22, 2010

In ASP.NET you can set the Response.StatusCode to for example 404. Should the status line / description always be set? (to in this case "404 Page Not Found")

How do you get the description if you only have the code (404)? Is this somewhere in the framework or do you manually have to hardcode the descriptions?

View 3 Replies

Web Forms :: Inserting C # Code Within The HTML-code. Aspx?

Jan 13, 2010

I can't write in english well, but I must try to have an answer for my problem.I have a problem that I have not found a solution, regarding the integration of C # code in the HTML code .aspxI want to do a loop on the

<ajaxToolkit:TabPanel of <ajaxToolkit:TabContainer to have several tabs by a few existing data in a DB table.

Here is a moceau of my code:

[Code]....

This code gave me this error:

Message d'erreur de l'analyseur: 'TabPanel_<%= idMagasin %>' n'est pas un identificateur valide.Translation: Message parser error: 'TabPanel_ <% = idMagasin%>' is not a valid identifier.I removed idmagasin like this:

[Code]....

System.ArgumentException: Une entrée avec la même clé existe déjà .

Translation:
System.ArgumentException: An entry with the same key already existsThe result is that I found a great problem to insert a C # code in the HTML code .aspx unlike others languages like PHP.

View 1 Replies

Jquery - Http Post To Code Behind In Asp.net Webforms?

Jan 12, 2010

How can I call a method in the code behind from a jQuery post in asp.net webforms?

In MVC it's simple, I just do this:

$.post("/MyController/MyMethod", { data: somedata; }, function(result) { alert(result); });

but I can't figure how what to put for the first parameter if I wanted to call a method in the code behind in webforms... for example, if I have a method called doSomething() is there a way to stick some location in there so that it will call doSomething() and return data to the callback?

View 1 Replies

Compress A File Using Zip Instead Of Gz?

May 31, 2010

I have to let the user downloads a big text file.. By now I'm compressing the file with ".gz" (GZipStream)... And then the user can unzip in his machine.. But some users can't decompress the .gz extension.. And I wonder if there is any way to compress using zip..

View 2 Replies

AJAX :: Web Site Hangs And Gives Http Status Code 413?

Nov 11, 2010

have a web application hosted on Windows Server 2003 SP2 with IIS 6. I use ASP.net Web Forms and ASP.net AJAX.Some times, when clicking on a button to perform an action the web application does bot respond to the user.After debugging i have found that ErrorSys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 413

View 3 Replies

Code To Output A Specific HTTP Header E.g. X-adexpert-id?

Sep 10, 2010

What is the code to output a specific HTTP header e.g. x-adexpert-id

View 2 Replies

C# - How To Remove Or Compress Viewstate

Jan 17, 2011

Just spent a lot of time exorcising asp.net's large (but understandably useful) viewstate from an app, and i think it's worth sharing how it's done.

View 8 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved