مجرد اضافة بسيطة ومهمة وذلك للتأكد من عمل حذف و اختيار ( الكل او الجزء )
PHP كود :
if(isset($_POST['check_all'])) if (isset($_POST["slct"]) && count($_POST["slct"])!=0) for ($i=0; $i<count($_POST["slct"]); $i++) if (is_numeric($_POST["slct"][$i])) echo $_POST["slct"][$i].'<br>';
سنقوم باعطاء لكل شاك بوكس قيمة ستكون ( id )
مثال
ساستخدم 2 كتجربة فقط
//------------------------------------------------------------------------- function con(){return new mysqli('localhost', 'root', '', 'delphi');} //-------------------------------------------------------------------------
تم المشروع جزئيا للتجربة حمل هذا http://sourceforge.net/projects/xampp/
ضع ملفات php في C:\xampp\htdocs\exemple_02
افتح phpmyadmin وانشا قاعدة بيانات باسم delphi
تم ارفاق الجداول
هناك نقوصات كثيرة لاكن الفكرة تمت
PHP كود :
procedure TForm1.FormCreate(Sender: TObject); var test:TDynamicSA; list:TStringList; begin
test:=split(IdHTTP1.Get('http://127.0.0.1/exemple_02/active.php?cmnd&hdd=123456'),'|'); if Length(test)>0 then begin if test[0]='MSG' then MessageBox(0, PWideChar(test[1]), PWideChar(test[2]), +mb_ok); if test[0]='ACT' then MessageBox(0, PWideChar(test[1]+' Until '+test[2]), 'WoooW', +mb_ok); if test[0]='DES' then begin MessageBox(0, PWideChar('You cannot access because : '+test[2]), PWideChar(test[1]), +mb_ok); Caption:='<Démo>' end; end;