Adding rules to url rewrite

FLUXrider

Joined: 2006-05-18
Posts: 49
Posted: Tue, 2006-12-19 01:06

I'm about to try and learn enough about whats going on here to try and fix this , but in the hope that someone has already faced this and solved it I'll post my issue first. My only real issues with Gallery2 have always centered around the urls. I've managed to solve all others .
I have Gallery2 embedded into Drupal. My Issue -
I have a link in the drupal primary links which opens the latest pictures in gallery thanks to the excellent updates module. The updates module has a very nice short url eg: /updates/?g2_itemId=7. No problems with that url used as is or with alias.
The latest comments url however is another thing all together. The url generated is huge and complicated and full of ampersands. Its to long in fact to even use url alias in drupal
c/view/7.html?g2_return=%2Fhome%2Findex.php%3Fq%3Dgallery%26g2_0%3Dgallery&g2_returnName=album
WOW. Thats some url .
The difference between the two seems to be that the Updates module has a entry in the url rewrite rules which gets rid of all the url garbage before the g2_itemid.
I'll go looking now , but just in case someone can point me in the right direction, how does one add a rule to the url rewrite ?
Any suggestions really appreciated.
Thanks

 
FLUXrider

Joined: 2006-05-18
Posts: 49
Posted: Tue, 2006-12-19 02:57

Well, that was easy to figure. Just add the rule to the bottom of the comments module.inc. and add a $this rule at the top.... I think :). Soon as I've figured out just what that mod is I'll post it here fir any others who might be interested. That could be a while 'cause the more I read about this the more there is to learn.
edit- This is more complicated/confusing than first look. If someone can point me in the right direction I would be grateful.