Determine if the user is in edit mode (on the page)

My page parameters get lost every time I go into edit mode on the page. I need to know when the user is in edit mode (vs view mode) so that I can submit an event to repost the parameter back to the page. The only difference I can find between edit and view mode is the parameter: "_mode=16" gets attached to the end of the url. Yet, when I try this code:
String pageParamMode= (String)request.getParameter("_mode");
out.print("pageParamMode = " + pageParamMode + "<br>");
It returns null. I need a reliable way to tell which mode the user is in. Could someone please help?
Thanks,
Cory

Got it figured out. I can get the page url then check it for the existance of the string '_mode=16". If it exists, then we are in edit mode. Else in view mode. Here is a bit of code: <p>
PortletRenderRequest pReq = (PortletRenderRequest) request.getAttribute(HttpCommonConstants.PORTLET_RENDER_REQUEST); <br>
String url = pReq.getRenderContext().getPageURL();<br>
String mode = url.indexOf("_mode=16") > 0 ? "Edit" : "View"; <br>
Works like a charm :-)

Similar Messages

  • While in Edit Mode in Moodle - page content does not render at all, but I am able to display the underlying HTML code. Happens only after upgrade to Firefox 11.0.

    While in edit mode in the Moodle course management system, the Page Content window should display the page as it will appear to the user. If you click on the "Edit" button, you are able to view the HTML code for the page. However, when you return to the normal display mode, the page is blank. This has occurred after the upgrade to Firefox 11.0. Page is normally rendered in Internet Explorer.

    A possible cause is security software (firewall,anti-virus) that blocks or restricts Firefox or the plugin-container process without informing you, possibly after detecting changes (update) to the Firefox program.
    Remove all rules for Firefox and the plugin-container from the permissions list in the firewall and let your firewall ask again for permission to get full unrestricted access to internet for Firefox and the plugin-container process and the updater process.
    See:
    *https://support.mozilla.org/kb/Server+not+found
    *https://support.mozilla.org/kb/Firewalls
    See also:
    *http://kb.mozillazine.org/Error_loading_websites
    *https://support.mozilla.org/kb/Error+loading+web+sites

  • Bug or feature : Using portlets with edit mode on a page in the portal

    Hi,
    i am using Workshop 8.1 (GA release july) and i have discovered a bug (or a
    feature) with respect to the beta version.
    i have created a simple portlet with a view mode and an edit mode. When i
    place the portlet on the very first page of a one book portal, it works
    perfectly. However, i have a book with three pages and placed the portlet on
    the second page. Now when i put the portlet in edit mode, by clicking the
    edit button, i am directed to the first page of the portal and the portlet
    will not show.
    Inspection learned that the URL generated for the edit button, didn't
    contain the _pagelabel parameter. When i added the parameter manually it
    works fine.
    A final remark is that the buttons in the titlebar have no icons the browser
    can load.
    hope someone can help me out,
    Lodewijk

    Can you please post this question to weblogic.developer.interest.portal
    newsgroup.
    Thanks
    "Lodewijk Spijker" <[email protected]> wrote in message
    news:3f165945$[email protected]..
    Hi,
    i am using Workshop 8.1 (GA release july) and i have discovered a bug (ora
    feature) with respect to the beta version.
    i have created a simple portlet with a view mode and an edit mode. When i
    place the portlet on the very first page of a one book portal, it works
    perfectly. However, i have a book with three pages and placed the portleton
    the second page. Now when i put the portlet in edit mode, by clicking the
    edit button, i am directed to the first page of the portal and the portlet
    will not show.
    Inspection learned that the URL generated for the edit button, didn't
    contain the _pagelabel parameter. When i added the parameter manually it
    works fine.
    A final remark is that the buttons in the titlebar have no icons thebrowser
    can load.
    hope someone can help me out,
    Lodewijk

  • Page content disappears in Edit mode - Custom Master Page

    Hi All,
    Below are the two issues I have with my master page.
    1) I am facing the strange issue with the pages created using custom page layouts and custom master page.
    In browse mode, everything looks perfect and as expected. But when I try to edit the same page, all content disappears as soon as page ribbon appears. When I click back on Browse tab on the ribbon, everything appears back normally. 
    2) Also When I apply my custom master page as site master for Publishing site it works I can see all my custom design and layout. But when I apply same for team sites, unless I change system master to my custom master page, it doesn't reflect my design.
    Does anyone face this issue before? 
    Thanks
    Pramod
    Pramod

    Once in edit mode, are you able to view the page's source and do a "Find" on a certain keyword that should normally appear in your page's content? Is it there?
    I'm trying to determine if its a server side issue with your master page's code that's causing the content not to be sent back across the wire to the user or if the content is there but just not properly presented. Thanks
    Nikolas Charlebois-Laprade Microsoft Certified Professional & Software Engineer http://nikcharlebois.com

  • Vertical scroll in edit mode and Open a complete row in edit mode

    Any help would be greatly appreciated , if someone can share their knowledge/experience on the following two items ..
    1. Can you please help on how to implement vertical movement in  data grid (Using the up and down arrows to move from an editable cell in one row to the same column in the previous/next row) just like using tab to move in the same row, from one editable cell to the next? Please note we are able to implement the user navigation in editable mode in  one   single row and the user tabs from left to right and the cells  render in edit mode without issues.We are trying to implement this in a vertical fashion to have the  datagrid cell rendered in edit mode from one column  in one row to the same column in the next row ..We are tryinng to simulate the same user feel when a user navigates in Excel sheet.
    2.       Is there a way to open a cell in Flex datagrid edit mode by default? I understand that the itemrenderer for that column could be a text input but I don’t always want that cell to be in an edit mode. When the user comes to the screen, it needs to be in an edit mode just as a visual indicator that it can be edited. Once the user finishes editing, the cell can use the default itemrenderer. In other words, how do we fire an edit event on a cell when it is rendered for the first time by default? In nut shell how do you open all fields in the entire row  in edit mode  (rather opening one cell at a time it in edit mode as the user tabs from left to right ) 

    Can anyone help answering the question we have ? Any pointers would be greatly appreciated

  • How To Force Open Document In Edit Mode From Code-Behind (Chrome and Firefox)?

    Hello,
    Currently I am developing an IHttpHandler which at the should redirect the user to an Edit mode of a document located in a Document Library.
    The Problem is that in Firefox and Chrome it downloads the document in the temp folder. In IE it works as expected.
    The following code is used for the redirection:
    SPUtility.Redirect(urlOfTheNewDocument, SPRedirectFlags.Trusted, context);

    Hi,
    Please try to use IE Tab.
    Chrome IE Tab:
    https://chrome.google.com/webstore/detail/ie-tab/hehijbfgiekmjfkfjpbkbammjbdenadd?hl=en 
    Firefox IE Tab:
    https://addons.mozilla.org/en-us/firefox/addon/ie-tab/
    Here is a similar thread for your reference:
    http://stackoverflow.com/questions/14455212/how-to-open-sharepoint-files-in-chrome-firefox
    Thanks,
    Dennis Guo
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Dennis Guo
    TechNet Community Support

  • Background color portler header in edit mode

    Hi,
    I'm having a had time searching this forum on the subject so here's my question: when in edit mode on a page (portal 9026) the background of the portlet headers turns into a greenish color.
    How can I change this color/which style is this?
    Thanks,
    Tony

    Hi Peter,
    no, I don't. To clarify, I am referring to the top of the page when in edit mode (where links like Graphical | Layout | List and things like page path, builder, navigator etc. are shown.
    Any suggestions?
    Thanks, Tony

  • ChaRM Allowing Multiple Users in the Same CD to be in Edit Mode

    We have upgraded to ChaRM 7.1 but are still using CRMD_ORDER and Transaction Monitor CRM_DNO_MONITOR.  When the Developer completes her change, populates the Current Processor with the Change Manager and clicks Save she keeps the CD open in Edit Mode.  The Change Manager is able to open the same CD and click Edit without any warning on the bottom of the window saying it is being processed by another user.
    When there is a hand off to the next Current Processor, both the previous and current user are able to be in edit mode.  I don't recall this being allowed before.  Has this changed with 7.1?

    DGS wrote:
    I have a global temp table (GTT) defined with 'on commit preserve rows'. This table is accessed via a web page using ASP.NET. The application was designed so that every one that accessed the web page could only see their data in the GTT.
    We have just realized that the GTT doesn't appear to be empty as new web users use the application. I believe it has something to do with how ASP is connecting to the database. I only see one entry in the V$SESSION view even when multiple users are using the web page. I believe this single V$SESSION entry is causing only one GTT to be available at a time. Each user is inserting into / selecting out of the same GTT and their results are wrong.
    I'm the back end Oracle developer at this place and I'm having difficulty translating this issue to the front end ASP team. When this web page is accessed, I need it to start a new session, not reuse an existing session. I want to keep the same connection, but just start a new session... Now I'm losing it.. Like I said, I'm the back end guy and all this web/connection/pooling front end stuff is magic to me.
    The GTT isn't going to work unless we get new sessions. How do we do this?
    Thanks!You may want to try changing your GTT to 'ON COMMIT DELETE ROWS' and have the .Net app use a transaction object.
    We had a similar problem and I found help in the following thread:
    Re: Global temp table problem w/ODP?
    All the best.

  • Image needs to be enable only user select the edit mode

    Hi Expert,
    I have added one Image using value node and in get method I have given my image name, I also regenerated set, I and P method. I also moved the image in the configuration part.
    Now the Image is visble in the webui in editable mode.  But the requirement while opening any service order the image should be visble under the gernal data in disable mode.  While user selecting the edit button then only the image should be visible in the web ui.
    I tried to make this image in I Method, but I method is not triggered while debugging.  So kindly let me know how to overcome this issue.  Expecting your response ASAP.
    Thanks and Regards,
    Kannan.

    Hello,
    Did you try to use different image sources depending on the document process mode ?
    Exemple:
    1) If the document is in edit mode, then image source = 'your_image.jpg'
    2) If the document is in display mode, then image source = cl_thtmlb_util=>get_icon_url( iv_icon_name = '1x1.gif' )
    Nicolas.

  • How to maintain the Goods reciepent field in edit mode while SHC creation

    Hi Experts,
    Can any one suggest me a solution, this is the requirement in SRM 5.0 version classic.
    Business wants to keep the Goods recipent field in edit mode instead of in grey mode, so that User can edit and assign someone at the time of creation of shopping cart.
    This is because If i raise a shopping cart i will be goods recpient by default, but business does not want that they want to edit  and assign a person at the time of creation of shopping cart .
    Can it be possible in the standard template.
    If so what has to be done. Please suggest !!!
    Regards
    Srujan.K

    Hi
    Srujan:- while creating a cart you might get a list of good recipient right so you can assign whoever you wish to be a good recipient right. while creatiing a cart good recipient was determined and partner functions are created for good recipient. do you want to edit them again.
    Can we change Goods Recipient after shopping cart is ordered
    nagaraj:- in old srm it helps but srm 550 say no
    http://help.sap.com/saphelp_srm50/helpdata/en/84/a7e3389870c05ce10000000a114084/content.htm
    we can not make default good recipient
    for eg srujan create a cart by default naga become a good recipient . that is old. this requester attribute dont work for dual purpose.
    it uses sfor only on behalf of only
    br
    muthu

  • After userA check out a page, edit the page and save, Sharepoint prompt userA have checked out the page

    In one of site collection at our SP2013 farm, we have "SharePoint Server Publishing" site feature and "SharePoint Server Publishing Infrastructure" site collection feature activated.
    One of user (UserA) create a page in a page library. The new page is marked as "checked out by UserA". It is fine.
    Then UserA open the page -> edit page -> key in something and "save". Then the page prompt him "The file Pages/subfolder/test001.aspx has been modified by i:0#.w|test\userA on 8Aug2014 xx:xx:xx" and ask him to choose "Leave
    this page" or "say at this page".  The date time is exactly the time he was editing the page.
    Whatever he choose will save the page and return to "View" mode (non-edit mode).
    It is not the only problem. When userA want to edit the same page again and save, it prompt him that "The page could not be saved because your changes conflict with recent changes made by another user. If you continue, your changes will be lost."!
    When userA choose continue or "check out". Follow screen show up:
    What can we do? In summary, userA cannot edit a page because userA have checked out! We have tried for different users have exactly same issue.

    We are having the same problem, the one thing we have found is if we use the Save Icon on the top right hand side of the page in the ribbon (next to follow), that Save works just fine.  What is causing the issue is when trying to use the Save Icon on
    the left hand side of the ribbon that has the dropdown options to 'Save', 'Save and Keep Editing' or 'Stop Editing'.  It doesn't matter if you just click on the main Icon or choose any of the dropdown options, they all cause issues with the pages.  
    Thoughts?
    Nick Hurst

  • Is there a way to detect if the page is in edit mode or not? [WC Framework]

    I just can't find any system bean to provide such information. If any one know, that'd be very helpful.
    This is for Webcenter Framwork (not the Space). and by "edit-mode", I mean when user hit Ctrl+Shift+C and the blue dotted lines show up.
    Thanks in advance
    Edited by: Chris_Jo on Jan 25, 2012 12:16 PM

    Following EL will do what you want:
    #{composerContext.inEditMode}In other words, the composerContext bean is available, even in a WebCenter Portal application. If you take a look at the default template (pagetemplate_globe.jspx) that is created when you create a webcenter portal application. On line 16, you see an example of the usage.
    edit: sorry... Didn't see you meant the contribution mode...
    Edit mode is by pressing ctrl+shift+e
    ctrl+shift+c is called contribution mode...
    I just looked at the source code of the content presenter taskflow and this is what they are using to show the dotted line:
    inlineStyle="#{composerContext.subView == 'contentContribution' ? 'border:2px dashed blue' : ''}">So I guess #{composerContext.subView == 'contentContribution'} will return true if you are in contribution mode. This should work both in spaces as in framework.
    Hope this helps.
    Edited by: Yannick Ongena on Jan 25, 2012 8:10 PM

  • Can't get my audio clip to work in Keynote except in edit mode. I've followed Help instructions to the letter. Any suggestions?

    Can't get my audio clip to work in Keynote except in edit mode. I've followed Help instructions to the letter. Any suggestions?

    Hi Gary - thanks so much for your help. I'd already done that, but finally stumbled across the answer for my situation. I'm new to iMac and this is the first time I used Keynote, so maybe this info will help someone else along the way - I still haven't found this in any of the Keynote documentation or forums I've read.
    My slides were all set up with at least one text box in which the text was animated. The sound was the last thing I added to each slide, exactly following the info in Keynote Help re: adding audio. The audio would work when I tested it in Inspector mode, and also if I switched to soundtrack instead. But not if sound was added to each individual slide. Hmmm. After I submitted the question above, I was running through the (auto) slide show one final time to check text, animation, etc. when I noticed that on just one single slide the sound effect came through, but at the very tail end of the slide. Hmm again. Why?
    Through trial & error, the answer was in the animation section - not very intuitive re: audio. The steps to correct the issue were: 1) click on the sound icon embedded in each slide, 2) click on the animation tab in Inspector. 3) There's a drop-down menu there that allows you to reposition the audio clip to the #1 spot (if it was added after other "animation"). This allows the sound to begin before the text animation begins on each slide. Before doing this, I guess the sound was in there but the slides were transitioning before it had a chance to play.
    Since this is the first time I've used Keynote and it's the most recent version, I'm not sure if this is a new feature to allow users to choose where within a slide to play a sound effect, but I'm guessing that might be why was unable to find any info on how to solve it. Hopefully this will help others who get stumped.
    Thanks again for jumping in to help! I really appreciate it.

  • Display a file with in the ADF screen in the edit mode.(RTF or Word format)

    Hi ,
    As per my business need i need to display a file (.doc or .pdf) in the ADF screen in the edit mode. Later user can be able to save the document . As of now i am using a separate editor for edit the document. but that editor is supporting only for html format only. so that some images which are there in those files are not displaying in the screen.so this is not the consistent solution for my requirement.
    So please help on this if any body had done this kind of object.
    Thanks,
    Rajesh
    Edited by: 927500 on Apr 18, 2012 7:31 AM

    Hi,
    ADF doesn't provide a component for PDF and Word editing.
    Frank

  • IPhoto:  I have several photos that will not open in the edit mode.  They also will not open to a screensaver.

    I have Version 10.6.8 and iPhoto 9, versiono 8.1.2.
    Two questions: 
    1)  I can't find the 9.0 to install so I can then update thru 9.3...
    2)  I have several pictures that will not open in the edit mode.  There is just a blank screen when I attempt to open them.  I cannot export them to the desktop either.  Message is:  Unable to create/Users/(my name)/Desktop
    Help!

    What about a work-around?
    Ios 7.1 etc. has a problem with communicating with exchange.  There are lots of reports of problems with pdf files.
    The work-arounds mentioned here may be of assistnace.
    https://discussions.apple.com/thread/5992793?start=0&tstart=0
    get a gmail account.
    There are lots of ways of moving files.
    A simple and popular way to copy files and share files among your devices.
    https://www.dropbox.com/
    "Box lets you store all of your content online, so you can access, manage and share it from anywhere. Integrate Box with Google Apps and Salesforce and access Box on mobile devices" Rated the most secure cloud storage by SkyHigh Networks.
    https://www.box.com/
    Files Connect -- "Cloud Storage services like Dropbox, MobileMe iDisk, Google Docs/Picasa, Facebook photos, FTP, SFTP, WebDAV ... AFS (Apple File Shares) SMB (Windows shares)  protocols"
    https://itunes.apple.com/us/app/files-connect/id404324302?mt=8
    Windows File server
    http://itunes.apple.com/us/app/filebrowser-access-files-on/id364738545?mt=8
    "Dukto is a simple application that allows you to share files between devices connected to the same (wireless) LAN network."
    http://www.tidal.it/?page_id=309&lang=en
    http://www.msec.it/blog/?page_id=11

