Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6957185
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:58:02+00:00 2026-05-27T14:58:02+00:00

okay i found this regex from Stack overflow, which can isolate the URL and

  • 0

okay i found this regex from Stack overflow, which can isolate the URL and ID, but when ever i tried to use it in app engine (py) an error popup saying “nothing to repeat, i know theres a bug in Python regarding this regex repeating, can anyone fix this? tx

  File "C:\Program Files\Python27\lib\re.py", line 244, in _compile
    raise error, v # invalid expression
error: nothing to repeat

sample code

#   patt = '(?:http:\/\/)?(?:www.)?facebook.com\/(?:(?:\w)*#!\/)?(?:pages\/)?(?:[?\w\-]*\/)?(?:profile.php\?id=(?=\d.*))?([\w\-]*)?'
#   tst = self.request.get("form_fbURL")
#   m=re.match(patt,tst)

im not a good python programmer anyway 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T14:58:03+00:00Added an answer on May 27, 2026 at 2:58 pm

    There is a urlparse module to parse url.
    The urlparse module is renamed to urllib.parse in Python 3.0.

    $ python
    >>> from urlparse import urlparse
    >>> urlparse('http://www.facebook.com/hello/world.php?id=789')
    ParseResult(scheme='http', netloc='www.facebook.com', path='/hello/world.php', params='', query='id=789', fragment='')
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Okay, I have done a bit of searching online and found this thread, but
1. Okay this is probably lame question, but I haven't found good result searching
Okay so im working on this php image upload system but for some reason
Okay, I've seen but haven't programmed in C# before. You can assume I'm competent
Okay, so this probably sounds terribly nefarious, but I need such capabilities for my
Okay I found this RSS plugin and I want to display it inside a
Okay, I am a noob to regex, and I am using this site for
Okay, so not sure if apple.stackexchange is a better place for this, but I
Okay, so this is not the first time I've had this problem, but it
Okay, Now admittedly this sounds like a silly question; But, I actually have a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.