I'm going to make an Android app for my university that in my app's login page the user or student could type his/her student code and student password and by clicking "log in" the app takes him/her to his/her own portal on website!
I've watched many tutorials but all of them used JSON Parsing.
Our university website doesn't have JSON file so I want to try to connect to HTML code of log in page straightly and by the way university won't let me to connect to website database.
Basically I just want to know how to connect my app's login page to that login class of website HTML code!
Here is the webpage, you can see what I said here by just right clicking and selecting "view page source" in chrome:
http://puya.toos.ac.ir/gateway/PuyaAuthenticate.php
What you can do is , call the same page as you call http get service after getting the response , parse the html response.
For this specific case , you can login and track the script being called for login post request , call the same script by posting the required data as http post service . After authentication parse same result . Basically you will do all the parsing which browser do for you , and you have to present parsed data in meaning full manner .
You can also use webview for easy parsing and presentation.
Simulate your request by tracing every step of your website.
Related
In browser based web application(java), UI pages are served from web server . For example :- JSP are converted to HTML and then sent back to browser.
How does it work in Android Mobile Application ? Say i have a some mobile application whose home page has Employee Detail button. When i click on this button , I should be
navigated to new UI page(say Detail page) which should displays employee details.
Mine understanding :- On server side there will be restful API that will receive the http request and send the just Employee details in form of json. It will not send any UI
page. UI page(detail page) should already present inside mobile app. Now when i click the get detail button, i will be navigated to detail page . Now android API will fill
data i received from server in to that page. Is this correct ?
On server side there will be restful API that will receive the http request and send the just Employee details in form of json
It would not have to be JSON, though that is a typical response format for a Web service.
UI page(detail page) should already present inside mobile app
"Page" is not an appropriate noun here. Most GUIs do not use the term "page" for units of their user interface, as that is mostly used in Web apps. Desktop and mobile GUIs have other units of user interface: windows, screens, etc. In Android, the coarse unit of user interface is the Activity.
But, terminology aside, you are correct that normally a mobile app has code that will take the Web service response and use that to display results to the user, by one means or another.
Now when i click the get detail button, i will be navigated to detail page .
How navigation works is up to you and can take many forms.
This is no different than in a Web app. In a Web app, when the user clicks a button, the user might go to a different Web page, or might not. In the latter case, JavaScript code in the existing Web page might make a Web service call and update the contents of the current page.
The same thing is true for desktop and mobile programs.
Now android API will fill data i received from server in to that page
Some programmer's code will take data that the code received from the Web service and use that in the user interface, by one means or another.
How can I customize the look and feel of my registration email? In my Parse dashboard, it asks me to upload templates to my "server". I don't have a server for my app. It's fairly basic and depends solely on Parse for my back-end.
Can I just provide a link from, say, a GoDaddy hosting account to the specified HTML template pages provided?
Customize User-Facing Pages
These are the pages your users visit when resetting their password or
verifying their email addresses. You can customize the look and feel of
these pages by uploading a modified copy to your server and telling us
their locations.
Hide Parse.com URLs
By uploading this file to your server and entering its address below,
you can hide parse.com from your users. This page is an iframe for Parse
that lets your domain be the front-end to our back-end.
Yeah, this was really easy.
Just download the provided template files from your Parse.com Dashboard under Settings > Email, then upload them to your server (web host, i.e. GoDaddy).
Where it says /app/password_reset_success.html, etc., replace that entire line with a link to that same file on your server.
I am trying to get html code of specific page in facebook but the problem is that my code gives me the html of no-user in facebook.
String html = Jsoup.connect("https://www.facebook.com/mor.amit.3/about").get().html();
System.out.println(html);
For example when i try to do it, it gives me her page but from side of no-facebook user.
how can i use this code and look on her profile from user side?
you can't get birthday ,education or some specific information without login to facebook because of privacy settings of Facebook user.for example if you logout from fb and view that profile .you will get this .so there is no information about birthday .you have to log to fb using java then you will be able to download expected page
I'm developing a Dynamic web Project in java, and the goal is upon click on button to fetch the "ITERATION BURNDOWN" graph from https://rally1.rallydev.com.
my question is do i have to know the rally api in order to get this content or just to go to the appropriate url and search there the graph?
i login successfully to the rally (used this link for the login: http://www.mkyong.com/java/how-to-automate-login-a-website-java-example/).
after i login successfully i couldn't get the url with the graph. it's just returning the landing page content.
pls help,
Thanks
I assume that you refer to IterationBurndown on Reports>Reports page, which is served by a legacy analytics engine.
To get the appropriate URL you may need to install IterationBurndown report wrapped in an app from AppCatalog on a custom page in Rally. I cannot confirm a java scenario, but the URL of that custom page can be used with javascript, by making an html file with this custom page embedded using iframe, for example:
iframe.src = "https://rally1.rallydev.com/#/12345d/custom/6789";
The steps are:
create a custom page
install IterationBurndown report from the AppCatalog as an app.
At least in the javascript app case, the URL to IterationBurndown on Reports page will not work for this purpose, hence the extra step of using a custom page.
When you say that you get a landing page, I am not sure if you are referring to login page or home page. If it is the former, it means authentication has not been handled. Legacy IterationBurndown report wrapped in an app will not work with newer ApiKey. That's too bad because ApiKey, unlike LoginKey, works with Java as well, unlike the legacy LoginKey which works in the browser (with html/javascript apps) only.
I'm using the selenium page object model to test a website. We have access to the sandbox PayPal account which allows us place test PayPal orders with a mock account.
My problem is on the sandbox PayPal login screen when I click login with the account I have created some java script (I'm guessing) displays an animation saying "Authenticating your information Logging you in"
When this happens my page fails because the is loaded() is expecting the url to be different but because the page doesn't start to load the next page until after this javascript completes the url is not correct.
I could stick a hardcoded wait for this login to take effect but does anybody know a better / proper way to handle this?