Welcome Guest, Not a member yet? Register   Sign In
unable to store query
#8

[eluser]krishnakumar2k[/eluser]
[quote author="InsiteFX" date="1299695959"]Did you create a form to get the input?

If so show your form code and controller code.

InsiteFX[/quote]

Code:
controller code

$data1['content'] = $this->input->post('content');
$this->service_model->insertContent($data1);

form

<form name="kkdh" action="<?php echo site_url("login/editor_add"); ?>" method="post">
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="left" style="margin-bottom:25px;">
  <tr style="color:#FFFFFF;">
    &lt;input type="hidden" value="&lt;?php echo base_url();?&gt;" id="url" /&gt;
    <td width="10%" rowspan="2"><img src="&lt;?php echo base_url();?&gt;images/manage_plans.jpg" width="56" /></td>
    <td  height="11" colspan="5" style="background-color:#84BCED;">&nbsp;&nbsp;<span class="bigwhitetext"> Editor</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
  </tr>
  <tr style="color:#FFFFFF;">
    <td width="11%">&nbsp;</td>
    <td  height="11" colspan="2" ></td>
  </tr>
  &lt;?php if($error !=""){ ?&gt;
   <tr >
    <td width="10%" >&nbsp;</td>
    <td width="11%">&nbsp;</td>
    <td width="71%" >
        <div style="background-color:#990000;color:#FFFFFF;border:1px solid #FF0000;font-weight:bold;">&lt;?php echo $error; ?&gt;</div>
    
    </td>
    <td width="0%" >&nbsp;</td>
    <td width="8%"  height="11" colspan="2" ></td>
  </tr>
  &lt;?php } ?&gt;
  <tr >
    <td width="10%" >&nbsp;</td>
    <td width="11%">&nbsp;</td>
    <td width="71%" >
        <table width="568">
      <tr>
             <td width="192" class="greytext_contact">Menu Title</td>
            <td width="364">&lt;input type="text"&gt;&lt;/td>
          </tr>
            <tr>
             <td class="greytext_contact">Enable Menu</td>
             <td>&lt;input type="checkbox" name="status" &lt;?php if($content['status']== 1){echo 'checked="checked"';} ?&gt;  value="1" /&gt;&lt;/td>
            </tr>
               <tr>
              <td valign="top" class="greytext_contact">HTML Content</td>
             <td>&lt;textarea name="content" id="kk1" rows="15" cols="55" &gt;&lt;/textarea></td>
            
            </tr>
            <tr>
             <td></td><td>&lt;input type="submit" value="Submit" /&gt;&lt;/td>
            </tr>
        </table>
    
    
    </td>
    <td width="0%" >&nbsp;</td>
    <td width="8%"  height="11" colspan="2" ></td>
  </tr>
</table>
&lt;/form&gt;


Messages In This Thread
unable to store query - by El Forum - 03-09-2011, 05:58 AM
unable to store query - by El Forum - 03-09-2011, 06:02 AM
unable to store query - by El Forum - 03-09-2011, 06:08 AM
unable to store query - by El Forum - 03-09-2011, 06:19 AM
unable to store query - by El Forum - 03-09-2011, 06:32 AM
unable to store query - by El Forum - 03-09-2011, 06:33 AM
unable to store query - by El Forum - 03-09-2011, 06:39 AM
unable to store query - by El Forum - 03-09-2011, 06:44 AM
unable to store query - by El Forum - 03-09-2011, 06:51 AM



Theme © iAndrew 2016 - Forum software by © MyBB