Go Back   Pligg Forum > Pligg Development > Bug Report
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-09-2006, 09:16 PM
Aviran Aviran is offline
New Pligger
 
Join Date: Jan 2006
Posts: 22
Downloads: 1
Uploads: 0
Thanks: 0
Thanked 4 Times in 2 Posts
Buf Fix to story.php

users who upgrade from old versions can no longer access old posts if they switch to friendly urls since the new version tries to use the title as a url and old posts do not have the title_url field filled in.

The Fix:

in story.php after line 32 put the redirection in an if statement

Code:
if ($url != my_pligg_base."/story.php?title=")
	{
		Header( "HTTP/1.1 301 Moved Permanently" );
		Header( "Location: " . $url );
	
		die();
	}
This way if you don't have a title field filled in you'll still be able to access posts via the id parameter
__________________
Aviran's Place
Shaveh
Reply With Quote
The Following 2 Users Say Thank You to Aviran For This Useful Post:
Reply



Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
story.php have problem.. topcc General Help 2 03-21-2006 10:23 AM


LinkBacks Enabled by vBSEO 3.0.0