Author: rande
Date: 2010-02-16 16:59:54 +0100 (Tue, 16 Feb 2010)
New Revision: 28059

Modified:
   
plugins/mgI18nPlugin/branches/sf1.2/modules/mgI18nAdmin/templates/_displayTranslationBox.php
   
plugins/mgI18nPlugin/branches/sf1.3/lib/form/plugin/PluginmgI18nTargetsForm.class.php
   
plugins/mgI18nPlugin/branches/sf1.3/modules/mgI18nAdmin/templates/_displayTranslationBox.php
Log:
[mgI18nPlugin] add default relative url root to asset, make the form works with 
sf1.3 and upper

Modified: 
plugins/mgI18nPlugin/branches/sf1.2/modules/mgI18nAdmin/templates/_displayTranslationBox.php
===================================================================
--- 
plugins/mgI18nPlugin/branches/sf1.2/modules/mgI18nAdmin/templates/_displayTranslationBox.php
        2010-02-16 15:48:03 UTC (rev 28058)
+++ 
plugins/mgI18nPlugin/branches/sf1.2/modules/mgI18nAdmin/templates/_displayTranslationBox.php
        2010-02-16 15:59:54 UTC (rev 28059)
@@ -20,8 +20,8 @@
 <script type="text/javascript" 
src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/jquery-ui.min.js"; 
></script>
 -->
 
-<link rel="stylesheet" type="text/css" media="screen" 
href="/mgI18nPlugin/css/redmond-jquery-ui.css" />
-<script type="text/javascript" src="/mgI18nPlugin/js/gui.js" ></script>
+<link rel="stylesheet" type="text/css" media="screen" href="<?php echo 
$sf_request->getRelativeUrlRoot() ?>/mgI18nPlugin/css/redmond-jquery-ui.css" />
+<script type="text/javascript" src="<?php echo 
$sf_request->getRelativeUrlRoot() ?>/mgI18nPlugin/js/gui.js" ></script>
 
 <div id="mg-i18n-dialog" class="ui-widget">
   <div id="mg-i18n-on-top-box">

Modified: 
plugins/mgI18nPlugin/branches/sf1.3/lib/form/plugin/PluginmgI18nTargetsForm.class.php
===================================================================
--- 
plugins/mgI18nPlugin/branches/sf1.3/lib/form/plugin/PluginmgI18nTargetsForm.class.php
       2010-02-16 15:48:03 UTC (rev 28058)
+++ 
plugins/mgI18nPlugin/branches/sf1.3/lib/form/plugin/PluginmgI18nTargetsForm.class.php
       2010-02-16 15:59:54 UTC (rev 28059)
@@ -24,7 +24,8 @@
     $this->setWidgets(array(
       'catalogue' => new sfWidgetFormInput,
       'source'    => new sfWidgetFormInput,
-      'targets'   => new sfWidgetFormChoiceMany(array(
+      'targets'   => new sfWidgetFormChoice(array(
+        'multiple' => true,
         'choices' => sfConfig::get('app_mgI18nPlugin_cultures_available')
     ))
     ));
@@ -34,14 +35,9 @@
       'source'    => new sfValidatorString(array('required' => true)),
       'targets'   => new sfValidatorPass()
     ));
-    
+   
+    $this->disableLocalCSRFProtection();
   }
-
-  // we don't use this feature for now, the action should not be called in 
production
-  public function addCSRFProtection($CSRFSecret)
-  {
-    
-  }
   
   public function save()
   {

Modified: 
plugins/mgI18nPlugin/branches/sf1.3/modules/mgI18nAdmin/templates/_displayTranslationBox.php
===================================================================
--- 
plugins/mgI18nPlugin/branches/sf1.3/modules/mgI18nAdmin/templates/_displayTranslationBox.php
        2010-02-16 15:48:03 UTC (rev 28058)
+++ 
plugins/mgI18nPlugin/branches/sf1.3/modules/mgI18nAdmin/templates/_displayTranslationBox.php
        2010-02-16 15:59:54 UTC (rev 28059)
@@ -20,8 +20,8 @@
 <script type="text/javascript" 
src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/jquery-ui.min.js"; 
></script>
 -->
 
-<link rel="stylesheet" type="text/css" media="screen" 
href="/mgI18nPlugin/css/redmond-jquery-ui.css" />
-<script type="text/javascript" src="/mgI18nPlugin/js/gui.js" ></script>
+<link rel="stylesheet" type="text/css" media="screen" href="<?php echo 
$sf_request->getRelativeUrlRoot() ?>/mgI18nPlugin/css/redmond-jquery-ui.css" />
+<script type="text/javascript" src="<?php echo 
$sf_request->getRelativeUrlRoot() ?>/mgI18nPlugin/js/gui.js" ></script>
 
 <div id="mg-i18n-dialog" class="ui-widget">
   <div id="mg-i18n-on-top-box">

-- 
You received this message because you are subscribed to the Google Groups 
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/symfony-svn?hl=en.

Reply via email to