FABridge And Javascript object

I am using the flex Ajax Bridge to communicate with my flex
application. I have a javascript method that is receiving an
object. I want to send this object to my flex application. Only
thing is I am not sure what to set the in put param for my
actionscript function. The sayHello method will not get called. I
am not sure how to handle this when result is javascript object.
Any help would be greatly appreciated.
i..e
--Javascript
function helloActionScript(result) {
var flexApp = FABridge.flash.root();
flexApp.sayHello(result);
--ActionScript
//This method is not getting called from the preceding
javascript.
public function sayHello(result: Object): void {
Alert.show("Hi");
Thanks!!

I am using the flex Ajax Bridge to communicate with my flex
application. I have a javascript method that is receiving an
object. I want to send this object to my flex application. Only
thing is I am not sure what to set the in put param for my
actionscript function. The sayHello method will not get called. I
am not sure how to handle this when result is javascript object.
Any help would be greatly appreciated.
i..e
--Javascript
function helloActionScript(result) {
var flexApp = FABridge.flash.root();
flexApp.sayHello(result);
--ActionScript
//This method is not getting called from the preceding
javascript.
public function sayHello(result: Object): void {
Alert.show("Hi");
Thanks!!

Similar Messages

  • Sending and parse javascript object variable to java variable

    can anyone help me how to send and parse javascript object variable from client to java variable on servlet. Here is what i mention about:
    suppose i have object variable var_js with it's properties:
    <script>
    var var_js = {
    id: 'var_js1',
    name: 'this is var javascript',
    allow_value_type: ['int', 'string', 'object']
    </script>
    /* after processing javascript object to java var, that i hope you guys may help me, it's java var (var_java) become something like*/
    var_java.id = "var_js1";
    var_java.name = "this is var javascript";
    var_java.allow_value_type = {"int", "string", "object"}

    You could have this html page:
    <html>
    <script>
    var var_js = {
    id: 'var_js1',
    name: 'this is var javascript',
    allow_value_type: ['int', 'string', 'object']
    function send()
    document.getElementById("id").value = var_js.id;
    document.getElementById("name").value =var_js.name;
    document.getElementById("allow_value_type").value =var_js.allow_value_type;
    document.form.submit();
    </script>
    <form name="myForm" action="http://localhost:8080/servlet/myServlet" method="post" >
    <input id="id" type="hidden" value="">
    <input id="name" type="hidden" value="">
    <input id="allow_value_type" type="hidden" value="">
    <input id="cmdGo" type="button" value="Button" onClick="send()">
    </form>
    </html>
    Then have a servlet like this:
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    public class myServlet extends HttpServlet {
    public void doPost( HttpServletRequest request,
    HttpServletResponse response )
    throws ServletException, IOException
    String id = request.getParameter("id");
    String name = request.getParameter("name");
    String allowed_value_type = request.getParameter("allowed_value_type");
    Var_java var_java = new Var_java(id,name,allowed_value_type);
    //and have you java object
    class Var_java
    String id;
    String name;
    String allowed_value_type;
    public var_java(String id,String name,String allowed_value_type)
    this.id=id;
    this.name=name;
    this.allowed_value_type=allowed_value_type;
    well...something like that i think.
    Hope it helps.

  • How to manipulate a javascript object in java?

    Hi, I am fiddling with the java scripting interface. As I understand the rhino engine is packaged with the jdk but what I don't understand is how does one reconcile the objects one gets from their engine (e.g. sun.org.mozilla.javascript.internal.ScriptableObject) versus the ones in the rhino api (e.g. org.mozilla.javascript.ScriptableObject)?
    Is the one in the jdk heavily modified or wrappered up to suit their javax.scripting interface?
    More specifically, how do I manipulate javascript objects from java?
    e.g. suppose I have this java code:
    ScriptEngineManager mgr = new ScriptEngineManager();
    ScriptEngine js = mgr.getEngineByName("js");
    jsEngine.eval("var foo = { x : 1, y : 'hello', z : false };");
    Object o = jsEngine.get("foo");Now o is instanceof sun.org.mozilla.javascript.internal.NativeObject, which is a subclass of a bunch of other classes in the s.o.m.j.i namespace. Being internal I can't use these directly.
    Looking at the Rhino API obviously you normally get a org.mozilla.javascript.ScriptableObject and can call the .get() .getIds() methods. But I don't know how to translate the objects I am getting in my actual java code which uses the jdk engine into org.mozilla.javascript objects.
    Is this even possible? Am I misunderstanding something completely? Should I just be using the rhino js jar and not the javax.scripting interface? If so, for what reason is the javax.scripting interface implemented?

    Assuming that you DO want a deep copy, begin with a constructor that takes another hand.
    public Hand( Hand h ) { ...Then for each instance variable, within that constructor:
    this.instVar0 = h.instVar0;
    this.instVar1 = h.instVar1;
    . . .And last, for every reference, make sure there is a constructor (or copy method for arrays) that itself makes a deep copy:
    this.ref0 = new Ref0Type( h.ref0 );

  • How to find out the PATTERN, GRADIENT and BRUSHED objects?

    How to find out the PATTERN, GRADIENT and BRUSHED objects information in illustrator active document file. And also how to find the CMYK and RGB color information in illustrator file through javascript. Could you please provide any examples.

    I tried using the below code. But for both "cmyk" and "grayscale" pattern it gives only CMYK. Kindly check and advise.
    Code:
    var docRef = activeDocument;
    for(var i=docRef.inkList.length-1;i>=0;i--){
      var inkRef=docRef.inkList[i];
      var inkRefName=inkRef.name;
      alert(inkRefName);
      alert(inkRef.inkInfo.kind);
    Thanks for looking into this.

  • Using CSS and Javascript to display a div with flash in it, mozilla reloads the flash file!

    I am using CSS and Javascript to display a div with an
    embedded flash object in it. Mozilla Firefox reloads the flash file
    when the div is displayed! (I dont want this to happen, as it's
    unexpected functionality, my expectation would be that the flash
    file would not change it's state at all, and would remain in
    whatever state it was left in.)
    I was wondering if anyone has come across this issue and is
    there something I can do to prevent this from occurring?
    To be more specific, I have a single HTML page with 8 flash
    files embedded in it (yeah I know, it's a bit much). I am then
    using CSS and Javascript to display (via a numbered link (with an
    id)) an equivalent numbered div tag containing the flash file.
    Mozilla Firefox reloads the flash object that is in the div.
    Internet Explorer will not do this and will instead, load the flash
    object only upon initial view of the flash object. All subsequent
    links (in IE) will NOT reload the flash object on the page. I'm
    guessing this is some kind of difference in the flash player as an
    Active X object and the plugin, or is it just IE being clever? Or
    am I way off?
    Anyway, here is the code...

    I am using CSS and Javascript to display a div with an
    embedded flash object in it. Mozilla Firefox reloads the flash file
    when the div is displayed! (I dont want this to happen, as it's
    unexpected functionality, my expectation would be that the flash
    file would not change it's state at all, and would remain in
    whatever state it was left in.)
    I was wondering if anyone has come across this issue and is
    there something I can do to prevent this from occurring?
    To be more specific, I have a single HTML page with 8 flash
    files embedded in it (yeah I know, it's a bit much). I am then
    using CSS and Javascript to display (via a numbered link (with an
    id)) an equivalent numbered div tag containing the flash file.
    Mozilla Firefox reloads the flash object that is in the div.
    Internet Explorer will not do this and will instead, load the flash
    object only upon initial view of the flash object. All subsequent
    links (in IE) will NOT reload the flash object on the page. I'm
    guessing this is some kind of difference in the flash player as an
    Active X object and the plugin, or is it just IE being clever? Or
    am I way off?
    Anyway, here is the code...

  • HELP PLASE ! JavaBean and Javascript in frames :)

    Hello,
    First please excuse me for my bad english I'm French think you in advance for your patience and your help ! :)
    To resum the problem :
    I have 2 frames, a menu frame and a main frame
    I use a javabean wich is saved in application variable.
    When the pages of main frame use the javabean there is no probleme.
    BUT when menu frame calls pages of main frame it don't restore the javabean, it looks like je page called by menu frame, which operates on the javabean, wasn't called, and the changes I do in this page aren't saved
    Menu frame uses javascript to calls main frame pages so I think the problem is conjonction of frame and javascript.
    But I have no choice because it's volonty of my boss, so please help me ! :)
    More precisly :
    the javabean : NavigationBean
    page frame menu : menu_page.jsp
    main pages which use javabean : pageA.jsp, pageB.jsp, pageC.jsp
    pageA.jsp has reference on pageB.jsp which has reference on pageC.jsp
    Traitement of the javabean NavigationBean in pageA.jsp, pageB.jsp and pageC.jsp :
    <jsp:useBean      id="gestionNavigation"
              class= "NavigationBean"          
              scope="application">                         
    </jsp:useBean>
    <jsp:setProperty      name="gestionNavigation"
                   property="request"
                   value="<%=request%>" />     
    (it needs response and request to run)
    <jsp:setProperty      name="gestionNavigation"
                   property="response"
                   value="<%=response%>" />
    <jsp:setProperty      name="gestionNavigation"
                   property="pageActuelle"
                   value="<%=urlActuelle%>" />
    (it saves in NavigationBean object the url where user is)
    In pageA I clean all NavigationBean so all pages saved are deleted
    if user go DIRECTLY on pageA.jsp, all is ok :
    user go on
         pageA -> pageB -> pageC
    and NavigationBean save
         pageA -> pageB -> pageC
    That's good ! :)
    BUT if after user go on menu frame it's wrong !
    user go on
         pageA -> pageB -> pageC -> menu_page.jsp -> pageA -> pageB
    BUT NavigationBean save
         pageA -> pageB -> pageC -> pageB
    instead of
         pageA -> pageB
    To resume, for NavigationBean when user go directly on main pages there is no problem, but when it uses menu frame it doesn't save that user go on pageA
    I clean NavigationBean on pageA, but instead of this problem it doesn't clean and retrieve old datas
    It looks like that when user uses menu FRAME it uses an old NavigationBean object, but when it go directly on pages of main frame it runs !
    And I use scope application so don't understand, I have tried session scope but no change :(
    I have tried using "response.encondeURL" but no change
    Think you in advance for your help, and good luck from Paris for all New York people ! :)
    David

    It sounds like what might be happening is when the user goes 'back' to the menu, they're not requesting the page from the server. So, they're either getting the old page cached by the browser. Maybe. If you reload the menu page manually, does it work?

  • Unable to update rating (rating column) on host document using JavaScript Object Model API inside sharepoint hosted apps

    Hi Everyone,
    We are developing SharePoint hosted apps for Office 365, for that we are going
    to implement document rating functionality inside Sharepoint app. The host web contain document library (“Documents”) and from apps we need to rate each document. The rating functionality working fine with CQWP in team site  using
    JavaScript Object Model API.
    But the same code is not working inside apps and giving error:-
    If we are using app context than error will be:-
    "List does not exist.
    The page you selected contains a list that does not exist.  It may have been deleted by another user."
    And for Host context than error will be:-
    "Unexpected response data from server."
    Please help on this
    Please see below code..
    'use strict';
    var web, list, listItems, hostUrl, videoId, output = "";
    var videoLibrary = "Documents";
    var context, currentContext;
    var lists, listID;
    var list, parentContext;
    var scriptbase;
    (function () {
        // This code runs when the DOM is ready and creates a context object which is 
        // needed to use the SharePoint object model
        $(document).ready(function () {
            hostUrl = decodeURIComponent(getQueryStringParameter("SPHostUrl"));
            context = SP.ClientContext.get_current();      
            SP.SOD.executeFunc('sp.js', 'SP.ClientContext', sharePointReady);
        function sharePointReady() {
            scriptbase = hostUrl + "/_layouts/15/";
            // Load the js files and continue to the successHandler
            $.getScript(scriptbase + "SP.Runtime.js", function () {
                $.getScript(scriptbase + "SP.js", function () {
                    $.getScript(scriptbase + "SP.Core.js", function () {
                        $.getScript(scriptbase + "reputation.js", function () {
                            $.getScript(scriptbase + "sp.requestexecutor.js", execCrossDomainRequest);
        //Query list from hostweb
        function execCrossDomainRequest() {       
            //Load the list from hostweb
            parentContext = new SP.AppContextSite(context, hostUrl);
            web = parentContext.get_web();
            list = web.get_lists().getByTitle(videoLibrary);
            context.load(list, 'Title', 'Id');
            var camlQuery = new SP.CamlQuery();
            camlQuery.set_viewXml('<View><Query><OrderBy><FieldRef Name="Modified" Ascending="FALSE"/></OrderBy></Query><RowLimit>1</RowLimit></View>');
            listItems = list.getItems(camlQuery);        
            context.load(listItems);
            context.executeQueryAsync(onQuerySucceeded, onQueryFailed);
        //Process the image library
        function onQuerySucceeded() {       
            var lstID = list.get_id();
            var ctx = new SP.ClientContext(hostUrl);       
            var ratingValue = 4;
            EnsureScriptFunc('reputation.js', 'Microsoft.Office.Server.ReputationModel.Reputation', function() {      
            Microsoft.Office.Server.ReputationModel.Reputation.setRating(ctx, lstID, 1, ratingValue);       
            ctx.executeQueryAsync(RatingSuccess, RatingFailure);
        function onQueryFailed(sender, args) {
            alert('Failed' + args.get_message());
        function failed(sender, args) {
            alert("failed because:" + args.get_message());
        function RatingSuccess() {
            alert('rating set');
            //displaystar();
        function RatingFailure(sender, args) {
            alert('Rating failed : : ' + args.get_message());
        //Gets the query string paramter
        function getQueryStringParameter(paramToRetrieve) {
            var params;
            params = document.URL.split("?")[1].split("&");
            for (var i = 0; i < params.length; i = i + 1) {
                var singleParam = params[i].split("=");
                if (singleParam[0] == paramToRetrieve) return singleParam[1];
    Thanks & Regards
    Sanjay 
    Thank you in advance! :-)
          

    Hi,
    According to your post, my understanding is that you want to update list column in SharePoint hosted apps using JavaScript Client Object Model.
    Based on the error message, it seems not retrieve the list object in context. I suggest you debug the code step by step using Internet Explorer Developer Tools to
    find the problem.
    Here are some demos about using JavaScript Client Object Model in SharePoint hosted app:
    http://blogs.msdn.com/b/officeapps/archive/2012/09/04/using-the-javascript-object-model-jsom-in-apps-for-sharepoint.aspx
    http://sharepoint.stackexchange.com/questions/55334/how-to-access-list-in-sharepoint-hosted-app
    http://www.dotnetcurry.com/showarticle.aspx?ID=1028
    Best regards
    Zhengyu Guo
    TechNet Community Support

  • Use of HTML and Javascript within EP

    I have a newbie question:
    I have several HTMl documents with javascript embedded like e.g. various calculators we use on the current website.
    If I want to migrate these html sources to EP content, what can I best do than?
    I assume that all existing html and javascript renders as normal without too many development involved?
    Is there a good example how-To source which I can use to demonstrate this?
    many thanks for your help

    Hi,
    Well there are two options:
    <b>1) If you are interested to make the portal component and then use in Portal.
    2) If you want to use your earlier HTML document as it is inside the portal.</b>
    In case 1 you need to make the Portal objects and then make a portal project. You can use javascript in that as well.
    In case 2 you can directly make the URL iView of the HTML document and then view it from the portal. Well this is not a good way of using your javascript. Personally I suggest you to go for Portal Project.
    I hope this help you!!
    Regards
    Pravesh
    PS: Please consider reewarding points.

  • Can not JavaScript objects in Java project

    Hi guys and girls,
    I have CMP managed java project that I am trying to create a menu for. Each time I create a new javascript object I am getting the error "objectname is undefined". Below is a code snipset followed by the error message I get when I try displaying the jsp.
    <head>
         <link rel="stylesheet" href="menu.css">     
         <script language="javascript" type="text/javascript" src='menu.js'></script>     
         <script language="javascript" type="text/javascript" src='menu_items.js'></script>     
         <script language="javascript" type="text/javascript" src='menu_tpl.js'></script>
    </head>
    <body leftmargin="15" rightmargin="15" marginheight="15" marginwidth="15" bgcolor="white">
    <script language="javascript">               
              new menu (MENU_ITEMS, MENU_POS);
         </script>     
    </body>
    The error message is 'menu' is undefined.
    I supspect that the src=menu.js reference is not working but I am not sure how I can change this. Any help would be appreciated.

    Hi guys and girls,
    I have CMP managed java project that I am trying to
    create a menu for. Each time I create a new javascript
    object I am getting the error "objectname is
    undefined". Below is a code snipset followed by the
    error message I get when I try displaying the jsp.
    <head>
    <link rel="stylesheet" href="menu.css">
    <script language="javascript" type="text/javascript"
    src='menu.js'></script>
    <script language="javascript" type="text/javascript"
    src='menu_items.js'></script>
    <script language="javascript" type="text/javascript"
    src='menu_tpl.js'></script>
    </head>
    <body leftmargin="15" rightmargin="15"
    marginheight="15" marginwidth="15" bgcolor="white">
    <script language="javascript">
    new menu (MENU_ITEMS, MENU_POS);
    </script>
    </body>
    The error message is 'menu' is undefined.
    I supspect that the src=menu.js reference is not
    working but I am not sure how I can change this. Any
    help would be appreciated.
    Hi
    I didn't get a clear picture of your question. Any way try this.
    1) make sure that menu.js is in the same directory as your jsp file. if it is not give the proper path.
    2) what is this MENU_ITEMS, and MENU_POS. instead of it try with integers

  • Accessing JavaScript objects via JSObject

    The jaws.jar file, which contains JSObject was included in the sdk directory up to j2sdk1.4.1_05 (in j2sdk1.4.1_05\jre\lib). However, apparently this JAR file is not included in versions 1.4.2 and later versions of the sdk. So I have the following questions:
    1. Is JSObject becoming obsolete?
    2. If this is the case, what mechanism is replacing JSObject to access JavaScript objects from Java?
    Thanks for your help.

    JSObject is included in plugin.jar for Java 1.5 and 1.6, which can be found in the jdk folder unter \jre\lib
    It can be still included as usual, with:
    import netscape.javascript.JSException;
    import netscape.javascript.JSObject;
    I hope this helps.

  • Problem of Java - javascript and javascript - java communicate of same obje

    Hi all,
    I have met a great problem in program an applet! I have tried to communicate between java and javascript and javascript and java in the same page by using jsobject. However, problem occur. It is not a problem to call javascript from java by using jsobject. However, javascript call java by using document.object.function has problem. It cannot find out the object in IE. I have followed the webpage show in java, but the browser still prompt me the object called client not find. Please help!! My html code is shown as follow:
    <HTML>
    <HEAD>
    <TITLE>Alva Final Year Project Demo</TITLE>
    </HEAD>
    <Script language="javaScript">
    function show(html){
    layer.innerHTML = html;
    function getResponse(response){
    alert("response: " + response);
    document.client.getJSCommunicate();
    </Script>
    <BODY>
    <DIV id="layer" style="position:absolute">
    <H2>Secure Server</H2>
    <HR>
    <!--"CONVERTED_APPLET"-->
    <!-- CONVERTER VERSION 1.0 -->
    <OBJECT id="client" classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
    WIDTH = "800" HEIGHT = "400" codebase="http://java.sun.com/products/plugin/1.1.1/jinstall-111-win32.cab#Version=1,1,1,0">
    <PARAM NAME = CODE VALUE = "ClientPart.class" >
    <PARAM NAME="SCRIPTABLE" VALUE="true">
    <PARAM NAME="MAYSCRIPT" VALUE="true">
    <PARAM NAME="type" VALUE="application/x-java-applet;version=1.1">
    <COMMENT>
    <EMBED type="application/x-java-applet;version=1.1" java_CODE = "ClientPart.class" NAME = "client" WIDTH = "800" HEIGHT = "400" pluginspage="http://java.sun.com/products/plugin/1.1.1/plugin-install.html"><NOEMBED></COMMENT>
    </NOEMBED></EMBED>
    </OBJECT>
    <!--
    <APPLET CODE = "ClientPart.class" WIDTH = "800" HEIGHT = "400" NAME = "clientPart" >
    </APPLET>
    -->
    <!--"END_CONVERTED_APPLET"-->
    </DIV>
    </BODY>
    </HTML>
    Thanks your kindly help.
    Alva

    Everthing looks fine to me from here, you should be able to just call the java function direct such as
    document.myAppletObj.doMethod();
    I think your problem could be that your object is called "client". IE can get funny about names, it didn't like me calling a method delete()!!
    Try adding something else to the name such as "my_client", and see if this works any better.
    Chris

  • Javascript : Object Expected error.

    Hi,
    I have used a javascript in my sharepoint portal. Whenever I open the page in IE, it shows me "Object Expected" error at Line:1 Char:1.
    Here is the code snippet that I have used:
    $(document).ready(function() {
     // Create an array of unique user id's scraped from img rel tags
     var IDs = new Array();
     $('.author-image').each( function() {
      if($.inArray($(this).attr('rel'),IDs ) == -1) {
       IDs.push($(this).attr('rel'));
     // When sp.js is loaded run our function to display images
     ExecuteOrDelayUntilScriptLoaded(function() {DisplayAuthorImage(IDs);}, 'sp.js')
    I am not able to figure out what is causing this error?

    Sorry but you are in the wrong forum.
    Try posting in the Web forum.
    http://forums.asp.net/130.aspx/1?HTML+CSS+and+JavaScript
    That is the forum for IIS based JavaScript delivered to a browser.
    Here is a possibility:
    http://stackoverflow.com/questions/312150/where-should-a-script-block-with-jquery-code-be-placed-on-an-asp-net-mvc-master
    be sure jquery is being copied to target and specified correctly in the 'src=' statement on the <script.. tag
    ¯\_(ツ)_/¯

  • Creating javascript objects in LCD 8.2

    Hi,
    a year ago there was a posting "creating javascript objects in LCD 7.0.1 " http://forums.adobe.com/message/1360679#1360679
    I tried this in Designer 8.2 and failed! Does anyone know why?
    I set up a scriptObject "mydate" which contains:
    function createDate(sDay, sMonth, sYear) {
        xfa.host.messageBox( sDay + "." + sMonth + "." + sYear);
        var oDateObject = new Object();
        oDateObject .day = sDay;
        oDateObject .month = sMonth;
        oDateObject .year = sYear;
        return oDateObject;
        } // function createDate()
    function setToCurrentDate () {
        var dateToday = new Date();
        this.day = (dateToday.getDate() < 10) ? "0" + dateToday.getDate() : dateToday.getDate();
        this.month = (dateToday.getMonth() < 10) ? "0" + dateToday.getMonth() : dateToday.getMonth();
        this.year = 1900 + dateToday.getYear();
        } // setToCurrentDate ()
    function display() {
        xfa.host.messageBox("Display: " + this.day + "." + this.month + "." + this.year);
        return "" + this.day + "." + this.month + "." + this.year ;
    function display2() {
        with (this) xfa.host.messageBox("Display: " + day + "." + month + "." + year);
    In my field's Enter-Event I wrote:
        var dateToday = mydate.createDate("01","01","2000");
        dateToday.display2();
        xfa.host.messageBox(dateToday.display());
        dateToday.setToCurrentDate();
    The problem is, that I get the message: "dateToday.display2 is not a function"
    I cannot call any of dateToday's methods.
    Actually I would have expected this message, as there is no scriptObject with the name "dateToday". But apparently that worked in version 7.0.1.
    How can we use some object oriented programming with Adobe's JavaScript?
    How can we use objects in the scriptObjects?
    Did anyone find that out already? I'd appreciate every hint and help!
    Ulrich

    Hi Ulrich
    I don't think the Designer Script Objects are implemented as JavaScript objects but I think you can acheive what you want with something like;
    form1.#variables[0].myDateScript - (JavaScript, client)
    function myDate(sDay, sMonth, sYear)
        this.day = sDay;
        this.month = sMonth;
        this.year = sYear;
        this.setToCurrentDate = function(oDateObject)
             this.day = (dateToday.getDate() < 10) ? "0" + dateToday.getDate() : dateToday.getDate();
             this.month = (dateToday.getMonth() < 10) ? "0" + dateToday.getMonth() : dateToday.getMonth();
             this.year = 1900 + dateToday.getYear();  
         this.display = function()
             return "" + this.day + "." + this.month + "." + this.year ;
    function newMyDate(sDay, sMonth, sYear)
         return new myDate(sDay, sMonth, sYear);
    So you could then reference the myDate object with;
    xfa.host.messageBox(myDateScript.newMyDate(
    "01","01","2000").display());
    John Brinkman has a post on this at http://blogs.adobe.com/formfeed/2009/09/script_objects_deep_dive.html and before that post my previous method was discribed in this forum at http://forums.adobe.com/message/1964601
    Also attached is my sample to test the code above.
    Bruce

  • HTMLEditorKit : How you handle FRAMES, IFRAMES and JAVASCRIPT

    Hi all,
    Currently im using the HTMLEditorKit to parse through the HTML page. Obviously its easier when the elements are on the body of the page. But what if the page has frames,iframes or javascript and i want to extract links that these elements reference to. How do i do it? I know some of you would recommend my class to extend the parsercallback class. But is there a way for example i can use 3 or even 4 different iterators each pointing to the different elements ?
    and lets say if i reference to a SCRIPT tag of the HTML, how do i extract the possible URLs in it. Same goes for iFrames and JavaScripts. Can anyone please help me with this ?

    Tim,
    The form action needs to be the page URL. The INPUT fields/objects of your form will be sent as parameters when the form is submitted. These parameters can be read by your portlet by using the parameter passing PDK services. It is recommended to use qualified parameters in case the portlet that reads the parameters is the same as the one that has submitted them.
    As far as I remember the parameter passing sample portlet contains similar code to what you're looking for.

  • RichTextEditorProxy JavaScript Object

    Hi,
    I'm trying to use the 'Image Upload URI' feature of the messageRichTextEditor component but, to do so, Developers Guide says I need to call a javascript function insertImageTag('myImage.jgp') present in the RichTextEditorProxy javascript object. The problem is that I can't get a RichTextEditorProxy instance so I can call the insertImageTag function on it. Looking at the RichTextEditor.js library I found the RichTextEditorProxy object definition but I can't call his constructor sucessfully:
    function RichTextEditorProxy(a0,a1,a2,a3,a4)
    Does anyone knows how to use it?
    I've also already searched the forum and there's only one topic about it, but with no answers:
    How to upload image using MessageRichTextEditor?
    Please let me know if anyone has made it work. Thanks.

    Hi,
    I find out how to create the RichTextEditorProxy instance:
    var yorRteId_rte = new RichTextEditorProxy('DefaultFormName','yorRteId','R',1000,'IE_Win');
    Now I've got a Javascript issue: Inside the RichTextEditorProxy object there's some calls to document.getElementById() and the problem is that there's no instance of RichTextEditorProxy because this code runs on the new window created to do the image upload popup.
    I wonder if there's a way to make the newly created document child of the document where the instance of RichTextEditorProxy lives. Anyone? :)

Maybe you are looking for