Javascript inputtype=image disable

Im trying to disable a submit button with an image on it like
forn name = Increase
input type = "image" name="image" src="image.gif"
//this is the javascript code
out.println("function newResourceDisab(){");
out.println("alert(\"Resource addition button disabled hopefully\");");
out.println("frm=document.forms['Increase']");
out.println("frm.image.disabled=true");
out.println("}");
typical input disabling doesnt seem to work for images.
anybody got any ideas.

There's no relation between JavaScript and Java, despite the similarity in names.
That said, the easiest way to do something like this is to add an onClick( ) argument to the input tags, or alternatively, the image tags. The onClick will call your Resource Disabling function.
I'm not sure if you simply want to toggle a value within the form, or if you actually want to submit the form while at the same time overriding the default behavior of expanding the image.

Similar Messages

  • Passing Javascript Enabled or Disabled value in a custom tag

    Hi,
    In my JSP I am using a custom tag.
    This custom tag is having one attribute called status(whose value will be jsenabled means true or jsdisabled means false) depending on the browser's javascript enabled or disabled
    How can i find the value of javascript enabled or javascript disabled and set the value of the attribute status in my jsp.
    This is the custom tag
    <t:tab summary="tabs" url="/services/eservicepac/registrationprocess/process.wss" tabNames='<%=tabList%>' currentTab="<%=currentTab%>" zone="WWW_ZONE" fetchText="false" status=" "
    </t:tab>
    The value of this attribute status=" " should be the value of jsenabled or disabled.
    Since the user can visit any page at any time, the jsenabled value is not maintained in session or request, so i can't take from session or request also.
    As this is urgent,
    --I am expecting the reply                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Hi Merlin,
    In addition to what was written above, you must make sure that you tell your web application to run as a JSP 2.0 web application.
    You do this by defining your web.xml a little differently. Like this at the top:
    <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee web-app_2_4.xsd">
    That should be what you need to get it working correctly.
    Damian Sutton

  • Accidently installed NoScript, can't get rid of it and JavaScript has been disabled even though it says it's enabled - help!

    I accidently installed NoScript when trying to remove adverts/pop-ups. Now it's causing problems on various sites I regularly use and I can't get rid of it. It doesn't show up on Tools/Add- ons so I can disable and JavaScript has been disabled, even though it shows as 'Enabled'.
    Help would be appreciated.

    The usual method for uninstalling extensions and themes is by using the Add-ons manager for your Mozilla application, as follows.
    # Click "Tools -> Add-ons
    # Click on the Extensions or Themes button on the top.
    # Click on the extension or theme you want to uninstall.
    # Click Uninstall.
    # Restart your Mozilla application.

  • Fail to update flash,gets "JavaScript is currently disabled in your browser and is required to download Flash Player" However javascrip is available and enabled

    Firefox requests to update Flash but the download fails over and over initialization at 50%.
    also in one trial of download i recieved the message: "JavaScript is currently disabled in your browser and is required to download Flash Player". But i checked and it is enabled.
    I am stuck with Flash In FF and moving to Chrome.

    Your system details list doesn't show that the Shockwave Flash plugin is installed and enabled.
    *https://support.mozilla.org/kb/Troubleshooting+plugins
    Latest Flash player versions here:
    *http://www.adobe.com/special/products/flashplayer/fp_distribution3.html
    You can verify on the Adobe Flash Players Test Page that the Flash plugin is working and which version you have.
    * http://www.adobe.com/software/flash/about/
    If you use extensions (Firefox/Tools > Add-ons > Extensions) that can block content (e.g. Adblock Plus, NoScript, Flash Block, Ghostery) then make sure that such extensions aren't blocking content.
    Start Firefox in <u>[[Safe Mode|Safe Mode]]</u> to check if one of the extensions (Firefox/Tools > Add-ons > Extensions) or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox/Tools > Add-ons > Appearance).
    *Do NOT click the Reset button on the Safe Mode start window.
    *https://support.mozilla.org/kb/Safe+Mode
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

  • Javascript - added images display as grey boxes

    I am attempting to add an Image to an InDesign document via a javascript that I am executing via the RunScript() soap method of InDesign Cs4 server.  The script I am using to add an image is something similar to this:
    var imageFile = File("//c/images/animage.pdf");
    var imageGraphic = myDocument.pages.item(0).place(imageFile, null, imageLayer);
    imageGraphic = imageGraphic[0];
    var imageFrame = imageGraphic.parent;
    imageFrame.geometricBounds = [IMAGE_TOP_Y, IMAGE_TOP_X, IMAGE_BOTTOM_Y, IMAGE_BOTTOM_X];
    imageFrame.fit(FitOptions.proportionally);
    imageFrame.fit(FitOptions.frameToContent);
    The script adds the image correctly, but when I pull up the document with InDesign, the Images are displayed as grey boxes.  I am able to fix this within InDesign designer by manually setting the "Display Performance" to "High Quality" through the menus, but I need to handle this via the script run on the server.  I attempted to update the script to the following:
    var imageFile = File("//c/images/animage.pdf");
    var imageGraphic = myDocument.pages.item(0).place(imageFile, null, imageLayer);
    imageGraphic = imageGraphic[0];
    var imageFrame = imageGraphic.parent;
    imageFrame.geometricBounds = [IMAGE_TOP_Y, IMAGE_TOP_X, IMAGE_BOTTOM_Y, IMAGE_BOTTOM_X];
    imageFrame.fit(FitOptions.proportionally);
    imageFrame.fit(FitOptions.frameToContent);
    //HERE IS THE NEW LINE
    imageFrame.localDisplaySetting = DisplaySettingOptions.HIGH_QUALITY;
    This script runs without problems within the CS4 ExtendScript Toolkit on my local pc.  However, when I run the script against the InDesign CS4 server, I get the following error:
    Error Number: 55
    Error String: Object does not support the property or method 'localDisplaySetting'
    Does anyone have any advice on how I should proceed?  My main goal is to have the image display correctly without the grey box.

    hello, I'm running into the same issue with image showing up as grey boxes. I'm updating documents via (JS) scripts by placing new images into rectangles. When I open up that document after the script saves it, all I see is a grey box until I change the Display Performance to Typical (or higher). In my scripts, I can change the localDisplaySettings to DisplaySettings.TYPICAL, but it only works locally, when I run this on the server it fails because it says DisplaySettings is undefined. I'm wondering if this is a server setting, and if so, how I might be able to change it?
    Thanks in advance!

  • How can I use external CSS, JavaScript and Images in PeopleSoft Portal?

    I am developing a website and I need to put my CSS, JavaScript and IMG files in a folder on the server that can be used by my HTML objects.
    Where should I put the images? How do I get the HTML objects can read these images?
    I've tried several things like:
    <link rel="stylesheet" href="<%=psCtxPath%><%=psHome%>\MyStyleSheet.css" rel="stylesheet" type="text/css">
    <link rel="stylesheet" href="\portal\MyStyleSheet.css" rel="stylesheet" type="text/css">
    <link rel="stylesheet" href="\ps\images\portal_pa\MyStyleSheet.css" rel="stylesheet" type="text/css">

    Hi Jim!
    Yes, I am using the HTML Object Application Designer. Below is my HTML:
    <html>
    <head>
      <title>My Portal</title>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <script language='javascript' src='/jscript/MyJavaScript.js'></script>
      <link rel="stylesheet" href="/css/MyStyleSheet.css" rel="stylesheet" type="text/css">
    </head>
    <body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" bottommargin="0" rightmargin="0" marginwidth="0" marginheight="0">
    <img src="/images/MyLogo.jpg"/>
    </body>
    </html>
    But, the portal is not reading my css, js and images.

  • JAVASCRIPT ERROR WHEN DISABLED THE WELCOME AREA

    Hi sdn,
    I have modified our portal design. I set the welcome area and the logo area to the value none. Now I am always getting a javascript error when I call the side in my browser.
    I get the message that an object is missing and the browser can not set the focus to an element ==> because I have disabled two areas of the portal header.
    I have recognized this problem in all portal releases from EP6SP2 to EP6SP9.
    What can I do to prevent these error messages?

    I think this issue is fixed by this note : 798647. Suggested to go with latest hotfix.

  • Need a little JavaScript help with disabling a select list in a tabular frm

    Hello Folks
    Here's the scenario.
    I have a tabular form which, subject to the setting of one Select List, I want to disable/enable another.
    I have got this far and it will disable a text item but not a select list..
    This is in the HTML header section for the page...
    <script type="text/javascript">
    function test(pThis)
    var currIndex = $('select[name="'+pThis.name+'"]').index(pThis);
    if (pThis.value=='2') {
    $('input[name="f02"]')[currIndex].style.backgroundColor = "LightGrey";
    $('input[name="f02"]')[currIndex].disabled=true;
    The report region is defined as...
    SELECT apex_item.text(1, ir.iot_rebate_type_id) iot_rebate_type_id
    ,apex_item.select_list_from_lov_xl(2,ir.rebate_currency,'LOV_CURRENCY_CODES') rebate_currency
    FROM iot_rebate ir
    WHERE ir.iot_agreement_id = :P303_IOT_AGREEMENT_ID
    The iot_rebate_type_id column has an Column Element Attribute set to...
    onchange="javascript:test(this);"
    As I say, if I define the rebate currency as a text item, the javascript works fine.
    Can anyone offer any suggestions?
    Many thanks
    Simon
    Application Express 4.0.2.00.07

    Simon Gadd wrote:
    Hi Vikram.
    That's great.
    I have the relevant items being set to diabled & grey (and also the reverse of this if the driving select list is changed back).
    As this is being used in a Tabular form, if I am calling pre-existing records which should be displayed with two of the select lists disabled, can you point me in the right direction to show the relevent select lists as disabled when the records are returned from the database?If you are using apex_item API set the disabled property into p_attributes parameter conditionally using a case statement in you sql statement
    Another option is you can use some javascript to loop through the tabular form array that runs on the onload of the page.
    Finally, if some columns are disabled, this invaludates the MRU process on the page. Is there a way to submit the page with some fields in the disabled state?Do that as per Roel's suggestion for this issue.
    Any input/pointers much appreciated.
    Simon

  • Slow loading images disabling adjustments Aperture 2

    I am running Aperture 2.1.4 on an intel mac having just moved over from a powerpc. Its a big leap in many ways.
    In aperture all the images load so much faster than before except the adjustments are disabled and the heading at the top of the Adjustments sidebar is that the "Image Loading"
    The image is actually visible in the main window so its just the image levels box which is blank along with the above message.
    Any inputs? Is there anyone out there still using Aperture 2.1.4?
    Many thanks
    Anthony

    Is aperture 3 a new application rather than an upgrade to 2? I'm wondering how smooth a transition the process will be.
    Aperture 3 is an update from Aperture 2 which means it is a separate application then needs to be purchased through the Mac App Store. Upgrades (going from version 2.4 to 2.5 for example) are free but updates (going from version 2 to version 3) need to be paid for.
    Again good luck and take your time, document everything you do. Also have backups especially of things like the Aperture librssry, things that cannot be replaced.
    regards

  • Dreamweaver Freeze JavaScript (F6) is disable! Why?

    I will freeze JavaScript in my htm file in live view Dreamweaver but this command is disable.

    @e1a1s,
    Those options will be enabled only when you select "Hide Live View Displays".
    Since the Element displays in Live View are also JS implementations, disabling or freezing Javascript before hiding them would have yielded undesirable results. Hence, this solution.
    Hope this helps,
    Subhadeep

  • Javascript firing on disabled button also

    Experts,
    I have a button which has a clientListener who fires a javascript. The js disables the button. So far its good, but the issue happens if the user clicks on the disabled button the js fires again.
    <af:commandToolbarButton text="Update Profile" id="ctbUpdate"
                                           actionListener="#{viewScope.CustomerProfilePageBean.toggleButton}"
                                           binding="#{viewScope.CustomerProfilePageBean.updateButton}">
                    <af:clientListener method="toggleSplitter" type="click"/>
                  </af:commandToolbarButton>Isnt this strange ?
    thnks
    Jdev 11.1.1.5

    It is not strange but stupid...
    Also happens when using af:showPopupBehaviour with type="click"...
    I would like to know where is it useful to work like this???
    Try using type="action" on af:clientListener, it works for af:showPopUpBehaviour...

  • CS3 Fit Image disabled?

    Photoshop CS3, with all updates.
    Menu File - Automate - Fit Image has suddenly become grayed out.
    Grayed out in menu, and batches fail to access it too.
    Actions fail with log entry:
    Error: The command "Fit Image" is not currently available. (-25920)
    Sometimes the error is command "Canvas Size" is not currently available (also in the batch).
    Batches earlier today using it worked OK, no problems until now.
    Have tried rebooting, still grayed out and does not work.
    Any clues to fix it are appreciated.

    Never mind, I think this was a different error. I made a new Action and it worked OK. I think it actually was a file open failure. The first Action had been recorded opening RAW, and I was trying to open TIF now, and it appears that the batch Override Action File Open stuff failed to know how to switch.

  • What is the JavaScript function to disable the auto-loop feature for the Video Player Plus Widget?

    I have PDF's with links to streaming video that play using the native video skin. The Video Player Plus widget auto starts the video by default.
    Can someone please tell me how to disable this???
    Thanks in advance!

    And in CS4, if there is not a matching Preset, you can choose the Desktop Preset, which will allow you to customize nearly every attribute to match your source footage. The name is a bit of a misnomer, but has been around for a long time. I would have called it the "Custom Preset," but Adobe never called.
    Good luck,
    Hunt
    PS - I just learned something new about CS5 from Curt, because of your question - thanks!

  • Aperture exported images disable Photoshop CS2 Variations command

    Your comments and help please:
    From Aperture, I choose a file to modify in Photoshop CS2. I Export the file to Photoshop. Photoshop opens with the image exported. Unfortunately, the Variations command is grayed-out. I tried TIFF and PSD exports from Aperture. Variations, of course, works when I open the same image from the Finder. Has anyone else had this problem? Thanks for your help, Nate

    I'm fairly sure that the Variations adjustment doens't work with 16-bit images - when you use 'open in an external editor' Aperture passes a 16-bit file to that editor.
    Ian

  • JavaScript Fade Images

    Hey all, I'm trying to get an image to fade into another image AND also to get them to display:inline and in the center...How should I go about doing this??

    OK so I thought everything was going smooth and i got everything working how i wanted BUT for some reason Firefox is the only browser where the links at the top get shifted to the right and I have no clue how to fix it for Firefox only?? every other browser besides Firefox works fine, Safari, Opera, Chrome they all work even Internet Explorer to an extent
    my HTML is
            <div id="cf1">
                <p style="text-align:center"><a href="index.html"><img class="bottom" src="images/png/Reel-Over.png"><img class="top" src="images/png/Reel.png"></a></p>
            </div>
            <div id="cf2">
                <p style="text-align:center"><a href="media.html"><img class="bottom" src="images/png/Media-Over.png"><img class="top" src="images/png/Media.png"></a></p>
            </div>
            <div id="cf3">
                <p style="text-align:center"><a href="contact.html"><img class="bottom" src="images/png/Contact-Over.png"><img class="top" src="images/png/Contact.png"></a></p>
            </div>
            <div id="cf4">
                <p style="text-align:center"><a href="about.html"><img class="bottom" src="images/png/About-Over.png"><img class="top" src="images/png/About.png"></a></p>
            </div>
    my CSS is
    #cf1 { margin-top:-12px;
        clear:both;
        position:relative;
        float:left;
        left:0%;
        height:90px;
        width:200px;
    #cf2 { margin-top:-12px;
        position:relative;
        float:left;
        left:1%;
        height:90px;
        width:200px;
    #cf3 { margin-top:-12px;
        position:relative;
        float:left;
        left:6%;
        height:90px;
        width:200px;
    #cf4 { margin-top:-12px;
        position:relative;
        float:left;
        left:10%;
        height:90px;
        width:200px;
    #cf1 img, #cf2 img, #cf3 img, #cf4 img {
        position:absolute;
        -webkit-transition: opacity .35s ease-in-out;
        -moz-transition: opacity .35s ease-in-out;
        -o-transition: opacity .35s ease-in-out;
        -ms-transition: opacity .35s ease-in-out;  
        transition: opacity .35s ease-in-out;
    #cf1 a:hover img.top, #cf2 a:hover img.top, #cf3 a:hover img.top, #cf4 a:hover img.top {
        opacity:0;
    Nevermind I guess I figured it out i added left:5%; right below position:absolute;
    I read Firefox does not use position:absolute; accordingly with the other browsers...
    Message was edited by: Keldoun

Maybe you are looking for