Forums

Form to Databse I want

akari 04 Sep, 2008
hi,

I have finaly made a form and it is working perfectly, I want the form to be stored in an database i want and a table i choose.

Is this possible and how do i do this.
Max_admin 04 Sep, 2008
you need to create table for the form first, and if you have V3.0 BETA 2 then you need to connect the form to the table through the DB connections tab!

Cheers

Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
akari 04 Sep, 2008
hmmz ok i'll give that a try, i was more thinking of make new php file en put that in the submit so that that pgp file will fill the database,
akari 04 Sep, 2008
i have version 2.5 J1.5 RC3.1
Max_admin 04 Sep, 2008
go to forms management, check the box beside the form and then click create table, select which fields to be saved into database, click save table, you are done!
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
akari 04 Sep, 2008
let me tell you what i want to do, i'n working on this all day and can't figure it out,

<?php 
$user =& JFactory::getUser();
$usr_id = $user->get('userid');
$usr_em = $user->get('email');
$usr_name = $user->get('username');

?>  

<body>
<form action="" method="post" enctype="multipart/form-data" name="form1" id="form1">
  <label>Omschrijving:
  <input type="text" name="omschrijving" id="omschrijving" />
  </label>
  <p>Datum: 
    <select name="dag" id="dag">
      <option>1</option>
      <option>2</option>
      <option>3</option>
      <option>4</option>
      <option>5</option>
      <option>6</option>
      <option>7</option>
      <option>8</option>
      <option>9</option>
      <option>10</option>
      <option>11</option>
      <option>12</option>
      <option>13</option>
      <option>14</option>
      <option>15</option>
      <option>16</option>
      <option>17</option>
      <option>18</option>
      <option>19</option>
      <option>20</option>
      <option>21</option>
      <option>22</option>
      <option>23</option>
      <option>24</option>
      <option>25</option>
      <option>26</option>
      <option>27</option>
      <option>28</option>
      <option>29</option>
      <option>30</option>
      <option>31</option>
    </select>
    <select name="Maand" id="Maand">
      <option>Januari</option>
      <option>Februari</option>
      <option>Maart</option>
      <option>April</option>
      <option>Mei</option>
      <option>Juni</option>
      <option>Juli</option>
      <option>Augustus</option>
      <option>September</option>
      <option>Oktober</option>
      <option>November</option>
      <option>December</option>
    </select>
  </p>
  <p>Tijd: 
    <select name="our" id="our">
      <option>1</option>
      <option>2</option>
      <option>3</option>
      <option>4</option>
      <option>5</option>
      <option>6</option>
      <option>7</option>
      <option>8</option>
      <option>9</option>
      <option>10</option>
      <option>11</option>
      <option>12</option>
      <option>13</option>
      <option>14</option>
      <option>15</option>
      <option>16</option>
      <option>17</option>
      <option>18</option>
      <option>19</option>
      <option>20</option>
      <option>21</option>
      <option>22</option>
      <option>23</option>
      <option>00</option>
    </select>
  : 
  <select name="minutes" id="minutes">
    <option>00</option>
    <option>15</option>
    <option>30</option>
    <option>45</option>
  </select>
  (wanneer de reminder verstuurd word)</p>
  <p>Tekst:</p>
      <label for="rcontent"></label>
    <textarea name="rcontent" id="rcontent" cols="50" rows="9"></textarea>
  </p>
  <p>
    <input type="checkbox" name="day" id="day" />
  Dagelijks</p>
  <p>
    <input type="checkbox" name="weekly" id="weekly" />
  Weekelijks</p>
  <p>
    <input type="checkbox" name="month" id="month" />
  Maandelijks</p>
  <p>
    <input type="checkbox" name="year" id="year" />
  Jaarlijks</p>
  <p>
  </p>
  <p>
    <label for="submit"></label>
    <input type="reset" name="clear" id="clear" value="Leeg maken" />
    <input type="submit" name="Submit" id="Submit" value="Aanmaken" />
  </p>
</form>
</body>
</html>


As you can see in the beginneng, i want to get the userid,username and useremail.
if i create a table with croneforms it doesn't show up,

I have to use this table again in an external php with a cronjob. There for i need that information.
the date and time has to be in 1 field. withname senddate
Do you have any idea what i'm doing wrong.

this is the table i created on my own so you get an idea
  ID int(4)              
  userid int(4)                   
  omschrijving text                 
  inhoud text                 
  senddate datetime              
  email text                
  daily text                
  weekly tinyint(1)                 
  monthly tinyint(1)              
  yearly tinyint(1)               
  
Max_admin 05 Sep, 2008
Ok, so you have your table ready now, and your form still doesn't run, and need to store your data into table, for saving your time and getting things easier, uninstall Chronoforms V2.5 and install V3.0 then rebuild your form and remove the <form> tags from the code, then at the Db connection tab, set it to yes and choose that able you created adn save the form and you are done!

Regards,

Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
akari 05 Sep, 2008
ok i uninstalled the old version and installed the new version, made the form again from scratch, but now if i want to edit it i can an error

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, [email]webmaster@maily.nl[/email] and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.


--------------------------------------------------------------------------------

NOYB Server at <!-- w --><a class="postlink" href="http://www.maily.nl">www.maily.nl</a><!-- w --> Port 80
Max_admin 05 Sep, 2008
Hi akari,

do you have access to the the server error log to check what caused this error ?
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
akari 05 Sep, 2008
no. i already looked for that. this only happend with choroforms
v3.0b2
any ideas
Max_admin 05 Sep, 2008
Hi akari,

the error log will tell you whats the problem happened and so it generated this error, please open the log and go to edit the form, the error will happen, now refresh the log and see what it tells!
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
This topic is locked and no more replies can be posted.