2

I have enabled clean URLS and it is working fine. How ever I have a Panel page with link. the link goes somethinglike this.

<a href="?q=PageName">

Now, Lets say I am on that Panel page(i would think the same thing would happen on any other custom content pages) and let's call it PanelPage and I press the link, The URL end up being, PanelPage?q=PageName (The whole URL = localhost/SiteName/PanelPage?q=PageName).

My Question is, Is there a way to write that link, so that It coume out as Clean URL? SiteName/PageName ?

Please help. Thanks

Oswald
  • 31,254
  • 3
  • 43
  • 68

2 Answers2

0

Use l($text, $path, array $options = array()) to generate links.

Oswald
  • 31,254
  • 3
  • 43
  • 68
  • I am sorry, I am really new to PHP, can you posibly explain the code? Like I'm 5 :D. How would I rewrite the Link example that I have used? – user3808196 Jun 14 '15 at 12:30
0

In drupal 7, after logged in as admin go to following path "Configuration » Search and metadata » URL aliases".

There you can set 'Alias Path' for 'Existing Path'. Add an Alias path for your panel page.

For EX:

Existing system path : http://www.example.com/PanelPage?q=PageName Path alias : http://www.example.com/custom_name.html

Sagar
  • 642
  • 3
  • 14