#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11

    URL Rewrite problems on IIS7


    Im using iis7 and this url rewrite is giving errors, can anyone tell me how to fix this to work with iis?

    Im moving over a site from apache to iis and am having all kinds of small issues.

    this is the code and error presently.

    HTTP Error 500.50 - URL Rewrite Module Error.
    The expression "^group_edit/([a-zA-Z0-9\_\.\-]+)/$" contains an unmatched '[' or ']'.


    another problem im having is with the type of rewrite below, when someone tries going to login.asp the login/ rewrite below blocks it? any ideas of why? it works on apache. I just imported my url rewrites from the apache htaccess file.
    ^login/?([^\/].*)?$

    how can i make it so it sees that as a directory only?



    please help with both questions if you can, thank you!!

    Sean
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    found the answer elsewhere for the first problem, here it is.



    It is not necessary to escape the _ symbol. Try this pattern instead:

    ^group/([a-zA-Z0-9_\.\-]+)/$



    ** i still need help with the second problem**
    ^login/?([^\/].*)?$

    **actually it seems to work some, if you see an issue let me know please.
    Last edited by seanincali; January 5th, 2010 at 05:00 PM.
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    another problem:

    on win2k8/apache it was ok for rewrite google seo friendly urls like
    http://mydomain.com/yourupload/its_title_is_this:_Title./

    on apache the : and . are able to pass the browser,
    but on IIS it gives a 505 error.

    do i need to just strip the titles so they dont have any characters other than letters and numbers or?
  6. #4
  7. No Profile Picture
    Grumpier old Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Jun 2003
    Posts
    14,430
    Rep Power
    4539
    Just out of curiosity, is urlrewrite part of IIS or is it an an add-on from another vendor? And I don't know the answer to your question, sorry.
    ======
    Doug G
    ======
    Bartender to Rene Descartes "have another beer?" Descartes: "I think not" and he vanished.
    --Alfred Bester
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    it seems to be an add-on

    url rewrite 1.1
  10. #6
  11. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    any have any ideas of why iis wont pass this type or url rewrite? it comes back as bad request

    http://mydomain.com/edit_profile&s=personal

    the actual rule is

    <rule name="Imported Rule 103" enabled="true" stopProcessing="true">
    <match url="^edit_profile/?([^/._]+)?$" ignoreCase="true" />
    <action type="Rewrite" url="index.php?view=edit_profile{R:1}" appendQueryString="true" />
    </rule>



    I have iis url rewrite 2 installed.
  12. #7
  13. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    fixed by installed asp mvc
  14. #8
  15. No Profile Picture
    Grumpier old Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Jun 2003
    Posts
    14,430
    Rep Power
    4539
    I'm glad you got it working, thanks for sharing your solution.
    ======
    Doug G
    ======
    Bartender to Rene Descartes "have another beer?" Descartes: "I think not" and he vanished.
    --Alfred Bester
  16. #9
  17. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2003
    Posts
    81
    Rep Power
    11
    Sorry wrong solution!

    The solution was that i changed the IIS application process to classic.

IMN logo majestic logo threadwatch logo seochat tools logo