Mod-rewrite question: convert static URL to dynamic for dynamic signatures

Hey there, I want to create a mod_rewrite rule to allow dynamic signatures.

Here is the client URI:
Here is the rewritten URI:

Also please include which .htaccess file(s) needs modifying.

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Dodger42Author Commented:
No response so points bumped up.

if you want it for png extension only, you can try something like :

RewriteRule ^(.*)\.png$$1\.png
more info on  url rewriting:
Dodger42Author Commented:
Ok that redirect is kind of working, but there is an extra slash in there after the = sign:

"/42SF-Dodger" should be "42SF-Dodger"
Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.


to eliminate the slash:

RewriteRule ^/(.*)\.png$$1\.png

Experts Exchange Solution brought to you by ConnectWise

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Dodger42Author Commented:
One more thing. If I only want this rule to take place if the request is in the / directory, do I just put that rule int he directory section for /?

you can use:

RewriteRule ^/(.+[^/])\.png$$1\.png
(.+[^/])  where  matches everything , exept string that contains /

it doesn't help to use  RewriteRulele  ^/(.*)\.png$$1\.png   in <directory> section.   A rule is used in non-server context  if you add it to  a .htaccess file.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.