mvc

ASP.net MVC - How to persist model over various views.

Situation: In some project management software written in asp.net I have a create project page (working fine). I need to add to this the ability to add tasks from a list of templates to this project pre-creation BUT the list of available tasks is dependent on some values sitting in the create form. My abstract solution is this: I h...

ASP.Net MVC jquery Modal Dialog select from list and refresh Parent

In my project, i want to show a list of something to user and after a row is selected by user, the parent form will refresh without losing last data entry. I've created a sample project, please download and run it. You will see my note in that. (Edit a one row in the MainTable form and click on the "Select Item From List Please..." lin...

Ruby App MVC framwork (not web)

Has anyone heard of a Ruby MVC framework for Apps/Scripts? When Rails appeared - it was a revolutionary tool because it brought MVC to the masses of web developers and for once forced them to use design patterns and conventions. I'm looking for something like that but for scripting mundane admin tasks that are to be ran from cron or by ...

jqgrid how to dynamically create columns

Hello, I am trying to implement a jquery in mvc, there are a couple of tutorials around on this, but I don't want the jquery to have the columns hard coded (or in fact anything to be hard coded - this is logic that should be in the controller. So... looking at the code below you will see a colNames:, and colModel: how can I write these ...

wxPython: How should I organize per-widget data in the controller?

I have a widget that displays a filesystem hierarchy for convenient browsing (basically a tree control and some associated toolbar buttons, such as "refresh"). Each of these widgets has a set of base directories for it to display (recursively). Assume that the user may instantiate as many of these widgets as they find convenient. Note th...

ASP MVC Dropdown

Please look at my code. I am trying to display some dynamic customers in the dropdown menu. And after selecting a customer button is pressed. Then products owned by the selected customer should be displayed in the textarea. But the problem is that after selecting a customer and pressing the button, nothing is displayed in the text area !...

Avoiding spaghetti code in ASP.NET MVC

Probably a stupid question, but here goes. In my view, I have the following code.... <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Learner.MvcApplication.ViewModels.PagerViewModel>" %><% for (int i = Model.StartPage; i <= Model.EndPage; i++) { %> <% =Html.Label(ViewData.Model.Controller + i.ToString())...

BDD Top-Down Approach

Hi guys, I'm new in BDD world and I've been in some difficult trying to get the best from top-down approach, strongly recommended by many people. Considering this what would you recommend as a good start point to specify controller's behaviors? I mean, what need to be tested in a CRUD controller scenario for example? Regards, Alex ...

Retrieve LoaderExceptions on a shared host without a dev environment?

An MVC 1.0 with a 3rd party assembly builds and loads fine on my dev machine (no big surprise). When I publish it to my shared hosting provider, a System.Reflection.ReflectionTypeLoadException gets thrown at the start. I understand the general nature of the problem. My question is: how can I get at the LoaderExceptions property w...

Where should calculation logic go in a Rails app?

Hi all, I have an app that models a House. The House has_many Rooms, Rooms has_many Lights and Small_appliances, etc. I also have a controller called Calculator that is how the app is accessed. Data is added to the house (and its rooms) using the Calculator controller. Then a report is generated, which is located at app/views/calculator...

ASP.NET MVC - Display Result of Serverside Process

I'm very new to MVC, and just building my first site, using NerdDinner as an example. I'm wondering what is the best approach to displaying the result of a server-side process. eg on a screen where a user is asked to change their password - if the change fails validation then error messages are displayed as per NerdDinner pattern using t...

asp.net MVC antiforgerytoken on exception RedirectToAction

hiya I have implimented the AnitforgeryToken with my asp.net MVC forms, and also added the attribute to my login procedure, however when the check failes i wish to redirect to my fraud action rather than an exception page. is this possible within the attribute ???? thanks ...

HtmlAgilityPack for getiing required html

Am using C# application to feed the broken HTML into HtmlAgilityPack and get the first 200 words with proper closing of HTMl tags...anyone kindly help me with sample code for using HtmlAgilityPack to get the proper html content. ...

Asp.net MVC Ajax.ActionLink send ViewData.Model to the Action with last User inputs

I want to send ViewData.model to Special action with the last user data entry. I mean, the Edit form is showed to the User, User input values to some fields, when he/she will click on the Ajax.ActionLink, I am supposed to get my Model with the last modified in the action. I am sending ViewData.Model to the Action with the below code, b...

ASP.NET MVC "thickbox" Modal Dialog and selectList form

User has to input a field by selecting a row from a list. I can show a list in Modal Dialog with "thickbox". something like this. <%= Ajax.ActionLink("Please Select From List...", "ShowItemsList", "MyController",ViewData.Model, new AjaxOptions { InsertionMode = InsertionMode.Replace }, new { @class = "thickbox" })%> But i do not k...

Multi-Tier in PHP..the right way??

I have a specific question, that could use a general answer... When building Multi-Tier applications in PHP, does everything have to be done in the Business Logic layer, or can any layer do work... Example, Lets say I'm building an application that shows user information (from the database) on the presentation layer. Should I use the bus...

Creating a file upload template in Doctrine ORM

Hey all. I'm using Doctrine 1.2 as my ORM for a Zend Framework Project. I have defined the following Model for a File. File: columns: id: primary: true type: integer(4) unsigned: true code: type: string(255) unique: true notblank: true p...

How to learn programming for Web Development using microsoft technologies

i am programmer but not good i am working with c# , asp.net and MVC too. so how i can improve our coding skill for develop a better web apps. means how can i learn it. ...

MVC related question

Hi there let's consider a web application built using MVC concept. If my application generates some chart images dynamically based on the user input and a database I wish to know which component the image generation process will belong to: controller or view? It's controllers job to generate the image and the view component to display ...

Fluent nHibernate keeps recreating my database, why?

Hi, I'm trying to convert my data layer from Linq2Sql to nHibernate. I think Xml the configuration in nHibernate is pretty backwards so I'm using Fluent. I've managed to get fluent, add in a repository pattern and unit of work pattern, and my unit tests are looking good. However now as I'm plugging it into my services layer I'm noticin...