Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to Localize Custom Module Content in Orchard CMS?
    primarykey
    data
    text
    <p>I had made some modules in my Orchard site using MVC 3 and EFW .I had also made contents using Orchard Cms like I made some static pages using CMS . But my module has dynamic data which user can add and change them using site admin area.But my question is that I had to localize my app but how ? I made enable Culture picker module and added po files of my desire language and added translations of every content of my site but when I change culture only my CMS content changes.my custom module which I made using MVC 3 and EntityFrameWork does not have any offect of site Culture how to localize my custom module contents ?</p> <pre><code>public class ContactUsController : Controller { DbEntities context = new DbEntities(); [HttpGet] public ActionResult Index() { return View(); } [HttpPost] public ActionResult SaveContacts(FormCollection frmData) { try { using (new TransactionScope(TransactionScopeOption.Suppress)) { if (ModelState.IsValid == true) { Imidus_ContactUs ob = new Imidus_ContactUs(); ob.UserName = frmData["UserName"]; ob.Subject = frmData["Subject"]; ob.Message = frmData["Message"]; ob.Email = frmData["Email"]; context.Imidus_ContactUs.Add(ob); context.SaveChanges(); return RedirectToAction("Success", "ContactUs"); } } } catch (Exception ex) { throw ex; } return View("Index"); } public ActionResult Success() { return View(); } } &lt;fieldset class="contact-form"&gt; @using (Html.BeginForm("SaveContacts", "ContactUs", FormMethod.Post, new { id = "frmContact" })) { @Html.ValidationSummary(true) &lt;span class="errormsg"&gt;&lt;/span&gt; &lt;label for="cname"&gt; Name&lt;/label&gt; &lt;div class="editor-field"&gt; &lt;input id="cname" name="UserName" minlength="2" type="text" required /&gt; &lt;/div&gt; &lt;div class="editor-label"&gt; &lt;label for="cemail"&gt; E-Mail&lt;/label&gt; &lt;/div&gt; &lt;div class="editor-field"&gt; &lt;input id="cemail" type="email" name="Email" required /&gt; @* @Html.EditorFor(model =&gt; model.Email, new { Class = "input-xlarge" }) *@ &lt;/div&gt; &lt;div class="editor-label"&gt; &lt;label for="csubject"&gt; Subject&lt;/label&gt; &lt;/div&gt; &lt;div class="editor-field"&gt; &lt;input id="csubject" name="Subject" minlength="2" type="text" required /&gt; @* @Html.EditorFor(model =&gt; model.Subject, new { Class = "input-xlarge" }) @Html.ValidationMessageFor(model =&gt; model.Subject)*@ &lt;/div&gt; &lt;div class="editor-label"&gt; &lt;label for="cMessage"&gt; Message&lt;/label&gt; &lt;/div&gt; &lt;div class="editor-field"&gt; &lt;input id="cMessage" name="Message" minlength="15" type="text" required /&gt; @* @Html.TextAreaFor(model =&gt; model.Message) @Html.ValidationMessageFor(model =&gt; model.Message)*@ &lt;/div&gt; &lt;p&gt; &lt;input type="submit" value="Submit" class="btn btn-primary block my-btn" /&gt; &lt;/p&gt; } &lt;/fieldset&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload