ForumsProgramming ForumQuestion about Internet

12 2738
_Spaz_
offline
_Spaz_
143 posts
200

I browsed the net a little bit and could not find the answer to this question:

Is it possible to have your own sort of "internet" where only certain people can go onto a server or something of that sort. Is there something similar to my question? Please point me in the right direction.

Thanks,

Spaz

  • 12 Replies
jeol
offline
jeol
3,845 posts
6,080

Yes and no, and the answer may be a little complicated.

You can obtain some domain and subdomain (pay or free, though pay allows you to do more) and set it up so that only those with a certain username and password in your database can access it. You'd have to have a good base in PHP and MySQL though, being the easiest options and usually you have a lot of help if you need it.

You can also set up a network (sort of like a LAN [Local Area Network, within your own wifi access point) that only those in your network can access. If you get a separate hard drive connected to the router, this becomes especially easy, sort of. You can have just a bunch of HTML files interlinked, or if you want an actual server, download something like UniServer and get it all set up so that you can setup and use PHP and MySQL and Apache all at the same time. As long as you can connect to it through the router, anyone in your network can connect to it.

I'm not sure if there are really any options outside of that. You could probably set up some complex network alongside the Internet that you all can connect to if you're on seperate networks, but it may be plenty easier to actually build the site with PHP and MySQL and require a username and password to actually get into the site.

In that case, if you're not going to be using the site outside of general use and you don't care for ads or anything of the sort, you can get your hands on a free subdomain on which you can possibly set it up. One thing that you'll have to keep in mind, though, is that often free subdomains don't have as much flexibility as if you paid for a server. I used a free one for a while until I found out that even though it said it could use MySQL, it was incredibly limited and I could hardly even get a database set up on it. Then my brother gave me a subdomain of his own domain, so I still don't pay but I get much more flexibility. :P If you're going to be spending a lot of time investing in the site, though, I suggest paying for a domain (unless you can convince a friend to lend you a subdomain). You'll get a much simpler URL to learn as a bonus. :P

Salvidian
offline
Salvidian
4,229 posts
2,255

The easiest thing to do would be to just set up IIS. Every Microsoft computer has it. Go to Control Panel > Programs and Features > Turn features on or off (Left side of your window) > Internet Information Services. If you have an old computer, it'll say PWS instead of IIS. If you have a Mac, you're screwed, sorry. This will enable servers within your computer and network. I did it while learning ASP, which is virtually a dead language now (lol). From there on you can set up an Intranet network and, if you know how to code anything at all, code pages through notepad and save them as an .html file.

That's a rough way to do it, but you can literally do anything, like sharing files, creating your ow web pages for use between your computers, and if you're really advanced you can view any computer in your house, as long as it's connected to the internet. If you want, you can even stream music to video game consoles.

To physically connect your computers together, you'll need to connect them to the network wirelessly as long as you have the ability to connect to wifi. Instead of connecting to the wifi internet, connect to your network, which should be listed right by your internet. If you need to do it with wires, I'm pretty sure Ethernet cables work fine. You'll need one of those splitty-things.

Other than that, jeol pretty much covered everything else.

_Spaz_
offline
_Spaz_
143 posts
200

Any links to detailed instructions? I appreciate all this help by the way. The only reason I would want this is so me and some friends can connect to our own network and do anything you could do (file sharing, IM, etc.)

jeol
offline
jeol
3,845 posts
6,080

If you're wondering about programming websites, that's a bit of a hobby to get into. First you might want is a good text editor.

There are two that I've used in the past that I really like. First is Notepad ++. Think Notepad, but about a thousand more features that are much nicer for web development. Another good one that I use currently is Sublime Text. It has a handy little bar to scroll through a really long document and I like the color schemes it provides. It's also cross-platform, which can be nice if you're using a non-Windows computer (I actually have Windows 8 consumer preview downloaded on the computer I use, so I can't even use Notepad ++ - this one still works, though, and works great).

Next is to find a good site to learn HTML on. W3Schools is good for learning the very basics, but when you're getting into more indepth programming (like PHP and MySQL and Javascript and such) I wouldn't suggest it. If you want video tutorials, you can listen to this guy talk. I haven't looked much at his tutorials, but my friend really likes him. Those sites should be enough to get you past HTML and CSS. Practice, a lot. If you get a subdomain or some website that actually connects to the Internet, I suggest checking to see if it's right with this nifty thing.

Once you get ready for much more indepth *cough*actual*cough* programming, I would even look back at W3Schools and New Boston to get the very basics down. If you want to get serious, though, I suggest getting a book on PHP, MySQL, and Javascript (and HTML5 and CSS3, but you could even learn that stuff on W3Schools). I'm working through this book right now, and it seems to have a lot of useful information as well as directly confronting what you asked in the OP. Plus, it has squirrels on the cover, soo...

I already mentioned UniServer, so if you get that you should be set.

