Open local website on computer from phone on same network - mobile

I have a local sandbox website on my computer running on nginx. I have chrome canary and that's what I"ve been using to test the various media sizes. Of course, this doesn't stack up against actual hands-on testing to get an idea of the feel of the website.
So, is there a way to be able to access a website running on my computer from the same network? Even if I have to use a specific app. I would like to use the same URL. dev.mywebsite.com and mywebsite.com run a on a server, sandbox.mywebsite.com is on my machine (this is the one I would like to access). I don't need to access to it remotely, just when I'm on my network is fine.
Note: I need to use the actual URL.
Thanks.

If sandbox.mywebsite.com maps to localhost on your computer, then by mapping sandbox.mywebsite.com in the hosts file of your phone to the local network IP address of your computer e.g. 192.168.1.9, you should be able to access it on the phone.
I have done this using android with hosts editor, connecting to apache running on an ubuntu laptop.
There are also many google results for this, so you may be able to find something there for your specific configuration.

Related

rails server successfully, but can't access in mobile

Iam able to access rails app in all systems with in network, but unable to access in mobiles.
I started app like below
rails s -b ip
Double check if your mobile is in the same network of your server. You can do this either by pinging your mobile device (if it support ping) or doing a network scan using tools like nmap or take a look at your router to see where is your device. If you want to allow all access, the binding ip should be 0.0.0.0.

How to access virtual host made on XAMPP via smartphone?

I have a website running on my localhost, and it is set up as virtual host.
The problem is, it is no problem at all and works really okay on web browser on my computer, but is not accessible from my mobile phone.
Because virtual host is setup on my local, I know it works well when I access via web browsers on my computer.
But then how to access to this on mobile phone?
What I know is that in order to make accessible by mobile phone, it has absolute address by ip address, i.e, http://192.168.0.1/mysite
But due to complicated config made, the site is not working when to access as
http://192.168.0.1/mysite
but only works when
http://dev.mysite.com
(http://dev.mysite.com is the virtual host made on my local which is pointing to http://192.168.0.1/mysite)
Any help will be appreciated.

Mobile Hotspot Replaces Site Address With Incorrect IP

On some of our web apps, when a user connects via a Verizon 5510L Jetpack mobile connection the site address is replaced with an incorrect IP address, and of course throws a 504 error.
Has anyone else ever experienced this? or know why this is happening?
We have other apps that are very similar, on the same server that do not have this issue. Unfortunately this is a popular device with our customer so avoiding the hardware is not an acceptable fix.
As a workaround, the user can connect to the site via a different connection, keep the browser open and connect to their mobile device. This Also is not an acceptable fix as the applications are often used in remote areas.

Monitor URLs accessed by mobile app

I have downloaded an Android app (which is also available for iPhone and ipad). I want to monitor which URLs it is accessing. On the desktop, you can use tools like Chrome dev tools for browser traffic and Charles Proxy (http://www.charlesproxy.com/) for other app traffic. Is there a similar way to set a proxy for the app from outside it, and then view any connection attempts, possibly with headers and responses?
I only need to do it once, to ensure the app isn't malicious, so the process doesn't have to be the most convenient method in the world. For example, it could involve setting up a proxy app on the desktop and then connecting through that, or running the Android or iOS version on a desktop-based simulator and monitoring that.
When searching SO, a lot is to be found on this topic. The best solution seems to be setting up a desktop to be an access point for the android device and run wireshark on it like suggested here
Capturing mobile phone traffic on wireshark
your best bet is charles proxy trial version
to set up charles proxy is like butter
1) Make sure both computer and device are on the same network
2) Download charles proxy on computer
3) On device go to wifi--> connection name--> hold on to it --> modify --> manual proxy --> give your ip address and port 8888
4) keep charles open on computer while you are doing this
5) you will get a pop up in charles regarding the connection and will start showing you the traffic being captured from the app..

Silverlight app - service URL cannot handle IP address

I have a Silverlight app that run on a single server which also hosts the web service used for data access. This is a Service Reference in the project. A common issue is that someone browses to the app using an IP address rather than the machine name. This breaks because the app thinks this is a cross-site violation.
To access the web service we create a System.ServiceModel.ClientBase and assign is an address in the web.config file. So locally in dev this is localhost:xxxx, and in production is it the machine name. Or we could set it to the IP address, but then everyone would have to go to the app using IP address only.
Is there a good way to do this? One issue is that some people access the app internally where the machine has a good name, while others access it through a VPN where they may need to use IP. I would like for both to work.
FYI I had this same issue. silverlight application and wcf service running on same server, but when application is started using an ip address vs. application url, then cross domain problems occur. evidently these urls/ips are not resolved/matched locally so to the silverlight application, they look like different domains. My app is running as an application and couldn't be moved to root of iis web site for technical reasons which is required for a clientaccesspolicy.xml file or crossdomain.xml to work properly.
I solved it by adding an entry into the hosts file on the server with the ip address and name of the domain. This looks a bit strange since we are on the server pointed to by the ip address and the domain/machine name but it works.
Adding this locally in the hosts file evidently redirects all requests for the ip address to the server PRIOR TO making either the call to get the silverlight application or the call the wcf service, so they look the same no matter whether the application or the service is called using an ip address.
Hope this helps anyone else in the future.
FYI - this does not work with VMs
We use VMs for some functionality and I have found this just doesn't work when running clients from the VM. The VM manager must do something to the request before passing it through. Just thought I'd mention this for future use.
Have you tried creating a clientaccesspolicy.xml file?
http://msdn.microsoft.com/en-us/library/cc197955(v=vs.95).aspx

Resources