mvc

dismissing modalViewController all view move up by 20px

here i am using presentModalViewController and dismissModalViewController with animation set to "YES" in both cases. Which works fine. However, after the modal view is dismissed, all of the content on the main view has moved up what looks like 20px.Its effect all the viewcontroller. Any idea why did it happen and how to overcome it. ...

Merging two ASF files

I have an ASF file which contain 8 audios and 1 video. Now i want to merge this file with other of same ASF type. Is it possible to do with windows media SDK. My language is VC++ Please give some help ...

ASP.NET MVC Html.ActionLink Maintains Route Values

Hi, I have a question that has pretty much been asked here: http://stackoverflow.com/questions/780643/asp-net-mvc-html-actionlink-keeping-route-value-i-dont-want However, the final solution is a kludge, pure and simple and I really would like to understand why this happens, if someone can please explain it to me? For completeness, it...

MVC ActionLink generating NON-Restul URL AFTER adding constraints

Hello I have a custom route without constraints that generates a Restful URL with an ActionLink. Route - routes.MapRoute( "Blog", // Route name "Blog/{d}/{m}/{y}", // URL with parameters, new { controller = "Blog", action = "Retrieve" } Generates - http://localhost:2875/Blog/12/1/2010 From - <...

ASP.NET MVC 1: Model Binding With Disabled Textbox

I have a textbox that I am defining as <%= Html.TextBox("Username", Model.Form.Username, new { @class = "textbox", @disabled = "disabled" })%> In my action [AcceptVerbs(HttpVerbs.Post)] [ValidateAntiForgeryToken] public ActionResult EditLogin(LoginForm post) { ... return View(model); } pos...

jQuery MVC architecture

Hi, what is the best way to create MVC architecture in jQuery? Should I use jQuery.extend()? jQuery.extend({ View: function(){} }); ...or jQuery Plugin? (function($) { $.fn.model = function() { return this; }; })(jQuery); ...or just objects in JavaScript? var model = {} var view = {} var controller = {} Thank you! ...

ASP.NET MVC2 DataAnnotations not catching error

Can somebody help me to figure out why DataAnnotations will not work with my MVC2 project in VS 2008 SP1? Here's the situation.. I uninstalled VS2008 and MVC1, then reinstalled VS2008 SP1 and .NET 3.5 SP1 and MVC2. Now when I create a clean project as soon as it has to hit the DataAnnotations Dll (e.g. say when I go to Register.aspx i...

Passing sql results to views hard-codes views to database column names

I just realized that i may not be following best practices in regards to the MVC pattern. My issue is that my views "know" information about my database Here's my situation in psuedo code... My controller invokes a method from my model and passes it directly to the view view.records = tableGateway.getRecords() // gets array of record...

MVC without ORM is not real MVC?

at the moment im integrating ORM (doctrine) into a MVC framework (codeigniter). then it hit me that this was the obvious way of setting up a MVC: the controller calls the models that are representing database tables. look at this picture: MVC + ORM then i wondered, how can a MVC without ORM be real MVC? cause then the models are not...

Where should I define custom routes in my ZF 1.10 app?

With the new Zend_Application/Zend_Application_Bootstrap classes I'm confused as to where I should be applying my custom routes. For example, at the moment I have one route: protected function _initRouter() { $router = new Zend_Controller_Router_Rewrite; $route = new Zend_Controller_Router_Route('news/:id', array('contr...

Custom Model Validator for MVC

I am trying to write a customer validation with the goal of passing two values from the Event class to perform some validation logic and then add the error to the PURLValue property if it fails. I can't get it to work, am I using the the right approach, below, or is there a way to perform this at the class level and append the error to ...

pro/con of having single/multiple action per file in symfony?

been working with symfony for a while. most tutorials describe having multiple actions in a single php file. however, i find having 1 action per php file easier to maintain. what's the pro/con of both? is this purely a developer preference in code organisation? any performance impact on either approach? what's common practice for reaso...

PHP MVC Framework Structure

I am sorry about the amount of code here. I have tried to show enough for understanding while avoiding confusion (I hope). I have included a second copy of the code at Pastebin. (The code does execute without error/notice/warning.) I am currently creating a Content Management System while trying to implement the idea of Model View Co...

Action -methods vs public methods in PHP frameworks

There are plenty of PHP frameworks out there as many of you know, and I am interested in your thoughts on this: Zend Framework has so-called action controllers that must contain at least one action method, a method whose name ends in "Action". For example: public function indexAction() {} The word "Action" is important, without it you...

Parametrized Strategy Pattern

I have several Java classes which implement the strategy pattern. Each class has variable number parameters of different types: interface Strategy { public data execute(data); } class StrategyA implements Strategy { public data execute(data); } class StrategyB implements Strategy { public StrategyB(int paramA, int par...

learning OO with PHP

Hi there I've started to learn OO programming, but using the PHP language with the help of the "PHP 5 Objects, Patterns, and Practice" book. The thing is that I wish to learn to use into same time the CakePHP framework which make use a lot of the MVC pattern. Because I don't know much about OO and less about MVC I wish to understand the...

MVC model flow?

I am setting up an application using the MVC model and I have a query regrading the flow of information from the UI to the data model. What I need to do is place data from the UI in the model, what I have done is write a method in the view which collects the required data in an object and then passes it to the model. The model then takes...

Model View Controller + nib files

In objective c (iphone) are the nib files (xib) the View part of the MVC? When you set a property of an object in IB where is that actually stored in the xib file? ...

Why are ASP.Net MVC2 area controller actions callable without including the area in the url path?

I've just installed Visual Studio 2010 and have created a new MVC2 project so that I can learn about the changes and updates and have discovered an issue with areas that I'm not sure what to make of. I created a new EMPTY MVC2 project I right clicked the project and, from the context menu, added a new area called "Test" In the new test...

Correct implementation of MVC architecture

I read a lots of articles about MVC architecture, but I'm still confused. Which diagram is correct? Does even exist correct implementation of MVC architecture? Could I use diferent implementation of MVC architecture? Diagram 1 Diagram 2 Diagram 3 ...