Display the JS popup script to show a comment.

If the $file parameter is empty, then the home page is assumed. The defaults for the window are 400px by 400px.

For the comment link popup to work, this function has to be called or the normal comment link will be assumed.

Signature

comments_popup_script( $width = 400, $height = 400, $file = '' )
width
 (int) Optional. The width of the popup window. Default 400.
Default: 400
height
 (int) Optional. The height of the popup window. Default 400.
Default: 400
file
 (string) Optional. Sets the location of the popup window.
Default: ''

Return

(void)

Source

function comments_popup_script( $width = 400, $height = 400, $file = '' ) {
	global $wpcommentspopupfile, $wpcommentsjavascript;

	if (empty ($file)) {
		$wpcommentspopupfile = '';  // Use the index.
	} else {
		$wpcommentspopupfile = $file;
	}

	$wpcommentsjavascript = 1;
	$javascript = "<script type='text/javascript'>\nfunction wpopen (macagna) {\n    window.open(macagna, '_blank', 'width=$width,height=$height,scrollbars=yes,status=yes');\n}\n</script>\n";
	echo $javascript;
}
WP Trac GitHub

Link here