Of course, if you want a really cheap way out, you could just get something like UseBB Forums to communicate. As for simply file sharing, I suggest Dropbox (technically, you could do all of the HTML stuff on Dropbox too, though I don't know if you can actually run a server on it). Does that answer your question, or did you have something else in mind?

_Spaz_
offline
_Spaz_
143 posts
200

Well, I guess I forget to mention I know HTML...lol. Funny thing is I thought to myself to start java script which I just started and then from there I will learn PHP and mySQL

Salvidian
offline
Salvidian
4,229 posts
2,255

I'd learn PHP first. Javascript is more for each individual page, but PHP is more for networks and servers. Besides, if you do something like add a chatbox in through Javascript, your friend won't be able to access it if it isn't connected to a network. PHP allows you to connect pages to networks through code, which is phenomenally useful in further network and server building. After all, you wanted to set up your own "internet," and PHP is an awesome tool to do it with.

Notepad ++ is awesome. If you want to build stuff from scratch, go with it. jeol is right there.

W3Schools isn't bad for HTML, as HTML is for beginning beginners, but it isn't great for CSS. It gives you the jist on how it works, but you'll never get to do anything with it that you couldn't already do with HTML. Then again, there are a lot of websites out there that don't do a justice for what CSS can do.

_Spaz_
offline
_Spaz_
143 posts
200

I went on W3schools (that's where I learned HTML) and in the introduction it suggested that I learn Javascript and HTML before starting PHP...so should I completely ignore that suggestion? Would Javascript make it easier to learn PHP?

AceofSky
offline
AceofSky
768 posts
1,980

Any links to detailed instructions? I appreciate all this help by the way. The only reason I would want this is so me and some friends can connect to our own network and do anything you could do (file sharing, IM, etc.)

Judging from only this quote, instead of setting up a detailed server you could take the shortcut and use a program like Team Viewer for file sharing, IM/chat, and even controlling the other person's computer. (With their approval of course).

If that is not the way you want to do it then follow Salvidian's and Jeol's advices.
_Spaz_
offline
_Spaz_
143 posts
200

TV is an amazing tool, but this would be a personal project that I want to create for my personal friends. I guess it would work just like TV! Thanks for the suggestion!

jeol
offline
jeol
3,845 posts
6,080

I'd learn PHP first. Javascript is more for each individual page, but PHP is more for networks and servers. Besides, if you do something like add a chatbox in through Javascript, your friend won't be able to access it if it isn't connected to a network. PHP allows you to connect pages to networks through code, which is phenomenally useful in further network and server building. After all, you wanted to set up your own "internet," and PHP is an awesome tool to do it with.

I went on W3schools (that's where I learned HTML) and in the introduction it suggested that I learn Javascript and HTML before starting PHP...so should I completely ignore that suggestion? Would Javascript make it easier to learn PHP?

@Sal: I sort of agree with you. There's some things to keep in mind.

PHP is mostly used for performing server-side scripts like connecting to a database and using scripts you don't want someone to see, which also prevents people from getting past security measures you might have set up if you do it correctly. That said, anything that actually happens with PHP is on the server side rather than in the Client's browser. This is nice, but can also be a pain when it comes to a few things.

JavaScript is nice for client side actions, but given that it can easily be viewed by the client it is not suggested for use as any security measures can be passed much easier. That said, JavaScript is much nicer for certain functions that mostly involve visual actions. This includes HTML5 elements (mostly the canvas tag, which is used to display HTML5 games) and is also what is behind jQuery and other functions to be called while the client is using the site (say, if you hover over or click a certain element that is supposed to play a sound or expand, et cetera). The nice thing about JavaScript that is a pain with PHP is that certain background functions, like time, interpret from the client's system and not the server. Thus, if the client is on the West Coast accessing a server on the East Coast, if you're using PHP to call the time, it will display the server's time which would be 3 hours fast. If you're using JavaScript, it will use the client's time, so there would be no worrying if the time displayed would be right or if you have to make a specific form just to make sure that the client can access the right time.

That said, another useful function in JavaScript would be Ajax. Ajax allows the JavaScript to communicate with the server whenever it's called. This is used on Facebook (how the news feed updates without having to refresh the page) and many other sites as well, and can be a useful tool on forums because the user can see when someone posts without refreshing the page and finding out he got ninja'd, or post and it automatically posting without having to refresh the page, etc. Google also uses this to check if the username you want has been taken or not.

Aside from all of that, I think you can learn one and pretty easily grasp the other. The only true difference would be the syntax, as well as how you use it - but most of how it's formed is similar. The way functions, operators, and variables work is pretty universal, though they may require a different way of formatting. I wouldn't worry too much about it. Learn whatever you think most applies what you want to learn, and the other should come easily enough.
jeol
offline
jeol
3,845 posts
6,080

Werp, forgot to talk about this.

W3Schools isn't bad for HTML, as HTML is for beginning beginners, but it isn't great for CSS. It gives you the jist on how it works, but you'll never get to do anything with it that you couldn't already do with HTML. Then again, there are a lot of websites out there that don't do a justice for what CSS can do.

I suppose I agree with you there. Most of my learning was wondering how a certain site did it, looking at their code, going 'oohhhhh,' and trying to apply it to practice with it and understand how it works. Some sites (like AG2 is, I think) like to use pictures rather than coding. However, I like showing that I have the skill to code something and have it work the way I want it to.

That said, IE is possibly my biggest Achilles Heel since most of the earlier versions of IE - which it seems those who have somewhat obsolete computers have to use the earlier versions very often use (but they still won't get a browser that actually is advanced from the early IEs and function on those computers) - it makes it really hard to develop your website for a majority of the population to enjoy. I know AG has had some problems involving IE in the past.

IE8 and previous versions might have a little CSS3 and HTML5 support, but the lack of what they do support is a bit staggering. I couldn't even create rounded edges on tables before IE9, and probably many people still haven't upgraded to IE9 *cough*becausethey'reignorant*cough*. I haven't really attempted to make any websites that can be distributed for the whole World Wide Web to judge yet. I have looked a bit into support for it, but it still practically looks like crap in IE. *sigh*

That said, explore, take notes, and practice what you see. Perhaps look at a more organized site's code and see what sort of CSS options they use. (Google and AG are not really suggested, since most of the code is on one line, which looks pretty sloppy but is easier for adjustment and... Iduno. Most of what you may notice, though, are visually obvious, so it just looking for something that pops out at you would probably be enough.)
_Spaz_
offline
_Spaz_
143 posts
200

Thanks! I will really look into this!

Showing 1-12 of 12