Welcome, Guest. Please login or register.
Did you miss your activation email?
May 26, 2012, 06:51:12 PM

Login with username, password and session length
Search:     Advanced search
Interested in joining the WebsiteBaker team?
For more Information read here or on our new website.
155549 Posts in 21714 Topics by 7760 Members
Latest Member: gx-world
* Home Help Search Login Register
Pages: [1]   Go Down
Print
Author Topic: Work In Progress: Create nice news URLs  (Read 358 times)
crnogorac081
AddOn Development
*
Offline Offline

Posts: 1706



« on: July 04, 2011, 08:13:01 PM »

Hi,

It is made to suit my needs, and it works fine on test server (WBPortable) but I would like to hear about some vulnerabilities and comments before I post the tutorial Smiley

Here what is it about:

As of now, you can put each news post into certan group, but their links are all presented as www.wburl.xy/posts/this-is-the-news-title-10.php (at all my sites there is no /pages folder, and 10 is post_id)

So if you have multiple categories, all your news url's will be presented as boring - - -/posts/- - - folder.
This patch will create links like:   www.wburl.xy/football/this-is-the-football-news-10.php , where football is your news Group (category) Smiley

How it works:
1. When you create news Group it will create folder /group_name/ under /Pages
2. When you add news you can select group to: None, or select some Group. If you select None, news will be created under /posts/ and if you select any group it will go to /group_name/ folder. When you move between None or Groups it is the same.
3. If you delete Group, php files (of Pages and News ) will still be there
4. There are no problems when adding Page with same name as Group_name unless you really want to be nasty and put the exact post_id at the end.. (Set under TO DO)
Example: page: this-is-title.php , news: this-is-title-9.php , but if you add 9 at modify page name it will overwrite the code in file..
5. When you delete Page ,with or without Pages or News in it, which is same name as your Group title, code will check if there are News posts in it and it will not delete the folder but only the file (page_name.php and not the /page_name/ ) and entry in DB so you will not see that page in Admin Pages


TO DO:
At this moment it is still under testing and I have to make that if you create same pagename as news title it will overwrite the code in the file when you put it in same dir
 
So what do you think ?
« Last Edit: July 04, 2011, 08:21:19 PM by crnogorac081 » Logged

Wow, I coded something myself: PM Messanger Modul ,Searchbox with suggestions
crnogorac081
AddOn Development
*
Offline Offline

Posts: 1706



« Reply #1 on: August 18, 2011, 11:32:26 PM »

ok, here is demo:

www.mondocafe.me

its a news portal, and still under major development.. when I am done I will post a link How To, if you want urls like this Smiley

cheers
Logged

Wow, I coded something myself: PM Messanger Modul ,Searchbox with suggestions
Stefek
WebsiteBaker Org e.V.

Offline Offline

Posts: 4884



« Reply #2 on: August 19, 2011, 10:45:25 AM »

Looks great Ivan.

Also the commenting functions.
*thumbsup*

Regards,
Stefek
Logged

"In a time of universal deceit, telling the truth becomes a revolutionary act."
- George Orwell, Nineteen eighty-four (1984)
crnogorac081
AddOn Development
*
Offline Offline

Posts: 1706



« Reply #3 on: August 19, 2011, 10:57:30 AM »

Thanks mate
Logged

Wow, I coded something myself: PM Messanger Modul ,Searchbox with suggestions
Pages: [1]   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!