I want to create an Sharepoint hosted app but how to access list in these App ??
In SharePoint 2013 when you create any SharePoint Hosted App it will create separate web for the app you created so when you will open your app check the URL there will be
1) SPHostUrl 2) SPAppWebUrl
If you want to access List from SpHostWeb you will have to use Cross Domain Concept to access it.
Follow this MSDN Link it shows how to access List in SharePoint hosted app.
First, you need to use the SP.AppContextSite" instead of default "SP.ClientContext" to get the SharePoint site URL.
SP.AppContextSite used to get the host site URL and SP.ClientContext used to get the app web URL.
Please refer my below link on how to access the list: http://sharepointquicksolutions.blogspot.in/2013/01/is-list-exists-or-not-using-ecmascript.html
Please reach out me for any issue or additional information required.
-Thanks, Sasi Kumar Reddy http://sharepointquicksolutions.blogspot.in