[TYPO3-dev] Problem with changing query according to post-parameter

Walter Seeberger walk2moon at gmx.de
Fri Jul 31 14:14:51 CEST 2009


Hello there,

I try to react upon some post-parameters by changing data according to that in the model.ok:

first I am doing some query and print the result trough my template.works!:

<?php if($this->isNotEmpty()) { ?>
					<ul>
					<?php } ?>
					<?php for($this->rewind(); $this->valid(); $this->next()) {
						$entry = $this->current();
						?>
						<li><?php $entry->printAsText('name'); ?></li>
						<?php } ?>
						<?php if($this->isNotEmpty()) { ?>
					</ul>
	<?php } ?>


Now I am using my form to put in some param. My template calls this function in the controller:

public function formCallAction(){
	$modelClassName = tx_div::makeInstanceClassName('tx_testext_model_data');
    	$model = new $modelClassName($this);
        $model->load($this->parameters);	
	
        $view = tx_div::makeInstance('tx_testext_view_resultlist');
	$view->exchangeArray($this->parameters);
	$view->controller($this);
	$view->render($this->configurations->get('resultlist'));
	
        $className = tx_div::makeInstanceClassName('tx_lib_translator');
	$translator = new $className($this, $view);
	return $translator->translateContent();
    }

The result is: Fatal error: Call to a member function printAsText() on a non-object ... /template.php in line 9.

Is anyone able to help me with this problem?
Need some ;-)

Regards, 
Walter
-- 
Neu: GMX Doppel-FLAT mit Internet-Flatrate + Telefon-Flatrate
für nur 19,99 Euro/mtl.!* http://portal.gmx.net/de/go/dsl02




More information about the TYPO3-dev mailing list