Jump to content



Welcome to KnowledgeSutra - Dear Guest , Please Register here to get Your own website. - Ask a Question / Express Opinion / Reply w/o Sign-Up!
- - - - -

Joomla Edit .htaccess To Friendly Html Mod Rewrite


6 replies to this topic

#1 Sarkara

    Newbie

  • Kontributors
  • Pip
  • 4 posts

Posted 09 February 2010 - 03:58 PM

Ok guys i have a question. i'm using joomla and i need to change the urls from looking like:
index.php?option=com_content&view=article&id=1 
index.php?option=com_content&view=category&id=13 
index.php?option=com_content&view=section&id=1
to nice looking html extensions...I'm relativlely new to htaccess and sort of a noob at this.. :)

any help will be much appreciated

#2 shadowx

    Live your life so that in death you may stand side by side with your gods. Not at their feet.

  • Kontributors
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1,674 posts
  • Gender:Male
  • Location:Essex, UK
  • Interests:Photography is a big interest, i have some photos up at my site, apex photographs (http://apex-photographs.com). Using my Lumix g1 to take the photos of course! <br /><br />Um computer games... photo editing and thats about it!
  • myCENT:68.57
  • Spam Patrol

Posted 09 February 2010 - 04:17 PM

Here we go:

http://www.webweaver...direction.shtml

The first little example is what you need :)

Just type something like:

Redirect 301 /blog index.php?option=com_content&view=article&id=1 
Redirect 301 /contact index.php?option=com_content&view=article&id=2 
Redirect 301 /about index.php?option=com_content&view=article&id=3

Then if i go to yoursite.com/blog it will send me to yoursite.com/index.php?option=com_content&view=article&id=1

Note: Search engines dont like 301 redirects.... So it wont be the best method for your SEO but for a user it is so much better to remember /blog than /index.php?option=com_content&view=article&id=1 etc...

Edited by shadowx, 09 February 2010 - 04:18 PM.


#3 shadowx

    Live your life so that in death you may stand side by side with your gods. Not at their feet.

  • Kontributors
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1,674 posts
  • Gender:Male
  • Location:Essex, UK
  • Interests:Photography is a big interest, i have some photos up at my site, apex photographs (http://apex-photographs.com). Using my Lumix g1 to take the photos of course! <br /><br />Um computer games... photo editing and thats about it!
  • myCENT:68.57
  • Spam Patrol

Posted 09 February 2010 - 04:48 PM

Ah ok, its something ive only used once as a little test to run a .htm page as a .php, but this link should see you straight: http://www.yourhtmlsource.com/sitemanageme...ml#introduction

#4 Sarkara

    Newbie

  • Kontributors
  • Pip
  • 4 posts

Posted 09 February 2010 - 04:58 PM

Unfortunatly what i need is a rewrite and not a redirect. I need to follow seo protocols for the company i'm working for. Any tips or help on rewrite?

#5 Sarkara

    Newbie

  • Kontributors
  • Pip
  • 4 posts

Posted 09 February 2010 - 05:16 PM

I've looked at this website yesterday and it to doesn't give me the information i need. i'm using RewriteRule ^([^.]+)\.html$ $1.php [L] to rewrite the php of these urls:
index.php?option=com_content&view=article&id=1
index.php?option=com_content&view=category&id=13
index.php?option=com_content&view=section&id=1
to look more like a html hierachrical structure.. :/index.php/en/component/content/article/6-web-marketing/75-organic-website-submission-and-search-engine-optimization-seo.html

maybe what i'm trying to is more complicated because i'm using a cms.

#6 Sarkara

    Newbie

  • Kontributors
  • Pip
  • 4 posts

Posted 09 February 2010 - 05:24 PM

ok finally i'm trying to use these rewrite rules:
RewriteRule index/option/(.*)/view/(.*)/id/(.*)/catid/(.*)/Itemid/(.*)/lang/(.*)/ index.php?option=$1&view=$2&id=$3&catid=$4&Itemid=$5<=$6
RewriteRule index/option/(.*)/view/(.*)/id/(.*)/catid/(.*)/Itemid/(.*)/lang/(.*) index.php?option=$1&view=$2&id=$3&catid=$4&Itemid=$5<=$6					
RewriteRule index/option/(.*)/view/(.*)/id/(.*)/ index.php?option=$1&view=$2&id=$3
RewriteRule index/option/(.*)/view/(.*)/id/(.*) index.php?option=$1&view=$2&id=$3
but they don't seem to be working as i want them to...any clues?

#7 BuffaloHelp

    Sterling Archer

  • Kontributors
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 4,088 posts
  • Gender:Male
  • myCENT:50.18

Posted 10 February 2010 - 03:05 AM

According to a search, Joomla has builtin friendly URL setting.

Read this article http://www.siteground.com/tutorials/joomla...mla_sef_url.htm and see if you can fix your situation. Delete any alteration or modification you have performed and try the suggestion.

In case the site does not exist in the future, here is the snapshot

Posted Image




Reply to this topic


This post will need approval from a moderator before this post is shown.

  


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users