/    Sign up×
Community /Pin to ProfileBookmark

[RESOLVED] Permalinks

What is the method for creating a permalink?

If I have a blog entry, and along with the post content itself, an ID, a title, user created, a teaser and it all goes into my database for display. So it is stored and properly santized etc, what is the next step to be able to just show my teaser and reference a permalink? I can display the teaser thats no problem, but I would like to know how to [U]create the permalink itself [/U]that is tied to the ID of the entry (or whatever it is linked to). I have searched this on the net but found nothing other than the use of permalinks. Is one created at the time the data is stored in the database and what would the best method be? Would “Files” be used?

I dont expect anyone to write the script for me, but would like to be spun and pointed in the right direction. Thanks

to post a comment
PHP

4 Comments(s)

Copy linkTweet thisAlerts:
@CarolineBogartDec 29.2008 — Is this home made software? Wordpress?

You're looking for Search Engine Friendly links, aka SEF, in WordPress it's permalinks.
Copy linkTweet thisAlerts:
@mrwilsonauthorDec 29.2008 — No this is in my own home made scripts. How to generate a file on the run as you create it, throw it in the SQL database, display it and give it a unique ID(link) that would be its permanent link. that was the same as permalinks to me. Although being a SEF would certainly be an advantage. maybe i can browse around my wordpress and see if i can pick up the gist of the code. thank you for responding ?
Copy linkTweet thisAlerts:
@NogDogDec 29.2008 — This is typically done via Apache setting, using mod_rewrite to take the textual link and convert it to a url query string which sets a value in PHP in the $_GET array. You would then use that $_GET value to query the DB to get the applicable article. So if you add "mod_rewrite" to your "permalink" search, it might help focus the search results.
Copy linkTweet thisAlerts:
@mrwilsonauthorDec 29.2008 — thank you nogdog, I do remember seeing something about mod_rewrite. Looks like thats going to be a next step to learn ? I appreciate your help
×

Success!

Help @mrwilson spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...