URL Request Problem

Hi,
I have a problem. I have a link on a web page that uses java
to open a pop up window of a swf document. In that swf I have a
URLrequest to go to another page. It either opens in itself, or it
opens a new window. Is there a way to make it close the current
window it is in and open the requested page in the parent browser
(the one the pop up came from)?
Thanks

You need to create this functionality in JavaScript that will
allow you communication between parent and child windows.

Similar Messages

  • Tabs and url (request) parameters

    In our application we use tabs (Folders) and in those we got portlets that submit forms using post method. (so it is not shown on the url)
    The problem occures when you change tab. Then all the parameters submitted in the form is shown on the URL. And it seems to add new parameters for all the portlets you are visiting.
    Is it possible to set up portal to (clear) the request when you switch between tabs? Is there any other settings?

    Please post this question to the PDK forum.
    Regards,
    Jerry
    PortalPM

  • Open url request from PopUpManager

    Hi,
    I have a function which opens a new browser window with the result of a URL request (an image). I wonder if  I can do the same but with a window "embedded" in the flash application.
    I saw there is a class called PopUpManager. I understood that I have to create a new component ("popup") with the data for the new window. The problem is that I don't know how to pass the result of the URL request to that popup component.
    Is it possible at all? Is there any other alternative?
    Regards,
    Manolo

    Hi there
    Yep cool with the PopUpManager.centrePopUp.
    As for saving an image.  You can save graphics from Flex by specifiying a rectangular region you want to save.  You can save the selected region out as a jpg or a png using the encoders.  In the example below I have saved out an image. 
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
    <mx:Script>
    <![CDATA[
         import mx.graphics.codec.JPEGEncoder;
         import flash.utils.ByteArray;
         private function saveImage():void {
              var bitmapData:BitmapData = new BitmapData(myImage.contentWidth, myImage.contentHeight);
              bitmapData.draw(myImage);    
              var jpeg:JPEGEncoder = new JPEGEncoder();
              var byteArray:ByteArray = jpeg.encode(bitmapData);
              var file:FileReference = new FileReference();
              file.save(byteArray,'TestImage.jpg');
    ]]>
    </mx:Script>
    <mx:Image id="myImage" x="78" y="33" width="283" height="180" source="http://www.maniacworld.com/amazing-cars.jpg"/>
    <mx:Button x="78" y="236" label="Button" click="saveImage()"/>
    </mx:Application>
    Note you need to be compiling for Flash PLayer 10 in your Flex compiler settings as that allow you to read and write local files.
    Hope it helps
    Andrew.

  • Invoking a method on an URL request?

    i want to invoke a method of a class on an URL request,such that the method can navigate the control to number of other pages .

    Implement a Filter.

  • URL Request  Strings

    Hi,
    I have found information through research about the URL structure for 'passing information between pages' using the p?f=110:100:etc etc.
    We currently employ Apex to provide an insurance quotation engine for a third party and rely on a link on their pages to direct customers to our application.
    My question is...
    Is it possible to include (in a similar manner to say php) request variables - the client requires a 'customer friendly URL' i.e. www.myinsurance.com/apex/travel.insurance as opposed to www.myinsurance/apex/p?f=100:1:::::::::::::::::
    I assume it is not possible to link to an Apex app using www.myinsurance.com/apex/travel.insurance?referrer=STAFFMEMBER
    Please could you explain if it is possible to pass values in a 'customer friendly' URL to an apex application and if so how (or if not prepared to tell me, point me in the right direction of some reference material).
    Regards
    John

    Hi John,
    the Apache module mod_rewrite is the way to go. They can use the URL format they want to have and as soon this URL request goes to your Apache, it will be "translated" to the format APEX requires.
    Patrick
    My APEX Blog: http://inside-apex.blogspot.com
    The ApexLib Framework: http://apexlib.sourceforge.net
    The APEX Builder Plugin: http://sourceforge.net/projects/apexplugin/

  • AIR for iOS URL string problem

    This is a very strange runtime error, that accurs on iOS devices but does not appear, when compiled on the AIR compiler
    I have an input text field movieSearch.pName.text, in which you can enter a value for a JSON URL search.
    On an iOS device it cannot load the URL request. when the text value is passed like this:
    var req:String = movieSearch.pName.text;
    var myRequest:URLRequest = new URLRequest('http://api.themoviedb.org/3/search/movie?query=%22+'+req+'+%22&api_key=****************');
    I have tried writing a value manually in the code, and this works fine:
    var myRequest:URLRequest = new URLRequest('http://api.themoviedb.org/3/search/movie?query=%22+matrix+%22&api_key=****************');
    or
    var req:String = "Matrix";
    var myRequest:URLRequest = new URLRequest('http://api.themoviedb.org/3/search/movie?query=%22+'+req+'+%22&api_key=****************');
    These 2 examples work, but the first example does not. Why is it so? Does anyone have a clue?

    A sample project is something like this:
    import flash.data.*;
    import flash.text.*;
    import flash.display.*;
    import flash.events.*;
    import flash.net.*;
    import com.adobe.serialization.json.JSON;
    var movieSearch:TextField = new TextField();
    var resultField:TextField = new TextField();
    var searchButton:SimpleButton = new SimpleButton();
    addChild(movieSearch);
    addChild(resultField);
    addChild(searchButton);
    searchButton.addEventListener(MouseEvent.CLICK, simpleJSON);
    function simpleJSON(e:MouseEvent) {
                        var i:int;
                        var req:String = movieSearch.text;
                        var myRequest:URLRequest = new URLRequest('http://api.themoviedb.org/3/search/movie?query=%22+'+req+'+%22&api_key=******************* ******');
                        var myLoader = new URLLoader();
                        myLoader.addEventListener(Event.COMPLETE, onload);
                        myLoader.load(myRequest);
                        function onload(evt:Event):void {
                                  var myData:Object = JSON.parse(myLoader.data);
                                  var resultCount:int = myData.results.length;
                                  for (i=0; i < myData.results.length; i++) {
                                            resultField.appendText(myData.results[i].original_title);
    I am using Flash Professional CS5.5 with AIR 3.2, and tested the compiled project on iPhone 4 with iOS 6.1
    The result field does not show anything on the device, but shows everything correcly in Flash.

  • URL cache problem in UCM and sitestudio

    Hi ,
    We have created Metadata Field : xPageName, and have configure an entry in config.cfg as SSUrlFieldName=PageName, Scenario is we have assigned abc.html to xPageName for a content item on suppose /oracle/cms1/ URL, by mistake we assigned abc.html to xPageName to another content item on suppose /oracle/cms2/ URL. Problem is abc.html is registered with two content item and on two URL's, and now we have changed it for /oracle/cms2/ URL to xyz.html, but when we hit /oracle/cms2/abc.html it is also served with blank page. Please suggest how we can get away with this ASAP.
    Thanks,

    That is definitely a limitation that each custom page name must be unique.
    If think what you are saying is that you have resolved this issue but the URL is still taking you to the wrong page...
    THis stuff is cached IIRC in some js files in the weblayout
    Have you tried, clearing browser cache, recreating the navigation in SS Designer, or restarting UCM and webserver?

  • Sending URL requests

    I keep seeing large spikes in my swf trying to send a url request. But these only appear in Firefox in OSX. I haven't tested in windows. Chrome (pepper and regular) and safari both work fine.  Also see large spikes when using extrnal interface. Any ideas on how to work with these and perhaps some best practices?
    Function
    Total Time (ms)
    Sending URL requests
    84
    95%
        URL request timestamp
        URL request: <some_url>
        URL request ID: 25
    Function
    Self Time (ms)
    Total Time (ms)
                    ExternalInterface.call <static> (flash.external)
    0
    0%
    97
    100%
                        ExternalInterface._evalJS <static> (flash.external)
    97
    100%
    97
    100%
    -nate

    Michael, thank you for your detailed answer. I accept your suggestion about the issue related to sandbox api in IE9. Reducing concurent requests helped and was necessary for smooth flow of my app. However I believe this is an issue that should be targeted on flash player level not app code... I will consider filing a bug
    I strongly disagree with your conclusion:
    At the end of the day, if you can only make 6 or so concurrent requests at the same time, it's pointless to try and send more - either reduce the number of requests (preferably), or wait for the first batch to finish before sending some more.
    http://forums.adobe.com/message/5714849#5714849 ... 92 requests
    http://www.adobe.com/cz/ 117 requests
    http://facebook.com 200 requests
    http://maps.bing.com 100 requests in fullscreen mode when zooming, all of them concurrent ... this is basicaly what my app does

  • New URL Request (_blank) Without Address or Scroll Bars Present

    Can anybody please give me the AS3 code to open a new window (URL Request) without it displaying the address or scroll bars? I want to have a text link in a flash scene like "Click Here" that opens a new blank window (600 x 400) with a new URL without displaying any address or scroll bars. Is this possible? Any help would be greatly appreciated. Thanks.

    flash.net.navigateToURL(new URLRequest("about:blank"))

  • Encoding the URL request

    Could you plz assist me how encode the URL request that is getting from the client.The query about discarding a session is as follows
    (1)What will happened when employing invalidate() method of a session.
    (2) What is the distinguishing of invalidate() and logout if both has performed that all of the user's session will have been expired if we invoke anyone

    Making some guesses here.
    The invalidate() method does what it says: it invalidates the session. Most HttpSessionMethods will throw an IllegalStateException if called on an invalid session.
    There is no method or event that causes a "logout". It's something you have to do programmatically using the invalidate() method. Or the session could timeout in which case also it becomes invalid ( which is basically done by the container as opposed to you calling invalidate() )
    About URL encoding: do you mean URL rewriting which appends a session id to the URL to be used in case cookies are disabled? Then you need encodeURL() and encodeRedirectURL(). Working with the session with rewriting of URLs is exactly the same for you ( in your code ) as it is normally.
    If you mean making a safe URL, you need URLEncoder: http://java.sun.com/j2se/1.4.2/docs/api/java/net/URLEncoder.html
    I hope I got something right here.

  • How to tell which country a URL request is generated?

    Hi,
    We need to know the geographical location of a user at least the country information for our application. I learn the country where a URL request is generated can be detected. A package, called CountryHawk, on Jason Hunter's Servlet.com site demonstrated the function. Can someone teld me how it is implemented.
    Thanks in adnvance.
    v.

    What I find is where the country of my internet connection provider's location address.Yes, that is what you will get.
    I try the ip2country.com site. They get the country right, but not anything more, that is to say the site doesn't have my province/state right.Yes, that is true also. The IP addresses are given out to the Internet Service Providers in a controlled way, which is why those databases can be created. But the ISPs are free to give out their assigned blocks of IP addresses in any way they choose, and the people who make those IP-to-country database have not yet interviewed the many thousands of ISPs to see exactly how they did it. And I don't expect anybody will be doing that anytime soon.

  • Losing info after a & on a String url = request.getParameter("refurl");

    Hi...
    Wnen I am passing information.... like this....
    http://127.0.0.1:8080/forumoracle/forum_login.jsp?refurl=http://127.0.0.1:8080/forumoracle/forum_view.jsp?catid=2&threadid=4
    I seem to be losing the information after the amperstand.. and not sure why..
    String url = request.getParameter("refurl");
    So when I print out the url string.. I only get this...
    http://127.0.0.1:8080/forumoracle/forum_view.jsp?catid=2

    You can't redirect to a new window from the server end
    you have to make the decision at the client when you
    click the link. All a web server does is receives a
    request, and sends back a response.
    The decision about where to display that response is
    up to the browser. (ie does it replace current
    content, put into a new window etc etc)
    You can use the target attribute on links and forms to
    specify it from your HTML page, but once the
    link/button is clicked you are committed.While this is all true for JSP that doesn't care about the UI, JavaScripting makes it possible to open new windows, but it is lacking in some respects for my use. I am facing two issues:
    a)how to give a URLEncoder.encode string to JavaScript's window.open() legibly, and
    b) how to close a window opened with a JavaScript after a download of a file
    In both instances, there is ergonomics.

  • Help please  Url request variables problem

    I have a problem .I am trying to load some data from a php
    script . I want to send some variables to php .
    public function
    LoadXML2(nume:String,c1:String,c2:String,c3:String):void {
    var loader2:URLLoader = new URLLoader();
    loader2.addEventListener(Event.COMPLETE, OnComplete2);
    var request:URLRequest = new URLRequest(nume);
    var variables2:URLVariables = new URLVariables();
    variables2.c1 =c1;
    variables2.c2 =c2;
    variables2.c3 =c3;
    request.data = variables2;
    request.method = URLRequestMethod.POST;
    try {
    loader2.load(request);
    } catch (error:Error) {
    trace("Unable to load requested document.");
    private function OnComplete2(event:Event):void {
    var loader2:URLLoader = URLLoader(event.target);
    logInAnunt=loader2.data;
    The problem is that in firefox works , but in IE dont :
    in Ie it appears a box:
    ReferenceError: Error #1065: Variable URLLoaderDataFormat is
    not defined.
    at medieval::DataLoader/::OnComplete2()
    at
    flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at flash.net::URLLoader/flash.net:URLLoader::onComplete()
    I want to mention that this error appears when I add
    urlVariables
    what should I DO??

    loader2.data is undefined in onComplete2.

  • How to set attributes in new connection url request

    Hi, I'm an italian programer and I'm sorry for my english. Using the follow java code, I include an jsp page in to other jsp page. I use struts framework too. The problem is that the page includes do not has on the request object the same attributes of the calling page. for example the page authentication.jsp page has on self request object the attributes "org.apache.struts.message", but the page includes drop this attribute on the request object. In other words the page includes does not inherit the request attributes of the calling page.
    How to do to resolve this problem.
    Many thanks to your availability to my problem.
    By
    Antonio (Italy)
    String urlString = null;
    URL url = null;
    ServletContext sctx = null;
    HttpServletRequest request = (HttpServletRequest) pageContext.getRequest();
    try {
    if(strContextRoot==null) strContextRoot = "";
    // Set up a URLConnection to read the requested resource
    Map params = request.getParameterMap();
    params = updateParametersMap(newParam,params);
    if (!strContextRoot.equals(""))
    sctx = pageContext.getServletContext().getContext(strContextRoot);
    else
    sctx = pageContext.getServletContext();
    urlString = NewcomputeURL_old(strContextRoot,pageContext, forward, href, page, params, anchor, false);
    url = new URL(RequestUtils.requestURL(request), urlString);
    } catch (MalformedURLException e) {
    RequestUtils.saveException(pageContext, e);
    throw new JspException(messages.getMessage("ServletInclude: include.url", e.toString()));
    URLConnection conn = null;
    try {
    // Set up the basic connection
    conn = url.openConnection();
    //pageContext.
    conn.setUseCaches(true);
    conn.setRequestProperty("method","POST");
    conn.setAllowUserInteraction(true);
    conn.setDoInput(true);
    conn.setDoOutput(true);
    if ((conn instanceof HttpURLConnection)
    && urlString.startsWith(strContextRoot)
    && (request.getRequestedSessionId() != null)
    && request.isRequestedSessionIdFromCookie()) {
    StringBuffer sb = new StringBuffer("JSESSIONID=");
    sb.append(request.getRequestedSessionId());
    conn.setRequestProperty("Cookie", sb.toString());
    // Connect to the requested resource
    conn.connect();
    } catch (Exception e) {
    RequestUtils.saveException(pageContext, e);
    throw new JspException(
    messages.getMessage("ServletInclude: include.open", url.toString(), e.toString()));
    // Copy the contents of this URL
    StringBuffer sb = new StringBuffer();
    try {
    BufferedInputStream is = new BufferedInputStream(conn.getInputStream());
    InputStreamReader in = new InputStreamReader(is); // FIXME - encoding
    char buffer[] = new char[BUFFER_SIZE];
    int n = 0;
    while (true) {
    n = in.read(buffer);
    if (n < 1) break;
    sb.append(buffer, 0, n);
    in.close();
    out.write(sb.toString());
    } catch (Exception e) {
    RequestUtils.saveException(pageContext, e);
    throw new JspException(
    messages.getMessage("ServletInclude: include.read", url.toString(), e.toString()));

    Please have a look at this.
    What you are doing is creating a new http request using a url connection!! That's why the request attributes does not show up, it's not the same request!
    If you want to include the response of another resource, use a request dispatcher to include it. Eg.
    // in servlet
    request.getRequestDispatcher("/index.jsp").include(request, response);
    // or in jsp
    <jsp:include page="/index.jsp" />

  • URL  access problem

    I have JDK1.5.0_06 (build 1.5.0_06-b05) on my PC with Windows 2000 OS and when I am running the following code
    public class A
    public static void main(String[] args)
    try{
    URL u = new URL("http://www.aaaa.com/xxxx%F3P%F3Rblabla");
    ur = u.openConnection();
    ur.getInputStream().close();
    }catch(Exception e){
    e.printStackTrace();
    }finally{
    the following exception appears:
    java.lang.IllegalArgumentException
         at sun.net.www.ParseUtil.decode(ParseUtil.java:179)
         at sun.net.www.ParseUtil.toURI(ParseUtil.java:253)
         at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:738)
         at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:669)%
         at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:913)
    I think that the problem is using "%F3" in the URL. But, I have a site where this code appears in the URL and from IE it works fine.
    If somebody knows how to solve please give me a sign.
    If I use 1.5.0_02 (build 1.5.0_02-b09) it works fine.
    Best regards,
    Leo

    Are regular users able to access Files? Is the user seeing the SSO Login page or do they just get a HTTP 500?
    Please have the user delete all their cookies and temporary internet files and try it again.
    In addition please see if the users request makes it to the Files server by checking the HTTP access_log and the Files servlet's application.log.
    Hope that helps,
    -sancho
    I have a user who is having trouble accessing the
    administrator and files URL. He is using the same URL
    as other administrators but keeps getting HTTP 500
    error or page can not be displayed.
    The problem appears to be with his browser settings
    in IE version 5.5. He has reinstalled IE and is still
    getting this error. He can use someone else's PC and
    is able to log in using the URLs but on his PC he
    keeps getting an error.
    Does anyone have any suggestions where to start
    looking for a problem resolution?
    Thanks for any help...

Maybe you are looking for

  • Has the intelligent Migrate Comments feature disappeared in Acrobat X?

    One feature our organization uses on a daily basis is the Migrate Comments tool in Acrobat 9 and versions prior. Rather than just importing the comments to the matching position in the new file, Migrate intelligently reads the text structure of the d

  • New notebook~ "Fails to login"

    We received our new Acer Notebook on Friday. We had no problems setting it up and getting online. It worked up until yesterday afternoon. When we try you login we get the following message: "The User Profile service failed to login. User profile cann

  • IPhone 4S - Outgoing call no audio

    Picked up a Verizon iPhone 4S - 32GB and on about 1 in 10 calls I get no outbound audio when dialing.  Call shows the timer counting as if the call is progressing but absolutely no ring back and cannot hear the party on the other end when they answer

  • [Games] exult + soundpacks

    [edit] changed the soundpacks to use the more detailed roland recordings and added digital music package [/edit] Here are the PKGBUILDs for exult. I'm amazed no one did it earlier! use the appropriate sound packs for the game(s) you are going to inst

  • Xerox Workcentre 7328 Ps

    We had to unplug our computers, the telephone and the wi-fi connector for we were replacing out counter top and had to make room for our devices.  Now everything is plugged back in and for some reason our Xerox Workcentre 7328 Ps won't allow us to pr