page

C# Writing to the output stream

This code will always make my aspx page load twice. And this has nothing to do with AutoEventWireup. Response.Clear(); Response.ContentType = "application/pdf"; Response.AppendHeader("Content-Disposition", "inline;filename=data.pdf"); Response.BufferOutput = true; byte[] response = GetDocument(doclocation); Response.AddHeader("Content-L...

How to achieve dynamic page file names in ASP.NET?

I would like my website to create search-engine-optimized links for dynamic content (instead of locating data via the querystring). So: mysite/SomeModifiableNname.aspx instead of mysite/DynamicContent.aspx?entryID=2345. Aside from a smart 404 handler that redirects requests, or a custom mime-type handler in IIS, is there a good solut...

ASP.NET Page calls an additional aspx page after loading

To keep things simple, we have a few aspx pages... Page1.aspx - resets Session information. Page2.aspx - Search form with results and sets Session variables. Page3.aspx, Page4.aspx, Page5.aspx - require Session variables set on Page2.aspx What we're finding is that as Page2.aspx loads and setting the Session variables, Page1.aspx is ...

Paging with Oracle and sql server and generic paging method

I want to implement paging in a gridview or in an html table which I will fill using ajax. How should I write queries to support paging? For example if pagesize is 20 and when the user clicks page 3, rows between 41 and 60 must be shown on table. At first I can get all records and put them into cache but I think this is the wrong way. Be...

iText page wrapping- changes order of elements

I'm using iText to generate PDF reports - came across this issue, and worked up a simple example to illustrate it. I'm combining simple paragraphs, and images. The height of the images is such that 3 will fit on a PDF page, but when if text is on a page, only 2 images will fit. I create my iText PDF like so Document document = new ...

Going to a Random page PHP

I have a link that goes to http://example.com/random.php, code for random.php below. <?php srand ((double) microtime( )*1000000); $random_number = rand(1,100); header( "Location: http://example.com/test?page=$random_number" ) ; ?> Basically what I want it to do is link to a random page. It works initially, but after the first click i...

SharePoint: Back up single page.

Hi, I need to back up a sharepoint web page which containts web parts and other html tweaks. I would like to keep a back up of the page itself with the web parts in the appropriate places, is this possible? Right now I just opened SharePoint designer, opened my page and saved as to my hard drive. Is there another way? Is this a compl...

Is there a piece of public code available to create a page index using PHP?

I have a MySQL table holding lots of records that i want to give the user access to. I don't want to dump the entire table to the page so i need to break it up into 25 records at a time, so i need a page index. You have probably seen these on other pages, they kind of look like this at the base of the page: < 1 2 3 4 5 6 7 8 9 > For ex...

SimpleModal Problem in jQuery

Dear all, I am using simplemodal in jQuery. I used Ajax for displaying radio buttons. It should list the radio button and values, after the radio button click the page to be Redirected to page2. When I tested it on localhost everything was fine. But it doesn't redirect the page on the web server. Any change I should make? My code: ...

Is it possible to Serialize or Create a System.Web.UI.Page item?

I have a method that takes a System.Web.UI.Page as an input and returns some application specific details (what "type" of page it is, if certain items are in the query string, etc...). To run a unit test on this I was trying to create a System.Web.UI.Page item (in the code I am able to just send this.Page). First Attempt: Serialization...

Sharepoint 2007 - read custom page field from webpart

Hi, How do I programatically read a custom page field from within a webpart (from the page the webpart is on)? Thanks Jon ...

How do I reload a page without a POSTDATA warning in Javascript?

I want to reload a page using: window.location.reload(true); But I receive the POSTDATA warning because the refresh function want to resend previous POST form data. How can I refresh my page without this warning? UPDATED: I have no control of the project! I can't workaround the POST itself! ...

How to hook the DOM loaded event?

Hi, Can someone point me in the direction to hook the DOM loaded event? Basically, i want to display a loader while the dom is loading (I dont mean Ajax requests- the first time a user hits a page) ? Thanks all in advance ...

Read pdf uploadstream one page at a time with java

I am trying to read a pdf document in a j2ee application. For a webapplication I have to store pdf documents on disk. To make searching easy I want to make a reverse index of the text inside the document; if it is OCR. With the PDFbox library its possible to create a pdfDocument object wich contains an entire pdf file. However to pres...

Get MasterPage Hiddenfield Value From a User Class

Is there a way to get a value I am storing in a Master Page hidden field from a User Class which I created and placed in the App_Code folder of my ASP.Net 2.0 Application? Some examples would preferably in VB.Net is highly appreciated. Thanks. To give further details, assume the following: MasterPage.Master MasterPage.Master.vb MyPa...

Asp.net BasePage Properties using ViewState are cleared on Postback

Here are the basics of my setup: I have a BasePage class that inherits from System.Web.UI.Page. BasePage has two properties implemented such that their get/set does so from two different items in the ViewState collection (ex this.ViewState["Year"] from the BasePage). I have another class that then inherits from BasePage, lets call it ...

How to use dynamic master page in ASP.NET MVC RC 1.0

I don't know how to using dynamic master page in ASP.NET MVC RC 1.0. Please help! ...

rendering an aspx page in another one

In my web project's business object editor page, I'm sending a notification email to the administrator after an object insert or update. But instead of sending a plain text mail, i want to send the html output of another aspx page(Notification.aspx) i simply prepared for this purpose. First i thought, I can create an instance of Notific...

ASP.NET: Everything on a page, or break into controls?

When you're making a page that is visually broken down into specific regions, do you break those regions down into controls, or do you put everything on the page and in one code-behind? If regions are separated into controls, how do you facilitate communication among the controls? By communication I mean simply exchanging data on the s...

Self redirect an .Asp page and keep the same Request variables

Hello, Am trying to convert the content of a page to an Excel format, the problem is when I redirect the page I don't get my request variables so I found a solution that we should define a hiden variable for each request variable and then define the value after Get call. This is the code that am using now : <script language="Javascript...