Document root of web application

Hi. I'm having trouble determining where a web application is pulling a particular resource from.
I always though that the ServletContext.getResource() resolved it's path relative to the root of the WAR file or the equivalent root of the exploded deployment. However, I have a web application that appears to be running out of a war file, but also retrieving resources from the surrounding filesystem with getResource() Is this possible?
In particular, is it possible to have multiple roots? How would these multiple roots be configured, i.e. where would you specify them?
I've reread the servlet specification and it talks about the getResource() being capable of pulling resources off of remote filesystems, etc. So, i get the sense I'm missing some details.

This might help.
If you put this in the java code, it will print to the console the path that java code is running from. From there, you should be able to go up or down the directory structure as necessary. Note it will print out a different path for your project running in your development enviornment than when its deployed on a server.
File file=new File("");
System.out.println(file.getAbsolutePath());

Similar Messages

  • How to find the root document of my web application, if it is in WAR file ?

    Hi,
    I want the root document of my web application. I my EAR file, i have only one WAR file. In my WAR file the following are the folders:-
    enterprise/..
    properties/sql/..
    locale/..
    WEB-INF/..
    Once i get the 'real path' or 'root document', I will use that in my application in no.of times. Path(root document) is used in the following way in my application:-
    File emailTemplatesFolder = new File( path + "/enterprise/"+ enterpriseCode+"/EmailTemplates");
    If i use getRealPath() method, it works fine, in use Oracle9ias, because, EAR file will be extracted. Where as in Weblogic 6.1, EAR file willn't be extracted, so that getRealPath() is giving 'null', that is reason why i am seeking for alternative.
    Thanks in Advance
    Srinivas

    Yes, that is the corrected behaviour.
    What you need to do is to get the ServletContext, and then load the files as resources.
    Here is how to load a properties file in the init() servlet method, which has access to the ServletConfig object that can give u the ServletContext.
    String classesDir = "/WEB-INF/classes";
    ServletContext sc = config.getServletContext();
    InputStram is = sc.getResourceAsStream(classesDir+"default.properties");
    props.load(is);
    Hope it helps,
    Liviu

  • Setting Document Root in WebLogic 6.1

    I have recently migrated from WebLogic 5.1 to WebLogic 6.1, on Windows 2000
    running jdk 1.3.1. My Document Root settings (weblogic.httpd.documentRoot)
    from WebLogic 5.1 in my weblogic.properties file did not carry over to
    WebLogic 6.1, so does anybody know how to set the Document Root in WebLogic
    6.1? Or is there an equivalent to it now?
    Thanks in advance,
    Dustin N. Jenkins

    Hi Dustin,
    I think you posted this to the wrong newsgroup :-)
    In WLS 6.1, document roots are Web Application specific. Unless you explicitly
    change it, the default Web Application (the one that you get when you type in
    the http://localhost:7001 URL), the document root is a folder under your domain's
    application directory named "DefaultWebApp_{name-of-your-server}". Where {name-of-your-server}
    is whatever value you assigned to the -Dweblogic.Name property, on the command
    line you started WLS with. Refer to the WLS 6.1 documentation for instructions
    on how to change this to a different Web Application. Here are a couple of links
    that will provide you with some insight into this:
    http://edocs.bea.com/wls/docs61/webapp/basics.html#136976
    http://edocs.bea.com/wls/docs61/adminguide/web_server.html#113228
    Regards,
    Mike Wooten
    "Dustin N. Jenkins" <[email protected]> wrote:
    I have recently migrated from WebLogic 5.1 to WebLogic 6.1, on Windows
    2000
    running jdk 1.3.1. My Document Root settings (weblogic.httpd.documentRoot)
    from WebLogic 5.1 in my weblogic.properties file did not carry over to
    WebLogic 6.1, so does anybody know how to set the Document Root in WebLogic
    6.1? Or is there an equivalent to it now?
    Thanks in advance,
    Dustin N. Jenkins

  • How to upload documents to DMS from web application externally

    We have a webdynpro based J2EE application. We want to create a SAP DMS ( KPRO ) document using this web application externally.
    Any inputs on this scenario ?
    I am able to create similar using an ABAP report which reads the client file and create the DMS document using BAPI_DOCUMENT_CREATE.
    How do we achieve this using external web application ..
    Please HELP in this.
    Thanks..

    Hi Divya,
    Good day...!
    A custom UI component will berrequired to upload the data from a Flat File into CRM WEBUI.
    The View in this UI Component can have 2 fields lets say u2013  ID and File to Upload and a button 'upload'.
    When the UPLOAD button is clicked , the event u2018ONFILEUPLOADu2019 is triggered.
    A Javascript function u2018fileUpload()u2019 reads the Excel file and formats the data in the form of a long string with Line Breaks corresponding to each row in the excel file. This string is stored in a Hidden HTML form element u2018Excel_Datau2019.
    In the Event Handler for u2018ONFILEUPLOADu2019, the hidden form element u2018EXCEL_DATAu2019 is read and retrived.
      lv_file_data = request->get_form_field( name = lv_excel_data ).
      me->lv_id = request->get_form_field( name = lv_schema_id ).

  • Document root element

    When starting Sun One Application Server 7 I get the following error in the console:
    SEVERE ( 5028): ContextConfig[ROOT] Parse error in application web.xml
    org.xml.sax.SAXParseException: Document root element "web-app", must match DOCTYPE root "null".
    What does this error mean and how do I fix?
    My web.xml file:
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app 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      http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
      version="2.4">
      <display-name>My appliation</display-name>
      <description>My appliation</description>
      <context-param>
        <param-name>log4j-file</param-name>
        <param-value>WEB-INF/log4j.properties</param-value>
      </context-param>
      <listener>
        <listener-class>
          com.gh.web.listener.Listener
        </listener-class>
      </listener>
      <servlet>
        <servlet-name>action</servlet-name>
        <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
        <init-param>
          <param-name>config</param-name>
          <param-value>/WEB-INF/struts-config.xml</param-value>
        </init-param>
        <init-param>
          <param-name>debug</param-name>
          <param-value>0</param-value>
        </init-param>
        <load-on-startup>2</load-on-startup>
      </servlet>
      <jsp-config>
        <taglib>
          <taglib-uri>/tags/common</taglib-uri>
          <taglib-location>/WEB-INF/tld/common.tld</taglib-location>
        </taglib>
      </jsp-config>
    </web-app>

    If running on Tomcat Server, then is start without errors.
    I made a following change in web.xml and error is disappeared:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN'
      'http://java.sun.com/j2ee/dtds/web-app_2_3.dtd'>
    <web-app>
    </web-app>The reason for the 'break' is because I attempting to deploy a web application following the 2.4 spec that Sun One Application Server 7 does not support or why?

  • How to get the network details in flex4.5 web application

    How to get the network details in flex 4.5 web application
    similar to the nativeinterface in air application

    checkout this document for secure web application
    http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf6167e-7fff.html    

  • Multiple Web Applications WLS 7.0

    Hi,
    I am trying to configure multiple web applications on the same WL 7.0 server and
    am having trouble doing the following.
    I would like to be able to use the following URLS:
    Application #1:
    http://myserver/st/aems - where st/aems maps to the path X:\SimpleTrade2\AEMS\ui\source\htdocs
    Application #2:
    http://myserver/st/acms - where st/aems maps to the path X:\SimpleTrade2\ACMS\ui\source\htdocs
    Root - Default web application - This would be left empty with the idea that our
    company could sell our web applications and we would deploy them on someone elses
    WLS and we would not conflict in any way.
    The problem with the above is that when I look at the DTD and try and configure
    config.xml in the following way:
    <Application Deployed="true" Name="AEMS"
    Path="X:\SimpleTrade2\AEMS\ui\source\htdocs" TwoPhase="true">
    <WebAppComponent DeploymentOrder="2000" Name="aems"
    Targets="simpletradeserver" URI="st/aems"/>
    WLS blows up on startup because it tries to POST-Pend the URI to the path... If
    I change it to:
    <Application Deployed="true" Name="AEMS"
    Path="X:\SimpleTrade2\AEMS\ui\source" TwoPhase="true">
    <WebAppComponent DeploymentOrder="2000" Name="aems"
    Targets="simpletradeserver" URI="htdocs"/>
    This will work but then my URL is not what I want it becomes http://myserver/htdocs
    Is there anyway around this or a way to get what I want?
    Another piece of information, I am developing in Exploded directory format when
    we deploy it will be as an ear.
    Thanks in advance for any ideas!!!
    -Jerry Rodgers

    Thanks for the info Christian.
    I thought I would pass along a bit more inforation for others who might be trying
    to do something similar. In case they run across this message.
    I did determine that if you are using a .WAR file the name attribute of the xml
    node WebAppComponent will allow you to create a different context path than the
    URI. I did not test to see if it allowed you to use a name like "st/aems" I am
    sure "st.aems" would work or any name that may be different than the URI. The
    weird thinhg is that when using the EXPLODED DIRECTORY format the URI is the name
    of the folder under the path and the name property appears to be ignored no matter
    what you change it to you can only get to your web app using the URI.
    Hope this helps someone who comes after me and is looking for the same thing,
    maybe they won't spend 6 hours on it like I did ;>
    -Jerry
    "Christian Plenagl" <[email protected]> wrote:
    >
    Hi,
    this is not possible.
    The URI field contains the directory name of the WebApplication, which
    normally
    is the same name as the directory where you put the webapplication in.
    Christian Plenagl
    Developer Relations Engineer
    BEA Support
    "Jerry Rodgers" <[email protected]> wrote:
    Hi,
    I am trying to configure multiple web applications on the same WL 7.0
    server and
    am having trouble doing the following.
    I would like to be able to use the following URLS:
    Application #1:
    http://myserver/st/aems - where st/aems maps to the path X:\SimpleTrade2\AEMS\ui\source\htdocs
    Application #2:
    http://myserver/st/acms - where st/aems maps to the path X:\SimpleTrade2\ACMS\ui\source\htdocs
    Root - Default web application - This would be left empty with the idea
    that our
    company could sell our web applications and we would deploy them onsomeone
    elses
    WLS and we would not conflict in any way.
    The problem with the above is that when I look at the DTD and try and
    configure
    config.xml in the following way:
    <Application Deployed="true" Name="AEMS"
    Path="X:\SimpleTrade2\AEMS\ui\source\htdocs" TwoPhase="true">
    <WebAppComponent DeploymentOrder="2000" Name="aems"
    Targets="simpletradeserver" URI="st/aems"/>
    WLS blows up on startup because it tries to POST-Pend the URI to the
    path... If
    I change it to:
    <Application Deployed="true" Name="AEMS"
    Path="X:\SimpleTrade2\AEMS\ui\source" TwoPhase="true">
    <WebAppComponent DeploymentOrder="2000" Name="aems"
    Targets="simpletradeserver" URI="htdocs"/>
    This will work but then my URL is not what I want it becomes http://myserver/htdocs
    Is there anyway around this or a way to get what I want?
    Another piece of information, I am developing in Exploded directoryformat
    when
    we deploy it will be as an ear.
    Thanks in advance for any ideas!!!
    -Jerry Rodgers

  • Trouble getting data that I post to my JSC web application

    I have some Java code that posts an XML document to my web application. I tried placing the following code in the init() method of my first page.
    FacesContext context = FacesContext.getCurrentInstance();
    String postData = context.getExternalContext().getRequest().toString();
    Instead of getting the XML content that I posted, I get this result in the string :
    com.sun.faces.context.MyHttpServletRequestWrapper@1c26895
    I wish I knew more about the architecture, and exactly what happens when a request is sent to the application URL with post data.
    Joe Paladin

    FacesContext context = FacesContext.getCurrentInstance();
    String postData = context.getExternalContext().getRequest().toString();
    Instead of getting the XML content that I posted, I get this result in the string :
    com.sun.faces.context.MyHttpServletRequestWrapper@1c26895Right - the request object you got is HttPServletRequest implementation, see for example :
    http://java.sun.com/javaee/javaserverfaces/1.0/docs/api/javax/faces/context/ExternalContext.html#getRequest()
    Now you can cast to and use various methods of HttPServletRequest to access the data submitted to the servlet. See for example getInputStream or getParameterValues methods:
    http://tomcat.apache.org/tomcat-4.1-doc/servletapi/javax/servlet/ServletRequest.html#getInputStream()
    I wish I knew more about the architecture, and exactly what happens when a request is sent to the application URL with post data.It is HTTP POST request (google for rfc2068) : on the wire it is a stream with set of headers, including such as length of the data being submitted and its encoding, followed by the data encoded in either one of 2 ways, please see http://www.w3.org/TR/html4/interact/forms.html#h-17.13 and
    http://www.w3.org/TR/html4/interact/forms.html#h-17.13.4
    In particular the content of the submitted file should be streamed as part of "multipart/form-data" encoded data stream.

  • IWS60SP4 Additional Document Directories Problem with Web Application

    We have iPlanet/Sunone WebServer 6.0 Service Pack 4 installed. I have deployed a web application using the wdeploy command line. I have defined an additional document directory that is outside of the web application and document root. No matter how many ways I try it, it seems to expect that the document root is the source of the files and totally ignores the additional document directory definition.
    Example:
    additional document directory: /add /opt/dir1/dir2
    document root: /opt/doc/root
    URL given: http://my.domain.com/uri/add/file.html
    expected: to get file.html out of /opt/dir1/dir2
    actual: fails, trying to get /opt/doc/root/add/file.html
    Do additional document directories actually work? (They worked for us under iPlanet 4.1) If so, please tell me how to make them work with a deployed web application.
    Thank you.
    - Tom

    In the original post you state:
    Example:
    additional document directory: /add /opt/dir1/dir2
    document root: /opt/doc/root
    URL given: http://my.domain.com/uri/add/file.html
    expected: to get file.html out of /opt/dir1/dir2
    actual: fails, trying to get /opt/doc/root/add/file.html
    You are mapping /add to the new dir. The URL you would need to type then is:
    http://my.domain.com/add/file.html
    not
    http://my.domain.com/uri/add/file.html
    Mapping /add to a new dir will work. You do not need to specify /uri/add.

  • Problems while accessing images outside the web document-root folder

    Our application runs on Oracle application server on Linux. Facing problems while accessing images outside the web document-root folder. This works with changes in global-web-application.xml by including the <virtual-directory> tag. The same change does not work when done on Linux machine. It is unable to find the image. Please help in resolving this issue.
    </locale-encoding-mapping>
    </locale-encoding-mapping-list>
    </web-app>
    <virtual-directory virtual-path="/img" real-path="/home/eposuat/" />
    </orion-web-app>
    Code in the jsp:
    <img width=700 height=700 src="/img/3.tif"></img>
    <img width=700 height=700 src="/img/WB.gif"></img>

    This is one of the least satisfactory aspects of site management in Dreamweaver, and several developers, including myself, have been pressuring the Dreamweaver team for some years to improve this. Who knows? They might eventually take notice.
    The only way to do this at the moment is to create two site definitions, one nested inside the other. Set up the site definition normally based on htdocs as your site root. Then create a new site definition based on site. Dreamweaver will nag you that it can cause problems, but it won't actually stop you from doing it. The only potential problem is with site synchronization.
    The problem with using site as the only basis for your site definition is that Dreamweaver automatically puts things like the Connections, Scripts, and other folders in the site root. So, everything ends up at the wrong level of the site hierarchy. Quite frankly, the whole thing is a bit of a pain. Dynamic site development was added to Dreamweaver only in version 6 (Dreamweaver MX), and no one had really thought through the need to store files outside the site root.

  • WL 8.1: Configuring a document root for multiple web applcations in a domain

    Subject: Application - document root
    I am using the Apache web server with the BEA proxy plug-in. All requests to the
    apache server are proxied to WebLogic.
    http://localhost/wip-gl/xxx.jsp?param1...
    http://localhost/wip-am/xxx.jsp?param1...
    http://localhost/stg-gl/xxx.jsp?param1...
    etc
    For weblogic I have a domain where I have deployed 6 web applications. Each application
    represents a web site.
    .../wip-gl
    .../wip-am
    .../stg-gl
    etc
    But when processing jsp's it appears that the document root (web root) is not
    defined correctly.
    For each application how do I define the document root?
    Thanks for the help.

    Distributed sessions has nothing to do with different web applications. The concept is about distributing load for the same application between several appserver instances running on the same box(different jvm) or on some other box in the network.
    What you used with iAS 6.5 is not available in 8.1 because sharing sessions between web apps is forbidden by the servlet spec. You should consider repackaging your apps. into a single web app. or using other way of signing/verifying user identity(check Sun Access Manager for example).
    Have a look at this thread as well: http://swforum.sun.com/jive/thread.jspa?threadID=100931

  • 7210 - Specify different document root for a WAR/exploded application

              Hello,
              I would like to know how to specify a specific directory under my WAR/exploded
              directory as the
              document root instead of the standard application root directory as the document
              root directory.
              The following explains why I need that way..
              Our Source Code Control System consists of the following development directory
              hierarchy..
              /VOB/Application/
              /VOB/Application/Development/source/com/company/... *.java
              /VOB/Application/Development/docs/businessfunctionality1/*.jsp, *.html
              /VOB/Application/Development/docs/businessfunctionality2/*.jsp, *.html
              /VOB/Application/Development/docs/images/*.gif
              /VOB/Application/Development/Web-inf/web.xml
              /VOB/Application/Development/Web-inf/tlds/*.tld
              /VOB/Application/Development/Web-inf/lib/*.jar
              /VOB/Application/Development/Web-inf/classes/com/company/... *.class
              /VOB/Application/Design/*.doc, *.mdl
              With the above structure, the root directory of the applications is /VOB/Application/Development/
              

    Hi,
    You can't specify two different context root directly from your application unless until you specify " / " in context root and access application from two different host.
    Hope this should give you a clue.
    Regards,
    Kal

  • System.IO.FileNotFoundException: The Web application at ..not found - when getting document versions in a doc lib

    i have created a    asmx file using vs 2012 4.5 framework, and published to my d:\  drive  and mapped to a  iis  web site
    but when i trued to consume this from a another web appln, it throws me the below error:
     System.IO.FileNotFoundException: The Web application at http://srvr:4000/sites/mysitecollec could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a
    new request URL mapping to the intended application.
       at Microsoft.SharePoint.SPSite.LookupSiteInfo(SPFarm farm, Boolean contextSite, Boolean swapSchemeForPathBasedSites, Uri& requestUri, Boolean& lookupRequiredContext, Guid& applicationId, Guid& contentDatabaseId, Guid& siteId,
    Guid& siteSubscriptionId, SPUrlZone& zone, String& serverRelativeUrl, Boolean& hostHeaderIsSiteName, Boolean& appWebRequest, String& appHostHeaderRedirectDomain, String& appSiteDomainPrefix, String& subscriptionName, String&
    appSiteDomainId, Uri& primaryUri)
       at Microsoft.SharePoint.SPSite..ctor(SPFarm farm, Uri requestUri, Boolean contextSite, Boolean swapSchemeForPathBasedSites, SPUserToken userToken)
       at Microsoft.SharePoint.SPSite..ctor(SPFarm farm, Uri requestUri, Boolean contextSite, SPUserToken userToken)
       at Microsoft.SharePoint.SPSite..ctor(String requestUrl)
       at FetchlatestDocDet6Jan.FetchLatestDoc6Jan.<>c__DisplayClass1.<FetchLatestDocVer>b__0() in d:\PublishWSFetchLatestDoc6Jan.asmx.cs:line 41
       at Microsoft.SharePoint.SPSecurity.<>c__DisplayClass5.<RunWithElevatedPrivileges>b__3()
       at Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode)
       at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param)
       at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode)
       at FetchlatestDocDet6Jan.FetchLatestDoc6Jan.FetchLatestDocVer(String fileName, String processID, String subProcessId) in d:\PublishedWS\FetchLatestDoc6Jan.asmx.cs:line 35
    [WebMethod]
            public DataTable FetchLatestDocVer(string fileName,string processID,string subProcessId)
                DataTable dtFiles = new DataTable("File Details");
                dtFiles.Columns.Add("File Name");
                dtFiles.Columns.Add("File Version");
                dtFiles.Columns.Add("File Url");
                SPSecurity.RunWithElevatedPrivileges(delegate()
                    // implementation details omitted       
                //using (SPSite mySite = new SPSite(siteUrl))
                using (SPSite mySite = new SPSite("http://srvr:4000/sites/mysitecoll"))
                    using (SPWeb myWeb = mySite.OpenWeb())
                        SPList oList = myWeb.Lists["TEST DOC LIB "];
                        SPView oView = oList.Views["All Documents"];                  // SPQuery oQuery = new SPQuery(oView);
                        SPQuery oQuery = new SPQuery();
                        string query = "<Query><Where><And><Eq><FieldRef Name=Title/>" + "<Value Type=Text>" + fileName + "</Value></Eq>"
                                        +"<Eq><FieldRef Name=ProcessID /><Value Type=Text>"+processID+"</Value></Eq>"
                                        +"<Eq><FieldRef Name=SubProcessID /><Value Type=Text>"+subProcessId+"</Value></Eq>"
                                        +"</And></Where></Query>";
                        oQuery.Query = query;                    
                        oQuery.ViewAttributes = "Scope=\"Recursive\"";
                        SPListItemCollection collListItemsAvailable =
                         oList.GetItems(oQuery);
                        foreach (SPListItem oListItemAvailable in collListItemsAvailable)
                           // Console.WriteLine(oListItemAvailable["Name"].ToString());
                            SPFileVersionCollection versions = oListItemAvailable.File.Versions;
                            // If the file has versions, loop through all of the versions
                            if (versions != null)
                                if (versions.Count > 0)
                                    foreach (SPFileVersion version in versions)
                                     //   Console.WriteLine("Version Info:: {0}, {1}", version.VersionLabel, version.Url);
                                        DataRow dr = dtFiles.NewRow();
                                        dr[0] = oListItemAvailable["Name"].ToString();
                                    //Added data to the datatable
                                else
                                  //  Console.WriteLine("Version Info:: {0}, {1}", oListItemAvailable.File.UIVersionLabel, oListItemAvailable.File.Url);
                                    DataRow dr = dtFiles.NewRow();
                                    dr[0] = oListItemAvailable["Name"].ToString();
                                    dr[1] = oListItemAvailable.File.UIVersionLabel;
                                    dr[2] = oListItemAvailable.File.Url;
                                    dtFiles.Rows.Add(dr);
                return dtFiles;

    "The Web application at http://server:port/ could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing
    content, the system administrator may need to add a new request URL mapping to the intended application"
    Here are the most common reasons this error can occur:
    The code is executed on a different machine - The SharePoint object model (except the Client API) requires to be run on the SharePoint server itself. It is not possible to run the application on a server which is not within the same
    SharePoint farm the code is trying to access.
    Insufficient Rights on the site collection - The code is executed in context of an account which does not have read permission on the site collection
    Incorrect Url being used - Verify that the site works correct in a browser and double check that the server is correct registered in the AAM settings
    Incorrect bitness - The SharePoint object model needs to be executed with the same bitness as the operating system. That means you cannot use the SharePoint object model in a 32-bit application if the Operating System and SharePoint
    are installed as 64-bit version. Ensure to compile the project using the correct bitness (64-bit on a 64-bit machine vs. 32-bit on a 32-bit machine)
    Incorrect .NET framework version -  Ensure that the project is configured to use .NET 3.5. .NET 4.0 cannot be used with the current versions of SharePoint
    from Mr.Stefan's post, i have checked with my code : as per the first reason: (1)
    i am running the code from my  SP 2013 machine only. but the only difference is that, i am using a  asp.net web appln and have added a SP references of 15 hive and trying to make a  lists.asmx file.
    also checked the reasons
    2,3 ,4 ,5 all are  fine from my end.
    here just wanna know: abt the below approach : whether its Correct or NOT.
    create a plain GetDocsWebService.asmx file from asp.net 3.5 framework and  write the code for retrieving items from doc.lib using SPSite, spweb, splists, xmldocument and retrieve a datatable . [[[ i have added a web reference of sp 2013 microsoft.sharepoint
    dll from  isapi folder, in this GetDocsWebService.asmx project ]]
    i deployed this web service on my SP server's  new iis site, c:\inetpub\wwwroot\GETDOCSPUBLISH  site
    now, at present , am adding a  normal asp.net 4.5 web appln and add the  web reference of this custom web service and trying to consume.
    at this point am getting mulitpl errors: like
    1) platform not supported : am stuck with this error!!
    2) sometimes, am getting document not valid...<html> <head> document not valid........</html>
    for the above 2 errorrs, i still could not able to find a solution!!
    is it because, lists.asmx is not supported in sp 2013? we need to depend on rest-api/ecma/csom ?? 
    so my question is ,  what should be the correct ad most recommended approach  for reading doc lib/ splist  records/items from a  remote macihne.

  • Report on all documents (plus metadata) uploaded to a web application within a specific time period

    Hi All,
    The business is looking for a report that lists all documents added to all sites within a web application ( with multiple sites ) and includes both custom and standard ( modified , modified by etc.) metadata
    Is auditing the way to go or is there some way to report against the index created by the Search application ?
    All suggestions appreciated.
    Thanks,
    Counie
    SharePoint Farmer in training

    There are 3rd Party tools that can give you this level of detail, or you can roll your own with jQuery or other programming.
    Steve Clark, MCTS |
    Twin-Soft Corporation
    Easy Bins Roll-off Dumpster Rentals in Northern VA
    Specializing in:
    Driveway-sized, roll-off dumpster rentals in Fairfax VA |
    Dumpster Rentals for Junk Hauling in Springfield VA
    Roll-off Rental Dumpsters in Annandale, VA |
    Dumpster Rentals for Estate Cleanout in Alexandria VA

  • Advice needed for provider hosted web application - authentication and access to SharePoint document library

    I haven't done SharePoint 2013 development with claims so I apologize in advance if my assumptions and questions are way out in left field.
    I'm trying to understand SharePoint 2013 claims authentication for a scenario that involves:
    A SharePoint provided hosted (web forms) app that will pull information and assets (e.g. PDFs) from SharePoint into the web page.
    It will be a VS 2012 solution with asp.net.identity feature.
    Security will be set for internal users, federated external users and forms-based external users.  Based on their security and (claim type) role it will define what information and assets that can be retrieved from SharePoint
    I have looked through MSDN and other sources to understand.
    This one helped with my understanding 
    Federated Identity for Web Applications and assumed that the general concept could be applied to forms-based identity for non-Federated external users .
    What I have now:
    VS 2012 solution web forms application set to Provider Host with asp.net.identity feature and its required membership tables.
    I can create new users and associate claims to the new user.
    I can log in with a user from the membership tables and it will take me to a default.aspx page.  I have added code to it that displays the claims associated to a user.
    For POC purposes I'd like to retrieve documents that are associated to this user from the default.aspx page.
    This is where I am having trouble understanding:  Is my understand correct?
    Internal users
    since they are internal on the network i am assuming that they would already have access to SharePoint and they would already be configured to what documents that they have available to them.
    Federated external users & Forms authentication external users
    it seems to me that the authentication for external users are separate from SharePoint authentication process.
    changes to the configuration settings are necessary in SharePoint, IIS, web application.
    I believe this is what i read.
    claims processes (e.g. mappings) need to be set up in SharePoint
    as long as external users are authenticated then things are ok b/c they would have claims associated to the user and the configuration in SharePoint takes are of the rest.
    This statement bothers me because I think it's wrong.
    So basically i'm stuck with if my understanding is correct: once a user is authenticated either by federated identity or asp.net.identity authentication that it should go to the provider hosted default.aspx page because the claim is authenticated and means
    that it should have access to it and the SharePoint document library based on some claim property.  I could then write the calls to retrieve from a document library and SharePoint will know based on some claim property that the logged in user can only
    access certain documents.
    It just sounds too good to be true and that i'm missing something in the thought process.
    Thanks in advance for taking the time to read.
    greenwasabi

    Hi GreenWasabi,
    i agree this is an interesting topic to discuss,
    as you can check from the article, you may check this example from the codeplex:http://claimsid.codeplex.com/
    when i thinking regarding this topic, its looks like an environment with multiple of realms,
    from what you understand, its correct that all the authentication is based from the provider, so for example i have a windows live ID and internal ID, then when i login windows live ID, it will be authenticated using windows live ID server.
    here is the example for the webservice:
    http://claimsid.codeplex.com/wikipage?title=Federated%20Identity%20for%20Web%20Services&referringTitle=Home
    as i know, if you using this federated, i am not quite sure that you will need to go to the provider page literally, perhaps you can check this example if we are using azure:
    http://social.technet.microsoft.com/wiki/contents/articles/22309.integrating-windows-live-id-google-and-facebook-accounts-with-sharepoint-2013-white-paper.aspx
    Regards,
    Aries
    Microsoft Online Community Support
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

Maybe you are looking for

  • Can't get wireless PCI card to work

    I bought a Sonnet wireless PCI card but we can't get it to work yet. Before I return it I wanted to check to make sure all the software was right. The AirPort utility is v4.2. The extensions are: Airport 3.4.7 Airport2 4.0 AirportFW 3.4.7 AirportFWAP

  • IPhone Aspen Simulator not working

    I recently downloaded the iPhone SDK and I am trying to follow through the MoveMe tutorial. However, when I build and run the app, Aspen launches, but nothing appears on the simulator screen. I figured that I needed to turn it 'on', but clicking on t

  • How to get a coupons book on passbook, how to get a coupons book on passbook

    Ok! I have a coupon book i have bought a couple of months ago! i was wondering if i can get all those coupons on PassBook?? Please help!!! How would i do it??

  • Which web server is used for openHAB2?

    I've recently set up IDE for openHAB2 and built it successfully. openHAB dashboard & paper UI are web application. But I can't find any web server settings in openHAB project. Which web server is used for them? Is it possible to add java servlet for

  • Flash Player and Shockwave player Not Recognized

    I have Safair running in Rosetta. Some webisites state I need 7 or above Flash Player and that I don't have Shockwave Player- but I do! I tested them at the Adobe webiste and it states I have Flash Player 8,0,24,0 and Shockwave l0,1r,11 Successfully