Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 3.5 > ASP.NET 3.5 Basics
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 3.5 Basics If you are new to ASP or ASP.NET programming with version 3.5, this is the forum to begin asking questions. Please also see the Visual Web Developer 2008 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 3.5 Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 16th, 2009, 06:00 PM
Friend of Wrox
 
Join Date: Sep 2007
Location: , , .
Posts: 169
Thanks: 7
Thanked 2 Times in 2 Posts
Default Need Help with setting up my website url.

Hi

I want to do do some testing with Paypals IPN api but they don't allow you to test it on localhost. So I actually need to set it up somehow so that I can retrieve messages from my computer(otherwise I have to do it on a live server and every change I make I would have to reupload to test what would really suck).

So I have asp.net 3.5 website in VS2008 and I am using the built in webdevelopement thing.

So I tried to launch my site and change "localHost" to my ip address but this does not work. I just get the page cannot be found.

So I am not sure how to set it up.

Like I found this post

http://www.pdncommunity.com/pdn/boar...hread.id=10098

and it talks about this no-ip site so I signed up to it but I don't even know what to do with it. I don't know how to hook it up to my website on local host.

So I am out of ideas.
  #2 (permalink)  
Old March 18th, 2009, 01:03 AM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

If this is for testing purposes, e.g. a development box, you may be able to "fake it" provided you can answer yes to the following items:

You are not on a business network and you have either a Static or Dynamic IP address assigned to you by your ISP.

You are working off of an XP Pro or Vista Business+ Box that has IIS running. (Vista Home MIGHT also be able to run IIS but I forget)

You are able to make changes to your local copy of IIS.

The network that your PC is on is either A) connected directly to a cable modem that does not have a built in Router or B) is connected to the internet via a router. In both cases you (or someone else) need to be able to administer changes to the router (this only applies to secnario A if the cable modem has a built in router).

If you answered yes to all of these you might be able to "fake out" PayPal with a bit of DynamicDNS. Head over to http://www.dyndns.com/services/dns/dyndns/ and click 'Get Started' and create an account (everything we will be doing is completely free). Once you get logged in click on 'Host Services' and then 'Add New Host Name'. One the next screen select a host name. I personally dont use a wildcard alias and don't see why you would need to either. Leave the Host With IP address radio ticked. For the IP address click the 'Use auto detected..." and leave mail routing unchecked then click 'Create Host'. On the next screen just click next and check out. Again this is completely free and will be reflected as such by the 0.00 purchase price.

Once you have completed this step and DNS has refreshed <yourhostname>.domain.com will now point at your box! Now, before you run back into visual studio you will want to do download and install this client on your machine IF your ip address is dynamic (if it is static dont worry about this): https://www.dyndns.com/support/clients/ What this client does is send your current IP information to DynDNS so that your host name is continually resolving to the correct IP address. This is necessary since you have no way of knowing when the lease on your IP address will expire and your ISP issues you a new one.

There are two things left for you to do. If you have a router somewhere on your network you will need to log into your router and redirect all traffic coming to your IP on port 80 to your computer. This is farily trivial with LinkSys routers and don't imagine its to much of a pain with other brands but RTM.

The final thing that you will need to do is setup IIS properly. Since you are using the personal version of IIS you are limited to one website and while there are some tricky things you can do to get the hostname to resolve to a virtual directory but your best bet is going to just test the PayPal coude out of your home directory (by default it is inetpub\wwwroot\). What I would do before you go to all this trouble is drop a simple HTML file into your webroot and goto: http://<yourhostname>.domain.com and see if the HTML file appears (i am assuming here that you have given the file a name so that IIS recognizes it as a default document such as Default.htm or Default.aspx otherwise you will need to specifiy the file name in the URL). If the page does not appear your port forwarding is probably not setup correctly. Again, RTM.

After that, you SHOULD be able to provid that hostname to test the paypal api stuff with. I have never tried it using DDNS but it stands to reason that it should work. One thing though, if it is using SSL make sure that port 443 also redirects to your machine.

hth.
-Doug
__________________
===============================================
Doug Parsons
Wrox online library: Wrox Books 24 x 7
Did someone here help you? Click on their post!
"Easy is the path to wisdom for those not blinded by themselves."
===============================================
  #3 (permalink)  
Old March 18th, 2009, 08:20 PM
Friend of Wrox
 
Join Date: Sep 2007
Location: , , .
Posts: 169
Thanks: 7
Thanked 2 Times in 2 Posts
Default

