0
$status="<div  class='analysis btn btn-secondary' ><a id='$poupid' href='javascript: void 0;' onclick='open_windowdata(this.href,this.id)' style='color:white'><strong>Not attempted</strong></a></div>";

just need to replace onclick with below code

onclick="$('#wiewans_<?php echo $slno; ?>').slideToggle('slow')"

facing with trouble quote any one help us thanks

Gajendra
  • 25
  • 7

1 Answers1

1

Escape the double quotes with ' \ ', this way they wont get parsed as end of the string :

$status = "<div class='analysis btn btn-secondary'><a id='$poupid' href='javascript: void 0;' onclick=\"$('#wiewans_<?php echo $slno; ?>').slideToggle('slow');\" style='color:white'><strong>Not attempted</strong></a></div>";
Alfons McBobr
  • 89
  • 1
  • 2