dGallery, a sexy asp.net mvc photo gallery

Posted in ASP.NET | MVC at Tuesday, 16 September 2014 10:49 GMT Daylight Time

dGallery, asp.net mvc5 photo gallery

check the demo

  • No database required
  • Quick, smart, keyboard based navigation
  • Sign in with your Twitter and Facebook account
  • Super-simple, super-fast
  • Full source code is included. Easy to extend and customize it to fit your needs.
  • EXIF reader.
  • It uses bootstrap. Just go to bootswatch and download a new theme or create your own. It is a simple drag and drop.

AddThis Social Bookmark Button

If you go to Build-> Publish Web Site menu on Visual Studio 2005, you will find this publishing screen:

If you UNCHECK the "Allow this precompiled site to be updatable", all the aspx pages within the projects will be generated empty. To be more exact, you will find the following unique line on them:

This is a marker file generated by the precompilation tool, and should not be deleted!

If you compare this screenshot:

with this one:

you will realize how the first was published allowing ASPX pages to be updated and the second not (notice how in second screenshot, all the ASPX files have 1kb file size)

Don't worry!, All HTML markup and inline code is compiled into assemblies on the bin folder, and it is correctly executed and rendered when the page is requested.

This way, nobody would be able to change either code or HTML content after the publishing is done!

AddThis Social Bookmark Button

ASP.NET MVC Validation of viewstate MAC failed error

Posted in MVC | ASP.NET | .NET 3.5 at Saturday, 13 December 2008 02:30 GMT Standard Time

If you get a Validation of viewstate MAC failed error on ASP.NET MVC, before trying to hard code your <machineKey attribute in web.config, disabling the keying of viewstate

<system.web>
  <pages enableViewStateMac="false" />
</system.web>

, or any other literature you may want to check if the page you are posting data from has two "<form" attributes (the one hard coded on the page and the one created with Html.BeginForm()). If you play with master templates and have to merge some MVC pages with tradicional ASP.NET you may get to that error.

It took me a while to find the solution...

Did this post save you some time? post it. I'm curious. :) thanks.

AddThis Social Bookmark Button