Jump to content
Larry Ullman's Book Forums


  • Content Count

  • Joined

  • Last visited

Everything posted by melaniecarr23

  1. I have two tables: -players -registrations Each Registrations record can have many Players associated with it. My registration/create action gives me a syntax error: syntax error, unexpected '$registration' (T_VARIABLE)Can someone help me see what I'm doing wrong to make this work? It's one of the biggest pieces of the puzzle I need to work locally before I can see if it works online. I created a controller named RegistrationController.php <?php namespace backend\controllers; use Yii; use backend\models\Registrations; use backend\models\Players; use backend\models\search
  2. This was solved by using &PlayersSearch[registrationID]=29 instead of just &registrationID=29.
  3. I want to be able to click on a link from the registration gridview, and filter the results of the players gridview so only the players I selected show up. Right now, it's not filtering. I get all the players. I have the following tables: - registrations - players From the registrations/index gridview I have a link so I can edit players: <?= DynaGrid::widget([ 'columns' => [ ['attribute'=>'playersEditLink', 'format'=>'raw'], [ 'label'=>'Player(s)', 'format' => 'raw', 'value' => function ($dat
  4. Yii1 I actually am working on two sites (my own and one I volunteer to help a nonprofit with). The original guy did the site using Yii, but from what I'm able to see, he didn't do a lot of it the Yii way and it's making my life hell). This is the nonprofit site and is using yii1 locally running mamp pro on my macbook, and remotely hosted at digital ocean using Ubuntu. mysql is the db for both. I wish I could just drive out to State College one day and soak up everything from you like a sponge!
  5. admin/views/registrations/admin.php <?php $this->breadcrumbs = array( $model->label(2) => array('index'), Yii::t('app', 'Manage'), ); $this->menu = array( array('label'=>Yii::t('app', 'List') . ' ' . $model->label(2), 'url'=>array('index')), array('label'=>Yii::t('app', 'Create') . ' ' . $model->label(), 'url'=>array('create')), ); Yii::app()->clientScript->registerScript('search', " $('.search-button').click(function(){ $('.search-form').toggle(); return false; }); $('.search-form form').submit(function(){ $.fn.yiiGridView.update('registr
  6. I was able to follow everything you wrote in the book on yii booster and modules and tested everything locally on my mac using MAMP. It worked great. Dropdown menus, tables with dropdown related filtering, editable fields, toggle fields. Beautiful amazing module! I uploaded it to the server and can't get booster to work at all. I changed my yii booster menu to a CMenu version and it works, so I know it's got something to do with how I'm initializing or configuring yii booster. main.php (I can't change the way URLs are done or preload booster for the whole site) 'modules'=>array(
  7. Thanks. I abandoned this thought, and decided to instead try developing everything new in Yii 2 and publish when it's done.
  8. I don't know what I did to mess it up, but I got this working.
  9. I figured out what I was doing wrong. I now just use the admin.php view for both, but with different controller actions. public function actionAdminLinked($id) { $model = new Registrations('search'); if (isset($_GET['Registrations'])) $model->setAttributes($_GET['Registrations']); $model->ID = $id; $this->render('admin', array( 'model' => $model, )); } public function actionDivisionlevel($id) { $model = new Registrations('search'); if (isset($_GET['Registrations'])) $model->setAttributes($_GET['Registrations']); $model->divisionLevelID
  10. I have been using the Yii Book to create an admin module for a site I didn't create that uses the yii framework. I was able to successfully create the module, apply login functionality to it, and implement Yii booster for extendedgrid functionality with inline editing. I can link the text from a column using the foreign key relation to a different model's view (primary key) and display those results using the TbExtendedGridView. What doesn't seem to work for me is displaying the results according to a different attribute other than the primary key. Link: http://mysites.com/index.
  11. Yes, I was following an article I found online since I realized it wasn't easy for me to migrate from yii1 to yii2 and I wanted to use the newer version.
  12. Okay I'm still going through the book and I LOVED the Booster plugin but I don't get the Giix plugin at all. I installed it and ran the giix model and giix crud for tables that are related but the code generated for my one model doesn't even show the admin page. It's just a blank white screen! I look for documentation on how to use the features of this extension and there isn't any! Just issues. What am I missing. I can't see supporting an extension that doesn't help you figure out what you can do with it. MANY_MANY relationships with lookup tables are my freaking nemesis.
  13. I have Yii 1.1.16 installed and had been using the yii book to help me. I installed yii2 with the intention of using the suggestion for running both at the same time, and the yii book 2 helped with the installation but I can't seem to get it to work. My error is: Fatal error: Call to undefined method Yii::registerAutoloader() in /home/drcarr/protected/components/Yii.php on line 16 I could use some help fixing it, or suggestions on changing my yii1 site into a yii2 site that also runs from the main directory of the domain.
  • Create New...