Friday, May 27, 2011

Freelance Web Developer Bubble


JPR Freelance have now purchased a new vehicle for advertising use!

Known in the office as the JPR Freelance 'bubble', the Fiat 500 is fully badged up to catch people's eye when travelling the streets of Tyneside and beyond!

Wednesday, May 18, 2011

From Freelance Web Developer's Office To Film Set!

Yesterday saw the arrival of a German film company to JPR Freelance offices in North Shields, near Newcastle upon Tyne. The company have converted the JPR Freelance offices to a bakery and an internet cafe!

Watching the crew work was most interesting, it is quite amazing how a block of offices can be converted in a day to look completely different. Just look at the photos of the set!





Monday, May 2, 2011

Passing Selected HTML.Dropdownlist through actionlink in MVC

I spent a bit of time today figuring out how to pass a selected value from an html dropdown list into an MVC actionlink so thought I would write a post on my findings.

OK, I have a category list on my page as follows:

<%:Html.DropDownList("Categories") %>

...and an actionlink link as follows:

<%: Html.ActionLink("Edit", "MaintainCategory", "CMS", new { ID = 0 }, new { id = "editlink" })%>

...I want the ID passed to be the value selected in the dropdown box.

The easiest way I found was to add the above JQuery / Javascript to the page:

<script type="text/javascript">

$(function () {
$('#Categories').change(function () {
var value = this.value; // get the selected value
//modify the href link
value = '/CMS/MaintainCategory/' + value;
$('#editlink').attr('href', value);

});
});