web-development

Does having to many background-image in css affect perfomance?

Some users are reporting that my site is too slow And i think background images in css might be a possible culprit I have a site that uses a custom build system to concatenate all css, compress them ( yui compressor ) , make css sprites automatically ( smartsprites ) and I end up with a 9kb CSS for the whole page, this includes all cs...

How do you handle all the ways you could dispatch from a HTTP POST?

Imagine a user has just posted data to your web application and you want to re-display the current page with a message about their success or failure. This gets complicated. If the data is valid and the user is expecting html, you want to issue a redirect so that refreshing doesn't cause them to re-post. You want to redirect to the re...

Recovery from page refresh in Web Applications?

Is there a standard or accepted way to recover from a page refresh in an Ajax web application? My interest now lies mainly in a web app with a Java (JSP/Servlet) Back end. My page is initially rendered from a JSP and then the user progressed through the interface using javascript events. Is there a design pattern which covers this, I'm...

Fetching an image and associated metadata with an AJAX request

I have a somewhat expensive server-side operation that produces an image and some associated text metadata about that image. My web page will display both. The image and its data are fetched with AJAX calls. On the server side, it is possible to produce the image and the metadata at the same time. How can I transfer (and display) both t...

What's the best development platform for a social networking website?

Before everyone groans and says: "What another one?" This is (initially at least) a private one with about 100 users very bespoked to our needs. Are there any existing application frameworks that can be used and easily reshaped into our requirements or if not, what's the best choice of tech for each tier? ...

What is a standard warranty period for software development?

How long do you warranty your software against bugs, defects, or security issues after final acceptance by the client? I've used a 90 day window for our web development projects in the past, after which it becomes a time and materials billing scenario. I'm curious what others are doing. ...

How to suppress the file corrupt warning at excel download?

I have a web page which links to an excel 2007 worksheet. It is a .xls file and not .xlsx file. When I click on the link I get the usual dialog box to either open/save the excel file. On clicking 'Open', I get the following warning message- The file you are trying to open, 'filename.xls' is in a different format than specified by...

Using relative URL in CSS file, what location is it relative to?

When defining something like a background image URL in a CSS file, when using a relative URL, where is it relative to? For example: /stylesheets/base-styles.css: div#header { background-image: url(images/header-background.jpg); } If I include this style-sheet into different documents via <link ... /> will the relative URL in t...

How to construct a web file browser?

Goal: simple browser app, for navigating files on a web server, in a tree view. Background: Building a web site as a learning experience, w/ Apache, mod_python, Python code. (No mod_wsgi yet.) What tools should I learn to write the browser tree? I see JavaScript, Ajax, neither of which I know. Learn them? Grab a JS example from t...

Why a simple <% Eval() %> will work in IE and Chrome and not in Firefox?

The code below: <asp:HyperLink ID="Image1_Link" runat="server" Text='<% "< img src=" + PhotoGalleryBaseUrl + Eval("image_file_name") + ">" %>'> </asp:HyperLink> Image Size: <asp:Label ID="image_sizeLabel" runat="server" Text='<%# Eval("image_size") %>'> </asp:Label><br /> Renders like this in Chrome and IE: And renders like this i...

Virtual Earth VEShapeLayer Will Not Render

The goal: Allow user to turn on and off different layers of data; and to dynamically pull the data for the current extent from a database on map move event. This works fine and good if you hard code your VEShapeLayers as done here. My list of layers is coming from a database, I have everything working the way I want except that when I ...

Joining multiple event handlers in Javascript.

How to join multiple event handlers in Javascript as in the following scenario : onClick="doSomething();" onKeyUp="doSomething();" onLoad="doSomething();" ...

Lazy loading the addthis script? (or lazy loading external js content dependent on already fired events)

I want to have the addthis widget available for my users, but I want to lazy load it so that my page loads as quickly as possible. However, after trying it via a script tag and then via my lazy loading method, it appears to only work via the script tag. In the obfuscated code, I see something that looks like it's dependent on the DOMCont...

REST API error return good practices

I'm looking for guidance on good practices when it comes to return errors from a REST API. I'm working on a new API so I can take it any direction right now. My content type is XML at the moment, but I plan to support JSON in future. I am now adding some error cases, like for instance a client attempts to add a new resource but has exce...

JavaScript code to Class Diagram

Hi, I am looking for a tool that can generate class diagram from JavaScript code. Similar to the ones for C++ and Java. Is there any? Thanks ...

Displaying array data in horizontal manner using php and smarty

Suggest me a better way to do it. I would like to show the array result in the horizontal manner. Column1 | Column 2 | Column 3 3 | 7 | 10 now it shows in vertical manner as follows Column1 | Column 2 | Column 3 3 7 10 Array Result : Stored in $result variable and assigned in ...

getting a webresponse stream into iframe - trouble

hey again stackoverflowers I'm migrating a website from old ASP (in VBScript) and there's certain stuuf I have to iFrame as to keep the old stuff working inside a new container. on the aspx page I have an iFrame with the runat="server" attribute to make it available in the code behind file. <iframe id="frmLoader" runat="server" scrol...

Open Source .Net Authentication Libraries?

I'm building a website and I'd like to avoid using asp.net membership. I want to consider some alternatives before I decide to write this code from scratch. Are there any open source projects that tackle the authentication problem? note: I need user/pass auth (can't use Open Id). ...

iframed ASP actions trouble

This is actually a follow up on my previous question (link) I've created the HttpHandler and it works fine for now, I'll add flexibility by using the querystring and session to point the post I'm making in the right direction. The next question is as follows. Now that I have the old page iframed as it should be, there's still the trou...

Framework for doing (Igoogle/Pageflakes/netvibes)-like application using Ruby on Rails

Anyone has any suggestions of a framework to help me create an Igoogle/pageflakes/netvibes like application using ruby on rails. I tried using apotomo for a few days, but couldn't make it work at all. If not possible to make using ruby on rails, do u have any suggestions on what to use? Thanks, ...