Skip to main content

Home/ foograde/ Group items tagged and

Rss Feed Group items tagged

federico balderas

Redo The Web » Comparing Propel, Doctrine and sfPropelFinder - 0 views

  •  
    "Retrieving an article by its primary key // Propel $article = ArticlePeer::retrieveByPk(123); // Doctrine $article = Doctrine::getTable('Article')->find(123); // sfPropelFinder $article = sfPropelFinder::from('Article')->findPk(123);"
  •  
    Comparacion de Propel y Doctrine
Fernando Vega

symfony framework forum: symfony 1.3 and 1.4 => is there anyone can tell me how to use ... - 0 views

  • in the form $this->widgetSchema['login_id'] = new sfWidgetFormJQueryAutocompleter(array( 'url' => '/ajax/getUser', )); and in the action of executeGetUser $this->getResponse()->setContentType('application/json'); $users=Doctrine::getTable('user')->getLoginIDList(); return $this->renderText(json_encode($users)); And in the userTable which inside Doctrine $q=Doctrine_Query::create()->select('login_id')->from('user')- >execute(); foreach($q as $row){ $login_id[$row->login_id]=$row->login_id; } return $login_id; hope this help =]
    • Fernando Vega
       
      autocompletar con doctrine y sf 1.4
federico balderas

PHP: rmdir - Manual - 0 views

  •  
    "Here's another version of the recursive directory removal. This version requires PHP 5, and returns TRUE on success or FALSE on failure. "
  •  
    borra una carpeta del servidor con todo y sus subcarpetas y archivos
federico balderas

Symfony - Delete and reload all database records for each test - Stack Overflow - 0 views

  •  
    "$doctrine = new sfDoctrineDropDbTask($configuration->getEventDispatcher(), new sfAnsiColorFormatter()); $doctrine->run(array(), array("--no-confirmation","--env=test")); $doctrine = new sfDoctrineBuildDbTask($configuration->getEventDispatcher(), new sfAnsiColorFormatter()); $doctrine->run(array(), array("--env=test")); $doctrine = new sfDoctrineInsertSqlTask($configuration->getEventDispatcher(), new sfAnsiColorFormatter()); $doctrine->run(array(), array("--env=test"));"
Fernando Vega

symfony framework forum: symfony 1.3 and 1.4 => Admin generator, filters and I18n - 1 views

  •  
    "class MenuFormFilter extends BaseMenuFormFilter { private $rootAlias; public function configure() { $this->widgetSchema['title'] = new sfWidgetFormFilterInput(array('with_empty' => false)); $this->validatorSchema['title'] = new sfValidatorPass(array('required' => false)); $this->widgetSchema['type'] = new sfWidgetFormChoice(array( 'choices' => Doctrine_Core::getTable('Menu')->getTypes(), 'expanded' => false, )); $this->validatorSchema['type'] = new sfValidatorChoice(array( 'choices' => array_keys(Doctrine_Core::getTable('Menu')->getTypes()), )); } public function addTitleColumnQuery(Doctrine_Query $q, $field, $values) { if (is_array($values) && isset($values['text']) && '' != $values['text']) { $this->JoinTable($q); $q->andWhere('t.title like ?', '%' . str_replace(" ","%",$values['text']) . '%'); } } public function addTypeColumnQuery(Doctrine_Query $q, $field, $values){ if (isset($values) && '%' != $values) { $this->JoinTable($q); $q->andWhere('t.type = ?', $values); } } private function JoinTable(Doctrine_Query $q){ if(empty($this->rootAlias)){ $request = sfContext::getInstance()->getRequest(); $this->rootAlias = $q->getRootAlias(); $q->leftJoin($this->rootAlias.'.Translation t') ->andWhere('t.lang = ?', $request->getParameter('sf_culture', 'ro')); // or it will search in all of them } } public function getFields(){ return parent::getFields() + array('type' => 'Text') + array('title' => 'Text'); } } "
Fernando Vega

The Definitive Guide to symfony | Chapter 9 - Links And The Routing System | symfony | ... - 0 views

  • prod: .settings no_script_name: off
    • Fernando Vega
       
      para eliminar el nombre del controlador en lo enlaces
Adán Muguiro

jQuery: Get the checked and unchecked items from list of checkboxes « Sushant... - 0 views

  •  
    Manejo de checkboxes con jQuery
Adán Muguiro

sfWidgetFormPropelChoice y el valor seleccionado - 0 views

  • in BaseFormPropel i have the function : public function setValue($field,$value){ $this->widgetSchema[$field]->setDefault ($value); } and in my action : $this->form->setValue('idtype_doc',$this->getUser()->getAttribute('dossier_rec[type_doc]'));
  •  
    Cómo modificar el valor seleccionado dentro de un select de propel o cualquier otro.
Adán Muguiro

Git - DreamHost - 0 views

  • Setup One: For the Impatient If git is already working on your server (it was on mine), this will get you up and running ASAP. # Setup SSH keys [local ~]$ ssh-keygen -t rsa [local ~]$ ssh-copy-id [user@]host [local ~]$ eval `ssh-agent` [local ~]$ ssh-add # Create the local repository [local ~]$ cd project [local project]$ git init [local project]$ touch .gitignore [local project]$ git add . [local project]$ git commit # Create a bare remote repository [local project]$ ssh [user@]host [host ~]$ mkdir project.git [host ~]$ cd project.git [host project.git]$ git --bare init [host project.git]$ exit # Push to the remote repository [local project]$ git remote add origin ssh://[user@]host/~/project.git [local project]$ git push origin master [local project]$ git branch --set-upstream master origin/master # Clone from the remote repository [other ~]$ git clone ssh://[user@]host/~/project.git
  •  
    Configuración de Git en Dreamhost
1 - 10 of 10
Showing 20 items per page