Browse for a Resource

This feature helps with browsing for a resource that is already present in the HydroShare database. The option works very smoothly. This feature is brought about by the python API of HydroShare and what goes into the process is that we fetch for the resources in the HydroShare database using the fetch files button and then we can view them by just typing the subject with closest relevance to the resource that we are searching for. Finding a resource is one of the most useful features of this app.

Finding a resource is one of the most useful features of this app and there are many parameters that could be used to find a resource but this feature in the app is brought out by using the subject parameter.

Step 1: Enter in your username and password

In the boxes below enter your HydroShare username and password. If you need to make a HydroShare account, click here.

Step 2: Type in your subject of the resource you are looking for

Step 3: Browse for the resource you are looking for

The resources related to the subject, mentioned above, will appear in the scroll below. Depending on the number of the resources with respect to the subject in HydroShare, it could take a couple seconds to a few minutes.

The resource ID is what you could use in other features of the app like adding a file or downloading a file or even deleting a file from a resource.

Resource ID of the selected Resource:

To try this on your own, you can use the code snippet below, or download the full javascript file that is used in this demonstration.

    
      from hs_restclient import HydroShare, HydroShareAuthBasic
      auth = HydroShareAuthBasic(username='username', password='password')
      hs = HydroShare(auth=auth)

      result = hs.resources(subject=viewr)

      resourceList = []
      for resource in result:
          resourceList.append(resource)

      return HttpResponse(json.dumps(resourceList))