Forum Stats

  • 3,728,037 Users
  • 2,245,522 Discussions
  • 7,853,258 Comments

Discussions

Jquery modal causing page protection violation error

William Wallace
William Wallace Member Posts: 89
edited May 2013 in APEX Discussions
Hi,

I am using Apex 4.2.2.

I tried to move away from built in plugin template as it doesnt work in IE 7 (this is in theme 26) to use Jquery modal.


In page Header: I put the following code:
<link rel="stylesheet" href = "http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/themes/redmond/jquery-ui.css" type="text/css" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.js"> </script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/jquery-ui.js"> </script>

<script language="JavaScript1.1" type="text/javascript">

	$( function() 
	{
	   $('#modal-1').dialog(
	   {
			width: 500,
			height: 400,
			modal : true ,
			autoOpen : false ,
			buttons  : {
							Cancel 	: function() {
										closeDialog('modal-1');
									}
					    }

	   });
	});
</script>

<script language="JavaScript1.1" type="text/javascript">		
	function openDialog(pId)
	{
		var dialog_id = '#'+pId;
		$(dialog_id).dialog('open');
		
	}
	function closeDialog(pId)
	{
		var dialog_id = '#'+pId;
		$(dialog_id).dialog('close');
	}

</script>
Then created my Modal region (type HTML + No Template) with a

Region Header: <di v id="modal-1" style="display:none;">
Region Footer: </di v >

Modal comes up fine as soon as I run the page and submit or click on any other links on tabs (to go to other page) I am getting the error:
Session state protection violation: This may be caused by manual alteration of protected page item P17_RELEASE_ID. If you are unsure what caused this error, please contact the application administrator for assistance.

Contact your application administrator.
I know this is the main cause because if I remove the code from page header, the error dissappears.

Anyone encountered this? Please share how you fixed it (if you were able to ) thanks.

Edited by: William Wallace on 29/05/2013 21:47

Answers

  • William Wallace
    William Wallace Member Posts: 89
    Even More bizzare, when I check the apex_workspace_activity_log table/view, It shows the error to be in


    Error Message:
    Session state protection violation: This may be caused by manual alteration of protected page item P17_RELEASE_ID. If you are unsure what caused this error, please contact the application administrator for assistance. Contact your application administrator.

    Error On Component Type: APEX_APPLICATION_AUTH

    Error On Component Name: CUSTOM_AUTHENCATION
  • Tom Petrus
    Tom Petrus Member Posts: 1,151 Gold Trophy
    So are you sure that there is not other code influencing this page item? Do you get the error when you run the page and immediately submit (just let the page load, do nothing but clicking the button)?
    Tom Petrus
  • Pars
    Pars Member Posts: 630 Gold Badge
    i think put first three line of above code in template header before </head> and remaining in page header try it...
    Pars
  • William Wallace
    William Wallace Member Posts: 89
    No luck. Had to delete and add the region then worked.

    Dunno what went wrong.
  • Pars
    Pars Member Posts: 630 Gold Badge
    refer this denes kubicek application

    http://apex.oracle.com/pls/apex/f?p=31517:257:103099252668070::NO
    Pars
This discussion has been closed.