Wednesday, May 15, 2013

Connect your computer to a domain



A domain is a collection of computers on a network with common rules and procedures that are administered as a unit. Each domain has a unique name. Typically, domains are used for workplace networks. To connect your computer to a domain, you'll need to know the name of the domain and have a valid user account on the domain.
  1. Open System by clicking the Start button Picture of the Start button, right-clicking Computer, and then clicking Properties.
  2. Under Computer name, domain, and workgroup settings, click Change settingsAdministrator permission required If you're prompted for an administrator password or confirmation, type the password or provide confirmation.
  3. Click the Computer Name tab, and then click Change. Alternatively, click Network ID to use the Join a Domain or Workgroup wizard to automate the process of connecting to a domain and creating a domain user account on your computer.
  4. Under Member of, click Domain.
    Picture of the Computer Name/Domain Changes dialog boxThe Computer Name/Domain Changes dialog box
  5. Type the name of the domain that you want to join, and then click OK.
    You will be asked to type your user name and password for the domain.
    Once you are successfully joined to the domain, you will be prompted to restart your computer. You must restart your computer before the changes take effect.

Thursday, May 9, 2013

Cross domain Ajax request



The only (easy) way to get cross-domain data using AJAX is to use a server side language as the proxy as Andy E noted. Here's a small sample how to implement that using jQuery:
The jQuery part:
$.ajax({
    url: 'proxy.php',
    type: 'POST',
    data: {
        address: 'http://www.google.com'
    },
    success: function(response) {
        // response now contains full HTML of google.com
    }
});
And the PHP (proxy.php):
echo file_get_contents($_POST['address']);
Simple as that. Just be aware of what you can or cannot do with the scraped data.