php - Isset expression error -


I originally coded a code that populates a list of categories from my database, then you You can choose to remove it. / p>

I have a problem with a deleted code that does not work due to error:

  Fatal error: can not use isset () on the results of the expression (You can use "zero! == expression" instead) F: \ xamppnew \ htdocs \ 650032 \ admin \ delete.php in the line   

its Because of the line is:

  if (isset ($ _ POST ['delete_id'] & amp; amp; amp; amp; nbsp; ($ _ POST ['delete_id'])) {  

deletecategory.php

  & lt; h3 & gt; remove category & lt; / h3 & gt; & lt ;? ph P $ result = mysql_query ("Select * FROM range");? & Gt; & lt; table & gt; & lt ;? php while ($ row = mysql_fetch_array ($ result)):? & Gt; & lt; tr Id = "& lt ;? php echo $ row ['category_id'];? & Gt;" gt; & gt; & lt; td & gt; & lt ;? php echo $ row ['category_Name'];? & Gt; & Lt; / TD & gt; & lt; TD & gt; & lt; button class = "del_btn" rel = "& lt ;? php echo $ row ['id'];? & Gt;" & gt; delete & lt; / button & gt; & lt; / td & gt; & Lt; / TR & gt; & Lt ;? Php timeline; ? & Gt; & Lt; / Table & gt; & Lt; Script & gt; $ (Document) .ready (function () {$ ('del_btn'). Click (function () {var del_id = $ (this) .attr ('rel'); $ .post ('delete.php', {delete_id: del_id}, function (data) {if (data == 'true') {$ ('#' + del_id) .remove ();} other {alerts ('could not be deleted!')}}} );});}); & Lt; / Script & gt;   

delete.php

  & lt ?? Php if (isset ($ _ POST ['delete_id'] & amp; below! ($ _ POST ['delete_id']))) {$ delete_id = mysql_real_escape_string ($ _ POST ['delete_id']); $ Result = mysql_query ("delete the category WHERE id id =". $ Delete_id); If ($ result! == wrong) {echo 'true'; }}? & Gt;    

you have not left this ) : if (isset ($ _ POST ['delete_id']) & amp; empty! ($ _ POST ['delete_id'])) --- ---

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -