<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet</id>
  <title type="text">Liverpool Users of .Net Google Group</title>
  <subtitle type="text">
  Liverpool .net user group
  </subtitle>
  <link href="/group/liverpoolusersofdotnet/feed/atom_v1_0_msgs.xml" rel="self" title="Liverpool Users of .Net feed"/>
  <updated>2009-09-15T11:11:06Z</updated>
  <generator uri="http://groups.google.co.uk" version="1.99">Google Groups</generator>
  <entry>
  <author>
  <name>Thom Shannon</name>
  <email>t...@glow-internet.com</email>
  </author>
  <updated>2009-09-15T11:11:06Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/410dca4f98f20667?show_docid=410dca4f98f20667</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/410dca4f98f20667?show_docid=410dca4f98f20667"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  It&#39;s a &amp;quot;switch user&amp;quot; for admin. &lt;br&gt; &lt;p&gt;It&#39;s working ok now, like so... &lt;br&gt; &lt;p&gt;using (Html.BeginForm(&amp;quot;ChangeClient&amp;quot; , &amp;quot;Admin&amp;quot;, FormMethod.Post, new { id &lt;br&gt; = &amp;quot;ChangeUser&amp;quot; })) &lt;br&gt; &lt;p&gt;{ %&amp;gt; &lt;br&gt; &lt;p&gt; &amp;lt;%= Html.DropDownList(&amp;quot;clientid&amp;quot;, (from c in new &lt;br&gt; DataDataContext().Clients orderby c.Name select new SelectListItem() {
  </summary>
  </entry>
  <entry>
  <author>
  <name>Donovan Hide</name>
  <email>donovanh...@gmail.com</email>
  </author>
  <updated>2009-09-15T10:57:09Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/365bbc8fa9a1e075?show_docid=365bbc8fa9a1e075</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/365bbc8fa9a1e075?show_docid=365bbc8fa9a1e075"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  Ahh, session state, another ASP.NET legacy! It doesn&#39;t translate well &lt;br&gt; to MVC. Current page can be determined by your url, or current action. &lt;br&gt; Might be worth looking at filters if you need something to be run &lt;br&gt; before every single action. Create a BaseController and define your &lt;br&gt; filters in there. &lt;br&gt; &lt;p&gt;Are you doing a search form that will be on every single page of a site?
  </summary>
  </entry>
  <entry>
  <author>
  <name>Thom Shannon</name>
  <email>t...@glow-internet.com</email>
  </author>
  <updated>2009-09-15T10:43:41Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/f16294ff42a48002?show_docid=f16294ff42a48002</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/f16294ff42a48002?show_docid=f16294ff42a48002"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  but how do I get the current page into tempdata in the first place? I&#39;d &lt;br&gt; have to put it in there during the execution of every single action, &lt;br&gt; plus it&#39;s session scoped so if the user has more than one page open &lt;br&gt; they&#39;ll get redirected back to the last action executed rather than the &lt;br&gt; one they just came from.
  </summary>
  </entry>
  <entry>
  <author>
  <name>Donovan Hide</name>
  <email>donovanh...@gmail.com</email>
  </author>
  <updated>2009-09-15T10:39:25Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/5e31759aacaaface?show_docid=5e31759aacaaface</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/5e31759aacaaface?show_docid=5e31759aacaaface"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  This chap just uses some lambdas and model mapping with &lt;br&gt; RedirectToAction to pass his state around actions: &lt;br&gt; &lt;p&gt;&lt;a target=&quot;_blank&quot; rel=nofollow href=&quot;http://jonkruger.com/blog/2009/04/06/aspnet-mvc-pass-parameters-when-redirecting-from-one-action-to-another/&quot;&gt;[link]&lt;/a&gt; &lt;br&gt; &lt;p&gt;Kind of depends how you&#39;ve set up your models really. &lt;br&gt; &lt;p&gt;2009/9/15 Thom Shannon &amp;lt;t...@glow-internet.com&amp;gt;:
  </summary>
  </entry>
  <entry>
  <author>
  <name>Michael James</name>
  <email>m...@mjjames.co.uk</email>
  </author>
  <updated>2009-09-15T10:38:48Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/9c1bbef0092edcdb?show_docid=9c1bbef0092edcdb</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/9c1bbef0092edcdb?show_docid=9c1bbef0092edcdb"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  Personally I think the hidden input is more of a hack, tempdata is &lt;br&gt; provided by the framework to temporarily hold stuff whilst you perform &lt;br&gt; some logic, this sounds ideal for what you want to do. That way you &lt;br&gt; know there&#39;s no tampering. &lt;br&gt; &lt;p&gt;Just my thoughts anyway. &lt;br&gt; &lt;p&gt;-- &lt;br&gt; Regards, &lt;br&gt; &lt;p&gt;Michael James
  </summary>
  </entry>
  <entry>
  <author>
  <name>Thom Shannon</name>
  <email>t...@glow-internet.com</email>
  </author>
  <updated>2009-09-15T10:34:56Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/63f1c900491b9fb9?show_docid=63f1c900491b9fb9</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/63f1c900491b9fb9?show_docid=63f1c900491b9fb9"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  I&#39;ve used TempData a couple of times, it looks like a bit of a hack &lt;br&gt; really. I think I&#39;ll go with the hidden input option. &lt;br&gt; &lt;p&gt;-- &lt;br&gt; * Want to become an expert Digital Marketer? &lt;br&gt; &lt;a target=&quot;_blank&quot; rel=nofollow href=&quot;http://www.glow-internet.com/bootcamp&quot;&gt;[link]&lt;/a&gt; &amp;lt;&lt;a target=&quot;_blank&quot; rel=nofollow href=&quot;http://www.glow-internet.com/bootcamp&quot;&gt;[link]&lt;/a&gt;&amp;gt; &lt;br&gt; &lt;p&gt;Glow New Media &lt;br&gt; t: 0151 707 9770 &lt;br&gt; m: 07730 987 574
  </summary>
  </entry>
  <entry>
  <author>
  <name>Donovan Hide</name>
  <email>donovanh...@gmail.com</email>
  </author>
  <updated>2009-09-15T10:30:00Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/93af1ebbefd0d156?show_docid=93af1ebbefd0d156</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/93af1ebbefd0d156?show_docid=93af1ebbefd0d156"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  &lt;a target=&quot;_blank&quot; rel=nofollow href=&quot;http://stackoverflow.com/questions/1936/how-to-redirecttoaction-in-asp-net-mvc-without-losing-request-data&quot;&gt;[link]&lt;/a&gt; &lt;br&gt; &lt;p&gt;TempData is your friend! &lt;br&gt; &lt;p&gt;2009/9/15 Derek Fowler &amp;lt;dezfow...@gmail.com&amp;gt;:
  </summary>
  </entry>
  <entry>
  <author>
  <name>Derek Fowler</name>
  <email>dezfow...@gmail.com</email>
  </author>
  <updated>2009-09-15T10:26:08Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/9f26021fb05e224a?show_docid=9f26021fb05e224a</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/9f26021fb05e224a?show_docid=9f26021fb05e224a"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  I dunno what the &amp;quot;right&amp;quot; answer is but could your controller inherit from a &lt;br&gt; common controller that provides the action method for your partial? You&#39;d &lt;br&gt; have to record what the current action was so you could redirect back to &lt;br&gt; that action when your partial one is done. &lt;br&gt; &lt;p&gt;2009/9/15 Thom Shannon &amp;lt;t...@glow-internet.com&amp;gt;
  </summary>
  </entry>
  <entry>
  <author>
  <name>Thom Shannon</name>
  <email>t...@glow-internet.com</email>
  </author>
  <updated>2009-09-15T10:20:21Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/4774e8948d7330d6?show_docid=4774e8948d7330d6</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/4774e8948d7330d6?show_docid=4774e8948d7330d6"/>
  <title type="text">Re: MVC</title>
  <summary type="html" xml:space="preserve">
  Another question for you all. &lt;br&gt; I have a partial view and I want it to perform a simple action on the &lt;br&gt; server, but return the user to the current page. Do I have to post to &lt;br&gt; another action and then get it to redirect back to that page? What&#39;s the &lt;br&gt; right way to do that redirect while preserving all the parameters etc?
  </summary>
  </entry>
  <entry>
  <author>
  <name>Adam Cooper</name>
  <email>a...@myogenic.co.uk</email>
  </author>
  <updated>2009-09-14T20:13:43Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/cf0eabbd38ab9eb6?show_docid=cf0eabbd38ab9eb6</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/cf0eabbd38ab9eb6?show_docid=cf0eabbd38ab9eb6"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  You could also have two forms with different Ajax.ActionLinks &lt;br&gt; specified and then return a partial with search results from each one. &lt;br&gt; To be honest I found the transition to mvc a bit painful, but like &lt;br&gt; others have said well worth it once you can break out of the old &lt;br&gt; webforms mindset and once you add jquery into the mix it&#39;s really fun.
  </summary>
  </entry>
  <entry>
  <author>
  <name>Derek Fowler</name>
  <email>dezfow...@gmail.com</email>
  </author>
  <updated>2009-09-14T11:26:01Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/33c42bba2d6aa6ea?show_docid=33c42bba2d6aa6ea</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/33c42bba2d6aa6ea?show_docid=33c42bba2d6aa6ea"/>
  <title type="text">Re: [luodn] Re: MVC</title>
  <summary type="html" xml:space="preserve">
  Bit far for me to come now - suppose I could get a flight. &lt;br&gt; &lt;p&gt;2009/9/14 Thom Shannon &amp;lt;t...@glow-internet.com&amp;gt; &lt;br&gt; &lt;p&gt;-- &lt;br&gt; Derek Fowler &lt;br&gt; m. +44 (0) 7966 512 369 &lt;br&gt; e. dezfow...@gmail.com
  </summary>
  </entry>
  <entry>
  <author>
  <name>Thom Shannon</name>
  <email>t...@glow-internet.com</email>
  </author>
  <updated>2009-09-14T11:13:46Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/757431de959906e3?show_docid=757431de959906e3</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/757431de959906e3?show_docid=757431de959906e3"/>
  <title type="text">Re: MVC</title>
  <summary type="html" xml:space="preserve">
  Thanks guys! That was all helpful. &lt;br&gt; We should get the luodn meetings going again :)
  </summary>
  </entry>
  <entry>
  <author>
  <name>Paul Kinlan</name>
  <email>paul.kin...@gmail.com</email>
  </author>
  <updated>2009-09-14T10:37:10Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/e57e41f482381a33?show_docid=e57e41f482381a33</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/e57e41f482381a33?show_docid=e57e41f482381a33"/>
  <title type="text">Re: [luodn] MVC</title>
  <summary type="html" xml:space="preserve">
  Hi Thom. &lt;br&gt; Used it quite a bit. &lt;br&gt; &lt;p&gt;I find it better to separate everything out, sometimes a controller action &lt;br&gt; for each form is best. In your case I would have a Search action on the the &lt;br&gt; controller that you are using. Then on your view (web page) have two forms &lt;br&gt; with the same method and action but with different hidden variables
  </summary>
  </entry>
  <entry>
  <author>
  <name>Donovan Hide</name>
  <email>donovanh...@gmail.com</email>
  </author>
  <updated>2009-09-14T10:35:35Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/0fd8da12bae8c87c?show_docid=0fd8da12bae8c87c</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/0fd8da12bae8c87c?show_docid=0fd8da12bae8c87c"/>
  <title type="text">Re: [luodn] MVC</title>
  <summary type="html" xml:space="preserve">
  Actually, re-reading your post it seems like your problem is how to &lt;br&gt; re-render the page after a post. Simple answer is don&#39;t, maintain &lt;br&gt; state in the client and do an AJAX post with some jQuery to an action &lt;br&gt; which returns just the search results and inserts them into the DOM. &lt;br&gt; The Postback and ViewState models don&#39;t really transfer to MVC.
  </summary>
  </entry>
  <entry>
  <author>
  <name>Derek Fowler</name>
  <email>dezfow...@gmail.com</email>
  </author>
  <updated>2009-09-14T10:35:15Z</updated>
  <id>http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/cbc06176820a785f?show_docid=cbc06176820a785f</id>
  <link href="http://groups.google.co.uk/group/liverpoolusersofdotnet/browse_thread/thread/15a312689612d0df/cbc06176820a785f?show_docid=cbc06176820a785f"/>
  <title type="text">Re: [luodn] MVC</title>
  <summary type="html" xml:space="preserve">
  You can have actions with the same name but you need to use the AcceptVerb &lt;br&gt; attribute and specify which verbs each is responsible for i.e. have one of &lt;br&gt; them handle the POST from the search form. Easiest thing is probably to just &lt;br&gt; have the action method expect two strings from the form and check &lt;br&gt; IsNullOrEmpty on each and decide what to do based on that.
  </summary>
  </entry>
</feed>
