I think it is a beginner level question so I posted my message in here
First my current .htaccess file;
RewriteEngine on
RewriteBase /
rewriteCond %{HTTP_HOST} !^www\.
rewriteCond %{HTTP_HOST} ^(.+)\.domain\.com
rewriteRule ^([0-9]+)$ http://www.domain.com/items.php?pf=%1&page=$2 [P,L]
what i am doing here is; when you put the URL like sub.domain.com/page=1 apache rewrite is as www.domain.com/items.php?pf=sub&page=1 and works fine.
However, when you click the button from the mainpage i'd like to send my URL as sub.domain.com and this time my modrewrite doesnt work with my current rules. Is there anyway to create two rules when there is an parameter do rule1 and if there is no parameter do rule2. do you guys have any idea ? hope i did myself clear.
-s