Author: Peter

MVC

simple ajax controller (for countries etc) ajax (these are research notes) consuming WebApi with MVC consuming WebApi with MVC Dynamic content in MVC/Razor the following contains xml entries to get past razor runtime compilation errors of namespace not found: @Html.LabelFor(model => model.path.Value, “Path”) @Html.DropDownList(“Path”, new List { new SelectListItem { Text = TypeSafeEnum.a.Value, Value = TypeSafeEnum.a.Value }, new SelectListItem {… Read more →

Text enums with the Entity Framework / Code First in C#

One of the projects I am working on requires enumerated values be text and not numeric. maritalStatus = ‘Single’ instead of maritalStatus = 1 Below is an example. All of the code is generated using TextTemplates. The enums are referenced in the POCOs like so: [XmlElement(ElementName=”maritalStatus”)] public MaritalStatus maritalStatus { get; set; } //Enum values are flattened in the xml… Read more →

backing up wordpress

Ignore the original post as it doesn’t seem to work on a Windows host. BackupWordPress works fine … http://wordpress.org/extend/plugins/backupwordpress/   backing up wordpress Backing up your WordPress install / Adding a WordPress Backup plugin Using the left side menu, hover over plugins, then click add new. Using the search function, search for “WordPress SQL Backup“ You should now see your… Read more →