8 replies
How do I do this?

"If you want support for SEF (Search Engine Friendly) URLs, you'll need mod_rewrite and the ability to
use local .htaccess files."

Thank you in advance for any help that may be offered.
#modrewrite
  • Profile picture of the author zoobie
    well it is a too broad question, what kind of system are you using? are you using a CMS or a shopping cart for your website? Different system may need to do different things and you need to provide a more specific question in order for me to find a solution for you...
    thanks..
    {{ DiscussionBoard.errors[782590].message }}
  • Profile picture of the author Solidsnake
    Banned
    Originally Posted by Web Dummie View Post

    How do I do this?

    "If you want support for SEF (Search Engine Friendly) URLs, you'll need mod_rewrite and the ability to
    use local .htaccess files."

    Thank you in advance for any help that may be offered.
    Are you using FTP?

    If you are using your FTP, look for .htaccess file and change the permission to writable.. or just change it to 777..

    If you are not using FTP you can do the same inside Cpanel..

    let me know then..
    {{ DiscussionBoard.errors[782591].message }}
  • Profile picture of the author stevenh512
    If you're paying for hosting you should already have mod_rewrite and the ability to use .htaccess files. I don't know of any paid Linux hosts that don't let you edit the .htaccess file and use mod_rewrite.. especially cPanel hosts since half of the scripts you can "one click install" require mod_rewrite for search engine friendly URLs.
    Signature

    This signature intentionally left blank.

    {{ DiscussionBoard.errors[782596].message }}
  • Profile picture of the author Solidsnake
    Banned
    Contact your hosting support if you don't really know what to do... My host support always responds within 2 to 3 hours..
    {{ DiscussionBoard.errors[782646].message }}
    • Profile picture of the author Aaron Sustar
      In a large majority of cases you already have your Mod Rewrite (and .htaccess) enabled and you can start doing some magic ...

      Basically it looks like this - you have a folder with your website on the server and this website has a page "yourwebsite.com/index.php?page=23", but you want to make it look like "yourwebsite.com/affiliate-program". To do this you can simply put a .htaccess file in this very folder and put this in the file:

      <IfModule mod_rewrite.c>
      RewriteEngine On
      RewriteRule ^affiliate-program$ index.php?page=23
      </IfModule>

      From now on, you can find that page at "yourwebsite.com/affiliate-program". But .htaccess (and Mod Rewrite) allows you to do so much more, so try to find some literature about that online and you will be able to go a long way with URL SEO.
      {{ DiscussionBoard.errors[782690].message }}
      • Profile picture of the author Web Dummie
        Thank you all for your help, especially Aaron who gave me a "dummies" explanation of how this works. You made it simple for me.

        Who created this system of files and how they communicate anyway? This is nuts! .htaccess, .zip, .gz, .php, .htm, .html, .inc, .gif, .jpg, .com, .net, .xml, etc...

        Sorry to be so vague Zoobie,

        This is a direction in my admin panel for Joomla. So a linux based box running a CMS, but I would like to learn more about this so I can capitalize on this feature in multiple environments. This site will have a shopping cart in the near future.

        Even if I had this in my first hosting account Steve, I had no clue what it was or how to find it, let alone how to use it to my advantage.

        Yes, using FTP snake. Could you make me aware of what files are ok to leave at 777 and which files are not. There was a local web host here in town who got his server hacked due to one of his customers leaving the wrong file set to 777. The hacker got in to more than one of his clients site and did some damage. I was one of em.

        Thanks again!
        {{ DiscussionBoard.errors[785607].message }}
        • Profile picture of the author Aaron Sustar
          Originally Posted by Web Dummie View Post

          Thank you all for your help, especially Aaron who gave me a "dummies" explanation of how this works. You made it simple for me.
          Always glad to help.
          {{ DiscussionBoard.errors[794403].message }}
        • Profile picture of the author stevenh512
          Originally Posted by Web Dummie View Post

          This is a direction in my admin panel for Joomla. So a linux based box running a CMS, but I would like to learn more about this so I can capitalize on this feature in multiple environments. This site will have a shopping cart in the near future.
          With Joomla, there should be a file called htaccess.txt you would just rename that file to .htaccess on your host. Make sure you read it first because there's one line in the file that may or may not cause an error depending on how your host is set up (the file tells you which line, if it causes an error you can just delete that line in any text editor or comment it out by putting a # in front of it). Once you have that file installed and it isn't producing an error 500 page, just go to Global Configuration in your admin panel and turn on Search Engine Friendly URLs and Use Apache mod_rewrite (that's from the 1.5.10 admin panel, not sure about any other version).

          Even if I had this in my first hosting account Steve, I had no clue what it was or how to find it, let alone how to use it to my advantage.
          It's a feature that's available on most Linux hosts (and even some Windows hosts who use Apache instead of Microsoft's server), any cPanel host should have it enabled by default, some hosts (mostly "free" hosts who use it to force ads on your pages) will have their servers set up so you can't modify .htaccess, but you should be fine with any paid hosting.

          Could you make me aware of what files are ok to leave at 777 and which files are not. There was a local web host here in town who got his server hacked due to one of his customers leaving the wrong file set to 777.
          On some servers, 777 isn't required at all, check with your host. In general, on a server where you do need the 777 permissions.. only files and directories that your script absolutely needs to write to should be set to 777. Any .php files (since they execute code on the server) should not be 777 unless they absolutely need to be.
          Signature

          This signature intentionally left blank.

          {{ DiscussionBoard.errors[796795].message }}

Trending Topics