Maybe you are looking for

  • JVM Crashes with a VM state:not at safepoint (normal execution) error

    Hello. I have been battling with this error occasionally ocurring for months. There are many suggestions in various blogs and they all seem to think it's a JVM bug. I'm not so sure. I am running JBOSS 4.0.5 on SuSE Linux 10. JVM is Java HotSpot(TM) S

  • How to add display button(ICON) on standard report screen?

    Hi, I have to add display button after the excute button on the standard selection screen of the report. could you please guid me how to do that i was trying with below but it does not reflect. TABLES:  sscrfields. TYPE-POOLS: slis, icon. INITIALIZAT

  • Use a MacBook as a combi Keyboard/Mouse/Monitor?

    Hi, I was just wondering if it is possible to use a lets say MacBook Air as a monitor, keyboard and mouse/trackpad for another Mac via thunderbolt or something?

  • Multiple ALEAUD Idocs are being generated per original Idoc

    We have the following scenario in PI: ERP (IDOC)> PI (JDBC)> 3rd Party PI sends ALEAUD idocs back to ERP when the process is successful.  Program RBDAPP01 is then ran on a schedule to update the ALEAUD idoc status, which in turn, updates the idoc sta

  • JWSC Task "Error in opening zip file"

    I'm having a problem with JWSC execution. Within this task I have JWS subtask and implementation java file of web service. I have also added the other java files from other packages that are used in the implementation java file. When JWSC does compil