Quote:
Originally Posted by dparsons View Post
If this is for testing purposes, e.g. a development box, you may be able to "fake it" provided you can answer yes to the following items:

You are not on a business network and you have either a Static or Dynamic IP address assigned to you by your ISP.

You are working off of an XP Pro or Vista Business+ Box that has IIS running. (Vista Home MIGHT also be able to run IIS but I forget)

You are able to make changes to your local copy of IIS.

The network that your PC is on is either A) connected directly to a cable modem that does not have a built in Router or B) is connected to the internet via a router. In both cases you (or someone else) need to be able to administer changes to the router (this only applies to secnario A if the cable modem has a built in router).

If you answered yes to all of these you might be able to "fake out" PayPal with a bit of DynamicDNS. Head over to http://www.dyndns.com/services/dns/dyndns/ and click 'Get Started' and create an account (everything we will be doing is completely free). Once you get logged in click on 'Host Services' and then 'Add New Host Name'. One the next screen select a host name. I personally dont use a wildcard alias and don't see why you would need to either. Leave the Host With IP address radio ticked. For the IP address click the 'Use auto detected..." and leave mail routing unchecked then click 'Create Host'. On the next screen just click next and check out. Again this is completely free and will be reflected as such by the 0.00 purchase price.

Once you have completed this step and DNS has refreshed <yourhostname>.domain.com will now point at your box! Now, before you run back into visual studio you will want to do download and install this client on your machine IF your ip address is dynamic (if it is static dont worry about this): https://www.dyndns.com/support/clients/ What this client does is send your current IP information to DynDNS so that your host name is continually resolving to the correct IP address. This is necessary since you have no way of knowing when the lease on your IP address will expire and your ISP issues you a new one.

There are two things left for you to do. If you have a router somewhere on your network you will need to log into your router and redirect all traffic coming to your IP on port 80 to your computer. This is farily trivial with LinkSys routers and don't imagine its to much of a pain with other brands but RTM.

The final thing that you will need to do is setup IIS properly. Since you are using the personal version of IIS you are limited to one website and while there are some tricky things you can do to get the hostname to resolve to a virtual directory but your best bet is going to just test the PayPal coude out of your home directory (by default it is inetpub\wwwroot\). What I would do before you go to all this trouble is drop a simple HTML file into your webroot and goto: http://<yourhostname>.domain.com and see if the HTML file appears (i am assuming here that you have given the file a name so that IIS recognizes it as a default document such as Default.htm or Default.aspx otherwise you will need to specifiy the file name in the URL). If the page does not appear your port forwarding is probably not setup correctly. Again, RTM.

After that, you SHOULD be able to provid that hostname to test the paypal api stuff with. I have never tried it using DDNS but it stands to reason that it should work. One thing though, if it is using SSL make sure that port 443 also redirects to your machine.

hth.
-Doug
Yes to all the questions you asked. I think i got it to work now with my ip address it was just so weird.

I don't IIS works one min and another minute it does not. First I could not use the debugger in VS to debug I kept getting a error. Every solution I tried till i disablied the loopback address.

I then could not get the ip address to work even with my firewall off. Then all of a sudden it works and now it seems to work. So hopefully it does not corrupt itself or something.

I am also using the trick with multiple iis on windows xps and I think that was screwing something up(it gave it some name or something that I have to always delete after it creates it then the ip can work).
  #4 (permalink)  
Old March 18th, 2009, 09:49 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Awesome! Let me know if you need anything else!
__________________
===============================================
Doug Parsons
Wrox online library: Wrox Books 24 x 7
Did someone here help you? Click on their post!
"Easy is the path to wisdom for those not blinded by themselves."
===============================================
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
URL Redirect based on given URL somnath.kartic VS.NET 2002/2003 1 August 2nd, 2012 08:21 AM
Project URL Setting n7zfi BOOK: Professional DotNetNuke Module Programming ISBN: 978-0-470-17116-5 1 March 3rd, 2009 02:00 AM
URL rewriting with URL forwarding mtabyana BOOK: Professional Search Engine Optimization with PHP: A Dev's Guide to SEO ISBN: 978-0-470-10092-9 0 October 22nd, 2007 08:22 AM
Dynamic website to Static website Aboal3ood ASP.NET 1.x and 2.0 Application Design 4 December 7th, 2006 11:46 AM
extract URL from Favorites (.URL Files) PhilHawks VB.NET 2002/2003 Basics 2 November 2nd, 2004 04:35 AM



All times are GMT -4. The time now is 04:10 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.