transmit parameters in websphere portal8.5 - websphere-portal

I have two portlets,in the view.jsp of the first portlet have an form. By clicking submit, parameters can be transmitted to the show.jsp of the second portlet. If submit by 'get', I can receive the parameters. When I submit by "post", the parameter is null.
What can I do? Can I directly redirect to the other portlets by setting the <portlet:URL> in the view.jsp? If not, by using <action:URL> transmit parameters to the processAction of the current portlet, but how to set in the processAction that can redirect to the other portlet?

I am assuming this is a jsr 286 portlet, the reason for this has to do with the two phase of the portlet cycle. In the processaction on the Action response set the methods via setRenderParameter https://portals.apache.org/pluto/portlet-2.0-apidocs/javax/portlet/ActionResponse.html If you want you could get the map from the ActionRequest and then just set it to the action response with setRenderParameters

Related

MS Access - SubForm field pass through

I have a Navigation Form in which the first button is defaulted to show a blank form (Request form) where users will enter information.
There's an option on this Request form that if there are multiple requests under this request, `a box is checked and another form opens and the request number from the Request form is defaulted into the multiple request form's request number field (this is the link).
On the Multiple Request window's ID field in Property Sheet/Data/Default Value I have =[Forms]![frmRequests]![RequestID]
With the Request form open on its own, this works great, but within the Navigation form it doesn't. Is there another layer that I need to add so the default value works in either format? I will be using it in the Navigation form primarily.
The following worked for me.
=Forms!NavigationFormName.NavigationSubformName.Form!RequestID

Angular $http call 'cache' attribute default values and behavior

I am making $http get call in my application. A single page has a need where this call is made thrice asynchronously. When I set cache to true for the http call it works fine ie it does make only one request to the server. Requirement is only to cache them for a shorter period. So I need to make for the entire page one request is hit to server and the subsequent ones are cached and also the next request to the page ie page refresh should make should hit server and cache the fresh response.
For that purpose, I would like to understand what is the default values like how long does the response remains in the $cacheFactory and is the cache type private or public.
I am aware of the alternative solution, what I am looking here is to know what is the time that this get call is cached for?
$http(
{
method: 'POST',
url: '/test/api/component/getItem',
data: {
projectPath : projectPath
}
}
).then(unwrap);

ionic1 wait http response of next view before load it

i'm using ionic to create an application who retrieve data from api through http request when I change view I see the view before the data of the controller totally loaded :
How can I load data of the next controller to only see the final result :
here the button who start the change of view :
<ion-item class="item-thumbnail-left item-icon-right" ng-repeat="inscription in inscriptions" ng-click="loadActiProfil({{inscription}})" href="#/app/activite">
thank you in advance
You shouldn't wait for your HTTP response to start the navigation transition, on a UX perspective. ionic provides a service called $ionicLoading which allows displaying and hiding a spinner (with a black&transparent backdrop). You may use it to make your user understand that he/she's supposed to wait. But enough with my personal opinion.
Regarding your need:
Do not use href to change the current state, you'd rather use ui-sref, as it's supposed to be done using angular-ui router (which is, of course, ionic's router too). NB: ui-sref expects a state name and not an URI (for instance, "app.home").
Use your method loadActiProfil to programmatically switch from the previous state to the new one only once your data is available, thanks to the service $state and its method go (ie: $state.go('app.home') will take you to the state app.home)
TL;DR: if you need to switch the current state programmatically, then use $state.go(stateName), not ui-sref (nor href).

How can I disable "confirm form resubmission" messages?

I have set a search page and it's working properly, But when i click on back in browser then the problem(mention below) appears, So how can i can i disable this.
Confirm Form Resubmission
This webpage requires data that you entered earlier in order to be properly displayed. You can send this data again, but by doing so you will repeat any action this page previously performed. Press Reload to resend that data and display this page.
After processing POST on your page
example.com/mypage.php
use
header('Location: example.com/mypage.php');
In this way the post will not be resubmitted and you wont get the alert from browser.
Use the command line option -disable-prompt-on-repost for Chrome.

CakePHP Logs Me Out Prematurely

I have a CakePHP app that seems to be terminating my session on one specific action. I have a page which, when a link is clicked, launches a Fancybox overlay of the iframe type. In that overlay, the user fills out and submits a form. The form is submitted properly, does its work (including sending an email), loads the success view and lets me close the overlay, but as soon as I try to get to any other page, I'm sent to the login screen to reauthenticate.
The value of my Security.level config setting is medium and my Session.timeout is 120, so that shouldn't be the problem. Anyone have any idea what could be creating this?
Thanks.
is it possible that your ajax calls and redirects are not going to the same place, eg www.site.com and site.com? I have had that before and also kept getting logged out.
So this wasn't fun to track down, but it was me being an idiot. Buried in the code was some early-stage code to refresh user data in the authenticated session that wasn't doing what it should have been doing. It was attempting to update the entire Auth.User object directly (e.g. $this->Session->write( 'Auth', $user )) instead of calling the login method.
Once I changed the Session::write() code to $this->Auth->login( $user ), everything lined up nicely. A nice bit of reference material on this subject at http://milesj.me/blog/read/31/Refreshing-The-Auths-Session.

Resources