Location: PHPKode > scripts > Right Click Pop-up > right-click-pop-up/example2.html
<html>
	<script>
		function callMe() {
			alert('hello');
		}
	</script>
	<style>
		html {
			font-family: Verdana;
		}
	</style>
<?
	require_once('class.rightclick.php');

	$divName = 'hiddenDivToOpen';
?>
	<body>
		<div>
			<span
				id="init_<?=$divName?>"
				style="border: 2px solid #000000; padding: 3px;"
			>
				Right Click Here
			</span>
		</div>
<?
		$rc = new RightClick();
		$rc->CreateLink('Add', 'add', 'callMe()', 'javascript');
		$rc->CreateLink('Edit', 'edit', 'callMe()', 'javascript');
		$rc->CreateLink('Delete', 'delete', 'example.html', 'link');
		$rc->GenerateRightClick($divName);

		$divName = 'anotherhiddenDivToOpen';
?>
	<br />
	<br />
	<br />
		<div>
			<span
				id="init_<?=$divName?>"
				style="border: 2px solid #000000; padding: 3px;"
			>
				Right Click Here
			</span>
		</div>
<?
		$rc->NewRightClick();
		$rc->CreateLink('Add', 'add', 'callMe()', 'javascript');
		$rc->CreateLink('Delete', 'delete', 'example.html', 'link');
		$rc->GenerateRightClick($divName);
?>
	</body>
</html>
Return current item: Right Click Pop-up