Help. Testing on Local Host

By dareme at 2016-04-11 • 0 collector • 1144 pageviews

Anybody here testing it on localhost? i mean the android app .Does anyone help me on how. 


Thank you guys.


14 Replies | Last update 2016-04-15
2016-04-11   #1

please help me. 

2016-04-11   #2

the website run smooth but the android app wont connect.

2016-04-11   #3

You can bind the LAN IP of Server as domain name for the API, such as 192.168.1.1.

qq 20160410191351

Just like this.

2016-04-12   #4

my ip address? or my Default gateway?

2016-04-12   #5

Reply to #4 @dareme :

Your IP address.

2016-04-12   #6

Hey i just try to put it online and it's work the website, well of course the api and the mobile version i create a subdomain. But when i try in android app Toast message always Network error


APIAddress:

public static final String DOMAIN_NAME = "daremee.net.com" + WEBSITE_PATH;
public static final String MOBILE_DOMAIN_NAME = "m.daremee.net.com" + WEBSITE_PATH;
public static final String BASIC_API_URL = "api.daremee.net.com" + WEBSITE_PATH;

Untitled.png

htaccess for API


#强制重定向到带www的顶级域名
RewriteEngine On
RewriteCond %{HTTP_HOST} ^daremee.net.com$ [NC]
RewriteRule ^(.*)$ http://www.daremee.net.com/$1 [L,R=301]
#For SSL 
#RewriteCond %{HTTP_HOST} ^daremee.net.com/$ [NC]
#RewriteCond %{SERVER_PORT} 80
#RewriteRule ^(.*)$ http://www.daremee.net.com/$1 [L,R=301]
#RewriteCond %{HTTP_HOST} ^api.daremee.net.com$ [NC]
#RewriteCond %{SERVER_PORT} 80
#RewriteRule ^(.*)$ http://api.daremee.net.com/$1 [L,R=301]


2016-04-13   #7

Reply to #6 @dareme :

public static final String DOMAIN_NAME = "http://daremee.net.com" + WEBSITE_PATH;
public static final String MOBILE_DOMAIN_NAME = "http://m.daremee.net.com" + WEBSITE_PATH;
public static final String BASIC_API_URL = "http://api.daremee.net.com" + WEBSITE_PATH;
http://


2016-04-13   #8

i tried putting http:// but it wont work. it say Network Error



Untitled.png

2016-04-14   #9

Reply to #8 @dareme :

Have you resolve the API domain name?

2016-04-14   #10

yes ofcourse. i just create sub domain api.

2016-04-14   #11

Reply to #10 @dareme :

Try accessing the API domain name in your Android browser and take a screenshot.

2016-04-15   #12


here the screenshot


13010042_1095546463838666_733459148_o.jpg



2016-04-15   #13

when i go to my main domain and login. and go to api domain and enter my user and pass it wont log in me . my user and pass is correct but it said wrong password. and when i try to go in my mobile domain the style is just like website it not mobile style. and when i go to main domain my avatar is D stand for 'Dareme' but when i goto mobile site the avatar is letter K 

2016-04-15   #14

Reply to #13 @dareme :

Are you setting up your API domain on the dashboard?

Check again. 

Requires Login

Loading...