SQL Daten abspeicher in Datenbank und wieder auslesen

Diese Seite verwendet Cookies. Durch die Nutzung unserer Seite erklären Sie sich damit einverstanden, dass wir Cookies setzen. Weitere Informationen

  • SQL Daten abspeicher in Datenbank und wieder auslesen

    Hallo ich habe joomla 2.5 und das Free modul Projektfork was ich derzeit
    umschreibe. Dies ist für mein Chef für die Arbeit für interne nutzung
    gedacht um Werkstatt Aufträge anzulegen, Speichern, Drucke etc



    und zwar soll diese Seite:

    Quellcode

    1. <?php
    2. /**
    3. * $Id: form_new_task.php 864 2011-03-21 06:02:52Z angek $
    4. * @package Projectfork
    5. * @subpackage Tasks
    6. * @copyright Copyright (C) 2006-2010 Tobias Kuhn. All rights reserved.
    7. * @license http://www.gnu.org/licenses/gpl.html GNU/GPL, see LICENSE.php
    8. *
    9. * This file is part of Projectfork.
    10. *
    11. * Projectfork is free software: you can redistribute it and/or modify
    12. * it under the terms of the GNU General Public License License as published by
    13. * the Free Software Foundation, either version 3 of the License,
    14. * or any later version.
    15. *
    16. * Projectfork is distributed in the hope that it will be useful,
    17. * but WITHOUT ANY WARRANTY; without even the implied warranty of
    18. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    19. * GNU General Public License for more details.
    20. *
    21. * You should have received a copy of the GNU General Public License
    22. * along with Projectfork. If not, see <http://www.gnu.org/licenses/gpl.html>.
    23. **/
    24. defined( '_JEXEC' ) or die( 'Restricted access' );
    25. ?>
    26. <script type="text/javascript">
    27. function submitbutton(pressbutton)
    28. {
    29. if(document.adminForm.title.value == "") {
    30. alert("<?php echo PFformat::Lang('V_TITLE');?>");
    31. }
    32. else {
    33. <?php if($use_editor && !defined('PF_DEMO_MODE')) { echo $editor->save( 'text' ); } ?>
    34. submitform( pressbutton );
    35. }
    36. }
    37. function switch_deadline(ch)
    38. {
    39. var el = document.getElementById('dealine_table');
    40. if(ch) {
    41. el.style.display = "";
    42. }
    43. else {
    44. el.style.display = "none";
    45. }
    46. }
    47. function add_user()
    48. {
    49. var template = document.getElementById('user_template').innerHTML;
    50. var dest = document.getElementById('user_container');
    51. var div = document.createElement('div');
    52. div.style.padding = '2px';
    53. div.innerHTML = template;
    54. dest.appendChild(div);
    55. }
    56. </script>
    57. <?php echo $form->start();?>
    58. <a id="pf_top"></a>
    59. <div class="pf_container">
    60. <div class="pf_header componentheading">
    61. <h1><?php echo $ws_title." / "; echo PFformat::Lang('TASKS');?> :: <?php echo PFformat::Lang('NEW');?></h1>
    62. </div>
    63. <div class="pf_body">
    64. <!-- NAVIGATION START-->
    65. <?php PFpanel::Position('tasks_nav');?>
    66. <!-- NAVIGATION END -->
    67. <?php
    68. jimport('joomla.html.pane');
    69. $tabs = JPane::getInstance('Tabs');
    70. echo $tabs->startPane('paneID');
    71. echo $tabs->startPanel(PFformat::Lang('GENERAL_INFORMATION'), 'pane1');
    72. ?><form name="createEntityForm" method="post" action="/crm/CreateCommonModule.do" onsubmit="return selectCreateEntityAction('Create');"><input name="fieldname" value="property(CASECF51);property(CASECF7);property(Case Origin);property(Status);property(Subject);property(CASECF11);property(CASECF12);property(Phone);property(Email);property(CASECF81);property(CASECF13);property(CASECF4);property(CASECF1);property(CASECF5);property(CASECF3);property(CASECF8)" type="hidden"><input name="fieldlabel" value="Lieferschein Nr;Angenommen;Case Origin;Status;Subject;Stra&szlig;e;PLZ Ort;Phone;Email;Voraussicht. Fertigstellung;Newsletter;Mit folgendem Zubehör;Es Wurde abgegeben;Sonstiges Zubeh&uuml;r;Passwort;Fach" type="hidden"><input name="fielddatatype" value="I~O;V~M;V~M;V~M;V~M;V~M;V~M;V~M;E~M;D~O;V~M;V~M;V~M;V~M;V~M;V~M" type="hidden"><input name="rowCount" value="1" type="hidden"><input name="dtPtn" value="dd.MM.yyyy" type="hidden"><input name="relmodule" value="null" type="hidden"><input name="isload" value="null" type="hidden"><input name="range_value" value="null" type="hidden"><input name="FROM_INDEX" value="null" type="hidden"><input name="TO_INDEX" value="null" type="hidden"><input name="picklistFields" value="null" type="hidden"><input name="actionRedirect" value="null" type="hidden"><input name="module" value="Cases" type="hidden"><input name="property(module)" value="Cases" type="hidden"><input id="cvid" name="cvid" value="null" type="hidden"><input id="recordNum" name="recordNum" value="null" type="hidden">
    73. <table border="0" cellpadding="0" cellspacing="0" width="100%"><tbody><tr><td class="Cases-titleIcon">&nbsp;</td>
    74. <td class="title hline" style="padding-left:10px" height="30">
    75. Fall Bearbeiten
    76. </td><td class="hline" align="right">
    77. <</td></tr></tbody></table><p></p>
    78. <input name="singularModule" id="singularModule" value="Case" type="hidden"><div class="bodyText mandatory"></div><input value="create" name="operation" id="operation" type="hidden">
    79. <table border="0" cellpadding="0" cellspacing="0" width="95%"><tbody><tr><td align="center">
    80. <div style="float:right;" class="bodyText"></div>
    81. </td></tr></tbody></table><p></p>
    82. <div id="secDivCase Information"><table id="secHeadCase Information" cellpadding="0" cellspacing="0" width="95%">
    83. <tbody width="100%"><tr><td class="secHead">Fall Information</td></tr></tbody></table>
    84. <table id="secContentCase Information" class="secContent" border="0" cellpadding="0" cellspacing="1" width="95%">
    85. <tbody width="100%"><tr id="row0_Case Information"><td class="label mandatory" width="25%">*Angenommen:</td>
    86. <td class="element" width="25%"><input name="uiType_property(CASECF7)" id="uiType_property(CASECF7)" value="2" type="hidden">
    87. <select name="property(CASECF7)" class="select" style="width:95%" onchange="setDependent(this,false)">
    88. <option value="">-Keine-</option><option value="Horst Neumann">Horst Neumann</option>
    89. <option value="Marco Grabitzky">Marco Grabitzky</option><option value="Daniel Kühl">Daniel K&uuml;hl</option>
    90. <option value="Klaas Kuhlmann">Klaas Kuhlmann</option><option value="Marc Peters">Marc Peters</option>
    91. <option value="Aushilfe">Aushilfe</option></select></td>
    92. <td class="label" width="25%">Fall Zust&auml;ndiger:</td>
    93. <td style="vertical-align:top;padding-top:4" width="25%">
    94. <input name="uiType_property(Case Owner)" id="uiType_property(Case Owner)" value="8" type="hidden">
    95. <input class="searchFormatText" name="property(Case Owner)" id="ownerName" readonly="true" type="text">
    96. <input value="515225000000050003" name="property(ownerId)" id="ownerId" type="hidden"></td></tr><tr id="row1_Case Information">
    97. <td class="label mandatory" width="25%">*Fall Ursprung:</td><td class="element" width="25%">
    98. <input name="uiType_property(Case Origin)" id="uiType_property(Case Origin)" value="2" type="hidden">
    99. <select name="property(Case Origin)" class="select" style="width:95%" onchange="setDependent(this,false)">
    100. <option value="">-Keine-</option><option value="Kein">Kein</option><option value="Vor Ort">Vor Ort</option>
    101. <option value="Tel.">Tel.</option></select></td><td class="label mandatory" width="25%">*Status:</td><td class="element" width="25%">
    102. <input name="uiType_property(Status)" id="uiType_property(Status)" value="2" type="hidden">
    103. <select name="property(Status)" class="select" style="width:95%" onchange="setDependent(this,false)">
    104. <option value="">-Keine-</option><option value="Neu" selected="true">Neu</option><option value="In Bearbeitung">In Bearbeitung</option>
    105. <option value="Unterwegs / RMA">Unterwegs / RMA</option><option value="Abgeschlossen">Abgeschlossen</option>
    106. <option value="Warten auf Ersatzteile">Warten auf Ersatzteile</option></select></td></tr><tr id="row2_Case Information">
    107. <td class="label mandatory" width="25%">*Betreff:</td><td class="element" width="10%">
    108. <input name="uiType_property(Subject)" id="uiType_property(Subject)" value="1" type="hidden">
    109. <input autocomplete="off" name="property(Subject)" id="property(Subject)" class="textField" style="width:100%" maxlength="300" type="text">
    110. </td><td class="label" width="25%">Priorit&auml;t</td>
    111. <td class="element" width="25%"><input name="uiType_property(Priority)" id="uiType_property(Priority)" value="2" type="hidden">
    112. <select name="property(Priority)" class="select" style="width:95%" onchange="setDependent(this,false)"><option value="">-Keine-</option>
    113. <option value="Normal">Normal</option><option value="Sofort Service">Sofort Service</option></select></td></tr><tr id="row3_Case Information">
    114. <td class="label mandatory" width="25%">*Stra&szlig;e:</td><td class="element" width="25%">
    115. <input name="uiType_property(CASECF11)" id="uiType_property(CASECF11)" value="1" type="hidden">
    116. <input name="property(CASECF11)" id="property(CASECF11)" class="textField" style="width:100%" maxlength="20" type="text">
    117. </td><td class="label" width="25%">Fall Grund:</td><td class="element" width="25%">
    118. <input name="uiType_property(Case Reason)" id="uiType_property(Case Reason)" value="2" type="hidden">
    119. <select name="property(Case Reason)" class="select" style="width:95%" onchange="setDependent(this,false)">
    120. <option value="">-Keine-</option><option value="Hardware Problem">Hardware Problem</option><option value="Viren Problem">Viren Problem</option>
    121. <option value="Software Problem">Software Problem</option><option value="Unbekanntes Problem">Unbekanntes Problem</option>
    122. <option value="Neues Problem">Neues Problem</option></select></td></tr><tr id="row4_Case Information">
    123. <td class="label mandatory" width="25%">*PLZ Ort:</td><td class="element" width="25%">
    124. <input name="uiType_property(CASECF12)" id="uiType_property(CASECF12)" value="1" type="hidden">
    125. <input name="property(CASECF12)" id="property(CASECF12)" class="textField" style="width:100%" maxlength="20" type="text">
    126. </td><td class="label" width="25%">min. Kosten 39,- &euro;:</td><td class="element" width="25%">
    127. <input name="uiType_property(CASECF109)" id="uiType_property(CASECF109)" value="300" type="hidden">
    128. <input name="property(CASECF109)" checked="true" type="checkbox"></td></tr><tr id="row5_Case Information">
    129. <td class="label mandatory" width="25%">*Tel.:</td><td class="element" width="25%">
    130. <input name="uiType_property(Phone)" id="uiType_property(Phone)" value="33" type="hidden">
    131. <input name="property(Phone)" id="property(Phone)" class="textField" style="width:100%" maxlength="300" type="text">
    132. </td><td class="label" width="25%">Daten Wichtig?:</td><td class="element" width="25%">
    133. <input name="uiType_property(CASECF10)" id="uiType_property(CASECF10)" value="2" type="hidden">
    134. <select name="property(CASECF10)" class="select" style="width:95%" onchange="setDependent(this,false)">
    135. <option value="">-Keine-</option><option value="JA">JA</option><option value="NEIN">NEIN</option>
    136. <option value="Noch zu klären">Noch zu klären</option></select></td></tr><tr id="row6_Case Information">
    137. <td class="label mandatory" width="25%">*E-Mail:</td><td class="element" width="25%">
    138. <input name="uiType_property(Email)" id="uiType_property(Email)" value="25" type="hidden">
    139. <input name="property(Email)" id="property(Email)" class="textField" style="width:100%" maxlength="300" type="text">
    140. </td><td class="label" width="25%">Voraussicht. Fertigstellung:</td><td class="element" width="25%">
    141. <input name="uiType_property(CASECF81)" id="uiType_property(CASECF81)" value="24" type="hidden">
    142. <div class="bodyText" style="position:relative;">
    143. <input name="property(CASECF81)" class="textField" style="width:90px" maxlength="20" autocomplete="off" onclick="showCalen('property(CASECF81)',this.value)" type="text"><br>
    144. <span class="dim" id="dtPtn_property(CASECF81)" name="dtPtn_property(CASECF81)">dd.MM.yyyy</span></div></td></tr>
    145. <tr id="row7_Case Information"><td class="label mandatory" width="25%">*Newsletter:</td><td class="element" width="25%">
    146. <input name="uiType_property(CASECF13)" id="uiType_property(CASECF13)" value="2" type="hidden">
    147. <select name="property(CASECF13)" class="select" style="width:95%" onchange="setDependent(this,false)">
    148. <option value="">-Keine-</option><option value="Ja">Ja</option><option value="Nein">Nein</option></select></td>
    149. <td class="label mandatory" width="25%">*Mit folgendem Zubeh&ouml;r:</td><td class="element" width="25%">
    150. <input name="uiType_property(CASECF4)" id="uiType_property(CASECF4)" value="100" type="hidden">
    151. <input name="CASECF4" id="CASECF4" value="1" type="hidden">
    152. <select multiple="multiple" class="select" name="comboValue1" id="comboValue1" style="width:95%"><option value="Ohne ZB">Ohne ZB</option>
    153. <option value="Tasche">Tasche</option><option value="Netzteil">Netzteil</option><option value="Kabel">Kabel</option>
    154. <option value="Rechnung">Rechnung</option><option value="CD /'s">CD /'s</option><option value="Maus">Maus</option></select>
    155. <input name="property(CASECF4)" id="combo1" type="hidden"></td></tr>
    156. <tr id="row8_Case Information"><td class="label mandatory" width="25%">*Es Wurde abgegeben:</td><td class="element" width="25%">
    157. <input name="uiType_property(CASECF1)" id="uiType_property(CASECF1)" value="2" type="hidden">
    158. <select name="property(CASECF1)" class="select" style="width:95%" onchange="setDependent(this,false)">
    159. <option value="">-Keine-</option><option value="Notebook">Notebook</option><option value="Desktop">Desktop</option>
    160. <option value="Drucker">Drucker</option><option value="Monitor">Monitor</option>
    161. <option value="Speicher (HDD, RAM, Flash)">Speicher (HDD, RAM, Flash)</option>
    162. <option value="Andere Geräte">Andere Geräte</option></select></td><td class="label mandatory" width="25%">*Sonstiges Zubeh&ouml;r:</td>
    163. <td class="element" width="25%"><input name="uiType_property(CASECF5)" id="uiType_property(CASECF5)" value="1" type="hidden">
    164. <input name="property(CASECF5)" id="property(CASECF5)" class="textField" style="width:100%" maxlength="20" type="text"></td></tr>
    165. <tr id="row9_Case Information"><td class="label" width="25%">Herrsteller:</td>
    166. <td class="element" width="25%"><input name="uiType_property(CASECF2)" id="uiType_property(CASECF2)" value="2" type="hidden">
    167. <select name="property(CASECF2)" class="select" style="width:95%" onchange="setDependent(this,false)"><option value="">-Keine-</option>
    168. <option value="Nordland">Nordland</option><option value="Acer">Acer</option><option value="Asus">Asus</option>
    169. <option value="Packard Bell">Packard Bell</option><option value="HP">HP</option><option value="Dell">Dell</option>
    170. <option value="Medion">Medion</option><option value="FSC">FSC</option><option value="Sony">Sony</option><option value="Samsung">Samsung</option>
    171. <option value="MSI">MSI</option><option value="Andere /Unbekannt">Andere /Unbekannt</option></select></td>
    172. <td class="label mandatory" width="25%">*Passwort:</td>
    173. <td class="element" width="25%"><input name="uiType_property(CASECF3)" id="uiType_property(CASECF3)" value="1" type="hidden">
    174. <input name="property(CASECF3)" id="property(CASECF3)" class="textField" style="width:100%" maxlength="20" type="text"></td></tr>
    175. <tr id="row10_Case Information"><td class="label" width="25%">Typ /Art:</td><td class="element" width="25%">
    176. <input name="uiType_property(CASECF9)" id="uiType_property(CASECF9)" value="1" type="hidden">
    177. <input name="property(CASECF9)" id="property(CASECF9)" class="textField" style="width:100%" maxlength="20" type="text"></td>
    178. <td class="label mandatory" width="25%">*Fach:</td><td class="element" width="25%">
    179. <input name="uiType_property(CASECF8)" id="uiType_property(CASECF8)" value="2" type="hidden">
    180. <select name="property(CASECF8)" class="select" style="width:95%" onchange="setDependent(this,false)">
    181. <option value="">-Keine-</option><option value="Ohne">Ohne</option><option value="A1">A1</option>
    182. <option value="A2">A2</option><option value="A3">A3</option><option value="A4">A4</option>
    183. <option value="B1">B1</option><option value="B2">B2</option><option value="B3">B3</option>
    184. <option value="B4">B4</option><option value="C1">C1</option><option value="C2">C2</option>
    185. <option value="C3">C3</option><option value="C4">C4</option><option value="D1">D1</option>
    186. <option value="D2">D2</option><option value="D3">D3</option><option value="D4">D4</option>
    187. <option value="E1">E1</option><option value="E2">E2</option><option value="F1">F1</option>
    188. <option value="F2">F2</option><option value="G1">G1</option><option value="G2">G2</option>
    189. <option value="H1">H1</option><option value="H2">H2</option></select></td></tr>
    190. <tr id="row11_Case Information"><td class="label" width="25%">Garantie:</td>
    191. <td class="element" width="25%"><input name="uiType_property(CASECF107)" id="uiType_property(CASECF107)" value="301" type="hidden">
    192. <input name="property(CASECF107)" type="checkbox"></td><td class="label" width="25%">RMA:</td>
    193. <td class="element" width="25%"><input name="uiType_property(CASECF105)" id="uiType_property(CASECF105)" value="301" type="hidden">
    194. <input name="property(CASECF105)" type="checkbox"></td></tr></tbody></table></div><p></p>
    195. <div id="secDivDescription Information"><table id="secHeadDescription Information" cellpadding="0" cellspacing="0" width="95%">
    196. <tbody width="100%"><tr><td class="secHead">Beschreibung Information</td></tr></tbody></table>
    197. <table id="secContentDescription Information" class="secContent" border="0" cellpadding="0" cellspacing="1" width="95%">
    198. <tbody width="100%"><tr id="row0_Description Information"><td class="label" width="25%">Beschreibung:</td>
    199. <td class="element" width="0%"><input name="uiType_property(Description)" id="uiType_property(Description)" value="3" type="hidden">
    200. <textarea name="property(Description)" id="property(Description)" class="textField" rows="5" cols="5" style="width:100%">
    201. </textarea></td></tr></tbody></table></div><p></p><div id="secDivSolution Information"></div><p></p><div id="secDivComments Information"></div>
    202. <p></p><input name="comboCount" value="2" type="hidden">
    203. <input name="dateFields" value="property(CASECF81)" type="hidden"><input name="focusid" value="property(Subject)" type="hidden">
    204. <input id="currencyFields" value="" type="hidden">
    205. <input name="fieldvalues" value="ownerName##System||ownerId##515225000000050003" type="hidden"><p></p>
    206. <table border="0" cellpadding="0" cellspacing="0" width="95%"><tbody><tr><td align="center">
    207. </td></tr></tbody></table><p></p>
    208. <div id="copy" class="dropDownMenu" style="display:none;"><table border="0" cellpadding="4" cellspacing="0">
    209. <tbody><tr onclick="copyMapLocation( 'Billing to Shipping' )" class="dropDownItem" onmouseover="this.className='dropDownItemOver'" onmouseout="this.className='dropDownItem'"><td nowrap="nowrap">Abrechnung zu Versand</td></tr><tr onclick="copyMapLocation( 'Shipping to Billing' )" class="dropDownItem" onmouseover="this.className='dropDownItemOver'" onmouseout="this.className='dropDownItem'"><td nowrap="nowrap">Versand zu Abrechnung</td> </tr></tbody></table></div><div id="drillDownPtr" style="position:absolute;top:-1000px;left:-1000px;"><img src="/crm/images/spacer.gif" class="red-arrow" height="16" width="19"></div>
    210. <div style="display:none" id="menuincreate"></div>
    211. </form>
    212. <?php
    213. echo $tabs->endPanel();
    214. echo $tabs->startPanel(PFformat::Lang('TASK_RESPONSIBLE'), 'pane2');
    215. ?>
    216. <table class="admintable">
    217. <tr>
    218. <td class="key" width="150" valign="top"><a href="javascript:add_user();"><?php echo PFformat::Lang('ADD_MEMBER');?></a></td>
    219. <td id="user_container"></td>
    220. </tr>
    221. </table>
    222. <?php
    223. echo $tabs->endPanel();
    224. echo $tabs->endPane();
    225. ?>
    226. </div>
    227. </div>
    228. <?php
    229. echo $form->HiddenField("option");
    230. echo $form->HiddenField("section");
    231. echo $form->HiddenField("task");
    232. echo $form->HiddenField("limitstart");
    233. echo $form->HiddenField("keyword");
    234. echo $form->End();
    235. ?>
    236. <div id="user_template" style="display:none">
    237. <?php echo $select_user; ?>
    238. </div>
    Alles anzeigen




    und zwar soll diese php/Java Sript beim Abspeicher immer auf die
    Datenbank abspeichern und bei editieren oder so wieder aufrufbar sein

    wer mir helfen kann wäre toll



    MFg