Jump to content

Recommended Posts

Posted

I have installed this as a replacement to ClipBucket (certain features are available that we would prefer) having got everything working LDAP auth, uploading, converting, etc I want to put the entire site behind SSL I am using a LAMP install on Debian 6 I setup the Default file in Sites Available to redirect everything to SSL I enabled this which added a symlink into Sites-Enabled edited the Default-SSL file with our certs the site shows up fine however I believe PHPmotion uses redirects for the buttons on the main page and elsewhere and as such keeps bringing up The requested URL was not found on this server.

 

I put the following into the default file:

 

The following in the default file in sites-available/sites-enabled:

 

RewriteEngine on

ReWriteCond %{SERVER_PORT} !^443$

RewriteRule ^/(.*) https://%{HTTP_HOST}/$1 [NC,R,L]

 

 

If I click on a button e.g.

 

Video Button: The requested URL /videos/load/recent was not found on this server.

 

Audio Button: The requested URL /audios/load/recent was not found on this server.

 

Upload Button: The requested URL /upload-media was not found on this server.

 

When Clicking on the People button it does bring up a page but clicking on a member brings up:

 

The requested URL /members/admin was not found on this server.

 

Blogs and Groups seem to work fine though.

 

 

I get the above any thoughts? I've uploaded the .htaccess file again just in case this was at fault but no joy.

 

Any help would be much appreciated.

 

 

Thanks,

 

 

Wes

Posted

Here is a copy of the .htaccess file:

 

#

#*****************************************************************************************

# PHPMotion V3 Free Media-Sharing CMS

# PHPMotion Development Team

# PHPmotion :: Free Video Script - Free Youtube Clone - Free Youtube Script - Free Video Sharing software - you tube clone - PHP Video Sharing Script - Media sharing script - social networking scrript

# [email protected]

#*****************************************************************************************

#

#*****************************************************************************************

# Copyright © 2007-2008 phpmotion.com. All rights reserved.

#*****************************************************************************************

 

#----------------------------------------------------------------------------------------#

order allow,deny

allow from all

#----------------------------------------------------------------------------------------#

 

#----------------------------------------------------------------------------------------#

 

# uncomment this line to enable site wide gzip to increase load times

# may cause 500 server errors on servers running php in cgi mode

#---------------------------------------- GZIP BEGIN ------------------------------------#

#php_value output_handler ob_gzhandler

#---------------------------------------- GZIP END --------------------------------------#

 

#--------------------------------------- START SEO --------------------------------------#

Options +FollowSymlinks

RewriteEngine On

 

#----------- this is the directory where phpmotion is install ---------------------------#

#----- if phpmotion is installed in a sub directory edit the RewriteBase as follows -----#

 

# EXAMPLE => RewriteBase /your sub-directory name

# EXAMPLE => RewriteBase /videos

 

RewriteBase /

 

#------------------------------- do not edit below --------------------------------------#

 

RewriteRule \.(css|jpe?g|gif|png|flv|swf)$ - [L]

 

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

 

# Main Menu Links #

 

RewriteRule ^videos/load/([^/]*)$ seemore.php?load=$1 [L]

RewriteRule ^videos/load/([^/]*)/([^/]*)$ seemore.php?load=$1&page=$2 [L]

 

RewriteRule ^audios/load/([^/]*)$ audio.php?load=$1 [L]

RewriteRule ^audios/load/([^/]*)/([^/]*)$ audio.php?load=$1&page=$2 [L]

 

RewriteRule ^audio/album/([^/]*)/([^/]*)$ audio.php?album=$1 [L]

RewriteRule ^audio/album/([^/]*)/([^/]*)/([^/]*)$ audio.php?album=$1&page=$3 [L]

 

RewriteRule ^blogs/load/([^/]*)$ blogs.php?load=$1 [L]

RewriteRule ^blogs/load/([^/]*)/([^/]*)$ blogs.php?load=$1&page=$2 [L]

 

RewriteRule ^albums/load/([^/]*)$ albums.php?load=$1 [L]

RewriteRule ^albums/([^/]*)/([^/]*)$ albums.php?load=$1&page=$2 [L]

 

RewriteRule ^people_ajax people_ajax.php [L]

RewriteRule ^people/([^/]*)/([^/]*)$ people.php?load=$1&page=$2 [L]

RewriteRule ^people people.php [L]

RewriteRule ^upload-media upload.php [L]

 

RewriteRule ^groups$ groups.php [L]

RewriteRule ^search search.php [L]

 

 

# Action Links #

RewriteRule ^videos/([^/]*)/([^/]*)$ play.php?vid=$1 [L]

RewriteRule ^audio/([^/]*)/([^/]*)$ play_audio.php?audio=$1

 

RewriteRule ^category/([^/]*)$ category_home.php?cid=$1 [L]

RewriteRule ^category/([^/]*)/([^/]*)$ category_home.php?cid=$1&page=$2 [L]

 

RewriteRule ^subcategory/([^/]*)/([^/]*)$ category_home.php?sub=$1 [L]

RewriteRule ^subcategory/([^/]*)/([^/]*)/([^/]*)$ category_home.php?sub=$1&page=$3 [L]

 

RewriteRule ^genre/([^/]*)$ genre_home.php?cid=$1 [L]

RewriteRule ^genre/([^/]*)/([^/]*)$ genre_home.php?cid=$1&page=$2 [L]

 

RewriteRule ^view-album/([^/]*)/([^/]*)$ album_view.php?album=$1

RewriteRule ^view-image/([^/]*)/([^/]*)$ album_view.php?image=$1

RewriteRule ^read_blog/([^/]*)/([^/]*)$ read_blog.php?id=$1 [L]

 

RewriteRule ^blogs/category/([^/]*)/([^/]*)$ blogs.php?cat_id=$1 [L]

RewriteRule ^blogs/category/([^/]*)/([^/]*)/([^/]*)$ blogs.php?cat_id=$1&page=$3 [L]

 

RewriteRule ^members/([^/]*)$ memberprofile.php?user=$1 [L]

 

#-------------------------------------------------------------#

# redirect directory browsing attempts

RewriteRule ^videos(.?)$ seemore.php [L]

RewriteRule ^audios(.?)$ audio.php [L]

RewriteRule ^blogs(.?)$ blogs.php [L]

RewriteRule ^members(.?)$ people [R=301]

RewriteRule ^albums(.?)$ albums.php [L]

 

#-------------------------------------------------------------#

 

 

 

 

 

#--------------------------------------- END SEO ----------------------------------------#

 

 

#--------------------------------------- SOME SIMPLE BLOCKS -----------------------------#

RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]

RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]

RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})

RewriteCond %{QUERY_STRING} SELECT(=|\[|\%[0-9A-Z]{0,2}) [OR]

RewriteCond %{QUERY_STRING} UNION(=|\[|\%[0-9A-Z]{0,2}) [OR]

RewriteRule ^(.*)$ index.php [F,L]

#--------------------------------------- END BLOCKS -------------------------------------#

 

Options -Indexes

 

SecFilterEngine Off

SecFilterScanPOST Off

 

ErrorDocument 403 /403.php

ErrorDocument 404 /404.php

 

 

 

 

How can the rewrite rules be changes to force https?

 

 

 

 

Thanks,

 

 

Wes

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...