I am getting an problem with conflicting quert strings on the page. for example the page look such as the following:

website.com/photos/type/album-title/page-2/ AND website.com/photos/type/album-title/photo-id/

the problem here's that I'm not sure steps to make it to ensure that it recognizes that if this states 'page-2' that it requires one rule, so when it is the photo-id it requires another.

I've the next

RewriteRule ^photos/([\w+.-]+)/([\w+.-]+)/([\w+.-]+)/?$ /photos.php?view=$1&slug=$2&page=$3 [QSA,L]
RewriteRule ^photos/([\w+.-]+)/([\w+.-]+)/([0-9]+)/?$ /photos.php?view=$1&slug=$2&pid=$3 [QSA,L]

Rather than getting different rewrite rules for each possible query string, why not possess a generalized rewrite and take care of the query strings inside your application?

Or, for the second query, do this:

RewriteRule ^photos/([\w+.-]+)/([\w+.-]+)/(page\-[0-9]+)/?$ /photos.php?view=$1&slug=$2&pid=$3 [QSA,L]

Your Web addresses would seem like,

website.com/photos/type/album-title/page-2/ --> using the 'page-' keyword.