Jump to content
xisto Community

Emerald Green

Members
  • Content Count

    7
  • Joined

  • Last visited

  1. It would depend on your web server's configuration. Apache, for instance, has a configuration directive: DirectoryIndex index.html index.htm index.php With this configuration, Apache will first look for a file called index.html. If it can't find one, it will try to find index.htm. If it still can't find one, it tries index.php. But if they were in a different order, Apache would search for them in that order instead. I'd think most servers these days would have index.html before index.htm, but you never know. As for .html vs .htm, who cares? I personally prefer .html, but I'm quite surprised at the number of people who consider .htm "not professional" and "lazy". It does exactly the same thing, so what's the problem? Most JPEG files are saved as .jpg, rather than .jpeg - is that unprofessional and lazy?
  2. Personally, I like PHP Designer. I never warmed to HTML-kit. But I wouldn't use either alone. For my web design and coding, I usually use a combination of PHP Designer and AceHTML Freeware. PHP Designer for coding PHP-heavy pages, and AceHTML for pages with little or no PHP and for syntax-checking PHP-generated pages. AceHTML has a lot of really nice, creative features for working with HTML, and I find the two programs complement each other well.If you haven't used either PHP Designer or HTML-kit much yet, I'd say go ahead and install them both. Try them out, play with them, see what works for you. Because what works for me or for Houdini or for anyone else might be totally wrong for you.
  3. Like everyone else has said, there's no such thing as a "best" programming language. Every language has its own strengths and weaknesses.I've used BASIC (first Atari BASIC - that was how I started programming - then Visual Basic), VBscript for ASP, and PHP. I've also dabbled in Java and C/C++.Obviously, Java and C/C++ are more powerful languages. But, going on the ratio of ease-of-learning to power, I'd have to say my favourite is definitely PHP. I learnt it in a snap. I was particularly impressed with how easy it was to connect to a database through PHP. I spent hours trying to manage it with ASP (it probably would have been a lot easier if I'd had MS Access, but I didn't - I was left struggling with ODBC). But when I tried to do the same thing in PHP, it just worked! That sure gave it the wow factor for me. Of course, building your GUI in HTML makes things a lot easier. And PHP can do a lot. It does everything I want it to. What more can you ask?But I'm not going to be running around proclaiming PHP as the One True Language to which thou all shalt switch. It's a scripting language. And although it's made some slight movements towards becoming a "real" programming language, it will never do the sort of stuff that C/C++ can. That's why I'm learning C++ now.
  4. Okay, I've been having a look at your code and playing about with it, and I've got it working now. But there are several things that need fixing. I'll try to make it all as clear as possible. First of all:
  5. The point of that site is that it has no point. Why did the designer create it? Because s/he could. Does s/he need a better reason? It's just for fun - and see, we all got lots of fun out of it. Look how long this thread is.(Anyway, I've seen websites a lot more pointless than that one...)
  6. Do you mean that this is something you should do, or shouldn't do? Using .inc for PHP included files can be a security risk, because the server won't send .inc files to the PHP parser unless you specifically set it to do so. If you don't set it to parse .inc files, and a hacker happens to call up one of your include files, the file will be sent to the hacker as plain text, showing them your code. At the best, they could steal your code. At worst, they could discover a weakness in your code (or even something like your database login) and use it to hack your site. If you want to differentiate included files, it's probably best to name them something like filename.inc.php or filename_inc.php.
  7. They were probably PHP files (or a similar technology, like ASP or JSP) using a .html extension for whatever reason. I know that a certain book on PHP recommends naming your PHP files with .html extensions to mask your use of PHP, thereby making your site just a little tougher for hackers. But I have to agree with vujsa and mastercomputers - it's better to name files as what they are. If they were static HTML files, they must have had some sort of client-side script using the variable(s). Plain HTML can't do anything with variables - it's a markup language, not a programming or even scripting language. As far as I know (but my knowledge here is small - correct me if I'm wrong), Javascript doesn't have a native function for extracting variables from a URL. You could write a script to do it manually, though, if you really wanted to. Incidentally, forcing an extension to parse as PHP doesn't necessarily have to be done in .htaccess. If you have access to your server configuration file, you can add the option there, which will change the setting for your whole website, not just the folder you put .htaccess in. Changing the server configuration globally isn't always desirable or feasible (as, for instance, when you are using a free web host!) but it's more efficient than using .htaccess.
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.