I am trying to create a Yahoo Search.  I think it is breaking where I
send the variable.. Your Help Would be greatly appreciated thanks:

Current Error:
Notice: Undefined variable: javascript in..

Control
  function showresult($yahoosearch = null)
  {
  $this->set('question', $this->showresult($yahoosearch));
  $yahoo = new
Zend_Service_Yahoo("APIKEYYESONTHELIVEVERSIONITISHERE");
  $yahoosearch = $yahoo->webSearch('question');
  return $yahoosearch;
  $this->log('Something broke');
  }


Index View:

<?=$ajax->form(array('action'=>'/yahoo/showresult'), 'post',
array('update'=>'yahoosearch','loading'=>"Toggle.display('spinner');",'complete'=>"Toggle.display('spinner');stripe();"))?
>
<?=$html->image('spinner.gif', array('alt'=>'spinner',
'id'=>'spinner', 'style'=>'display:none;'))?>
<fieldset>
  <label for="showresult">Search:</label>
  <?=$html->input('Yahoo/yahoosearch',array('type' => 'text', 'size'
=> '25'))?>
  <?=$html->submit('Find')?>
</fieldset>
<div id="yahoosearch"></div>
</form>

Show Result:

<?php
// app/views/yahoo/show.thtml
foreach ($question as $result)
{
echo "<h3><a href='{$result->ClickUrl}'>{$result->Title}</a></h3>";
echo "{$result->Summary}
[<a href='{$result->CacheUrl}'>Cached Version</a>]";
}
?>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to