Permalinks - %title% is what exactly?

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
sboy
Posts: 4
Joined: Mon Nov 29, 2010 3:58 pm

Permalinks - %title% is what exactly?

Post by sboy »

Hello,

I've decided using serendipity since it fits my needs perfectly. One thing I am doing is using my website (not the serendipity blog site) to show serendipity blog entries, by accessing the DB and grabbing info using my own php.

In my website, I want to have links to my blog pages, and the permalink for linking to blog page can use %id% and %title%, the thing is I'm wondering is, how different is title and %title%, how does %title% change the actual title:

I know the %title% changes spaces [ ] to dashes [-], and probably deletes certain punctuations like question marks [?].

Where do I find the code that tells me exactly what %title% is?
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Permalinks - %title% is what exactly?

Post by garvinhicking »

Hi!

In include/functions_permalinks.inc.php there is the PHP code for serendpity_makeFilename() that does the transformations from %title%.

You might want to simply link to to /archives/XYZ-guid.html if you don't want to put the title in the url. As long as you have %id% in the URL, it does not matter what %title% actually contains, the lookup is done via ID.

HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
sboy
Posts: 4
Joined: Mon Nov 29, 2010 3:58 pm

Re: Permalinks - %title% is what exactly?

Post by sboy »

Thank you for the info! I got it working now~
Post Reply