Tuesday, August 31, 2010

Code hook before EntityManager is initialized in JBoss AS 6

Programmer Question

Hi *,



I'm looking for a callback facility that allows me to execute some code before an EntityManager is started in JBoss 6.



More specifically, I would like to process a Liquibase changelog, before the EntityManager is initialized.



Any hints greatly appreciated!
J.



Find the answer here

ASP.NET MVC HTML helper methods for new HTML5 input types

Programmer Question

HTML5 appears to support a new range of input fields for things such as:




  • Numbers

  • Email addresses

  • Colors

  • URLs

  • Numeric range (via a slider)

  • Dates

  • Search boxes



Has anyone implemented HtmlHelper extension methods for ASP.NET MVC that generates these yet? It's possible to do this using an overload that accepts htmlAttributes, such as:



Html.TextBoxFor(model => model.Foo, new { type="number", min="0", max="100" })


But that's not as nice (or typesafe) as:



Html.NumericInputFor(model => model.Foo, min:0, max:100)


Find the answer here

CSS Main Body does not stretch to page?

Programmer Question

I am beating my head against a wall trying to figure out why the code I have written for a particular site doesn't quite work.



The main body of my pages (the white area in link below) should be stretching from navigation to the footer but only does so on certain pages.



The footer is automatically placed at the bottom of every page regardless of height (i.e. will be at page bottom on a 400px height page).



Is it possible I am just missing something very basic?



I have posted a link to the dev version of the site at:



www.contendertest.com



The pages I am having trouble with are index and the 'enroll' link.



Find the answer here

LinkWithin

Related Posts with Thumbnails