Assume I want to generate an element similar to this in ASP.NET MVC 2:
<%= Html.TextBoxFor(p => p.FooBar)%>
Is there an overload or way I can get ASP.NET MVC 2 to only generate a name attribute and not an ID attribute?
I can have it generate a blank id with <%= Html.TextBoxFor(p => p.FooBar, new { id = "" })%>, but I would like to ...
I use an <Authorize> attribute in ASP.NET MVC to secure a controller. My page loads portions of its content via AJAX. Here's a problem I have with IE8, but not Firefox 3.6:
Sign in as user JohnDoe and navigate to http://www.example.com/AjaxPage. Everything works fine. AjaxPage is protected with the <Authorize> attribute.
Sign out, ...
I created a simple ASP.NET MVC version 1.0 application. I have a ProductController which has one action Index. In the view, I created a corresponding Index.aspx under Product subfolder.
Then I referenced the Spark dll and created Index.spark under the same Product view folder. The Application_Start looks like
protected void Applic...
Is it possible to pull photos from the Flickr API based on a search term? Not necessarily something from my profile, but from any public photo that matches the search term.
Or is the Flickr API only for pulling your own, or another authenticated users, photos?
Thanks!
...
Hi everybody!
I'm trying to implement this scenario using Unity and i can't figure out how this could be done:
the same web application (ASP.NET MVC) should be made accessible to more than one client (multi-tenant). The URL of the web site will differentiate the client (this i know how to get).
So getting the URL one could set the (l...
I have a grid-view having details of customers,now I want to print cheques for all customers of the grid with single click of button instead of clicking individual print button for each and every customer.I want to implement this in asp.net MVC 1.0.Please temme hw should i proceed for this..Is iTextSharp will do any help to me or there i...
What's up with this? The viewmodel variable is a bool with value true.
<%= Html.HiddenFor(m => m.TheBool) %>
<%= Html.Hidden("IsTimeExpanded",Model.TheBool) %>
<input type="hidden" value="<%=Model.TheBool%>" name="TheBool" id="TheBool">
Results in:
<input id="TheBool" name="TheBool" value="False" type="hidden">
<input id="TheBool" na...
While a record is edited,how should be the ID stored ? I could have a textbox with enabled false, but I don't like this approach.
In ASP.NET I used to have a property which has saved the value in viewstate(Actually a hidden field + encrypted value).
The only solution I found Is to use a hidden field. Is it save enough ?
Are there any...
Hi folks, currently I use [Authorize(Roles = ".....")] to secure my controller actions on my ASP.NET MVC 1 app, and this works fine. However, certain search views need to have buttons that route to these actions that need to be enabled/disabled based on the record selected on the search list, and also the security privs of the user logg...
I was thinking about writing universal HtmlHelper for jQuery autocomplete wire up for ASP.NET MVC and I would like to know first if something like that already exists.
Also do you think it even makes sense to write one because so far even by myself I had 4 different scenarios for which I had to customize it (data from the datastore is a...
I wonder how long will an ASP.NET (MVC) application run, when no new requests come in? Lets say I'm using an IOC Container ans have a Singleton Object serving to the clients. As far as I know it will serve different page requests. But how long will it live when no new request come in? Is there any timeout (maybe configured through IIS) t...
I have been reading about Command Query Responsibility Segregation (CQRS). I sort of wonder how would this work with ASP.NET MVC? I get the idea of CQRS conceptually it sounds nice and sure does introduce some complexities (event and messaging pattern) compared to the "normal/common" approach . Also the idea of CQRS sort of against the u...
problem:
On first full page request, my controller invokes an applicationServices Layer (Web Service Proxy to my business tier) in order to populate a collection of current services that is stored in my own controller base class property. This is then to be displayed within a view.
Everything within the context of that controller has ac...
I have the following code in html, I cannot get the Function call back of JSON get call. Down is the code in controller. Please Help
<script type="text/javascript">
$().ready(function() {
$("#CuitDespachante").typeWatch({ highlight: true, wait: 500, captureLength: -1, callback: finished });
});
function finished...
I've got a slightly different validation requirement than the usual "when save, validate!". The system can allow someone to update a bunch of times without being "bothered" with a validation listing UNTIL they say it's complete. I thought I might be able to pull a fast one and put the [HandleError] on the method of which this would fir...
Hello,
I have an ASP.NET MVC application that has one part where I dont really want to use the auto url feature. I have a significant number of OPTIONAL parameters that need to pass in. This is basically for a complex query form... and a parameter that is not in use (i.e. has the default value) should please not be part of the URL. I lo...
I'm a big fan of compilation errors. I find the a lot easier to fix than runtime bugs. I currently using the ASP.NET MVC framework and I find it has a lot of room for typos that the compiler won't catch.
For Example if I want to return the view Data from the Index action.
public ActionResult Index()
{
return View("Data");
}
can...
I am looking to generate some CSS files dynamically in my Content folder.
At the moment, this folder has an ignore route (routes.IgnoreRoute("Content/{*wildcard}");) and, I'd like that to remain, as I don't need/want most of my content folders to go into the MVC request lifecycle.
Example:
routes.MapRoute(
"DynamicCSS",
"Content/...
I'm making an IVR system for a project, and have decided on Twilio to handle the phone portion (making and receiving calls, sending and receiving SMS messages). This will surface a website with an IVR front-end, allowing users to navigate the site using their touch-tone phone.
I'm not making all the content browse-able over the phone, j...
Hi Guys
I'm trying to post a JavaScript data object with the following:
$.post(frm.attr("action"), data, function(res)
{
// do some stuff
}, "json");
where 'data' takes the structure of
data
- panelId
- siteId
- ConfiguredFactsheetId // this is an array of CheckBox ids that correspond to ConfiguredFactsheets
- 123
- 234...