Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 03/16/2023 in all areas

  1. You should read through the PCRE section of the manual to get an idea of what the various things in the patterns do, and what is available to use when constructing patterns. Using an online regex debugger can help you as well by letting you easily try patterns and break them down into their components.
    1 point
  2. Throwing syntax at the function and seeing if it does what you want isn't a very efficient way of programming. Do you understand how those regular expressions work? What the various symbols mean? Again: one step at a time. This ~(\bhttps?://\S+)(?:\s+\[([^]]+)\])?~i is a good enough regular expression that will match these: http://www.google.com https://www.google.com http://www.google.com [Link text here] https://www.google.com [Link text here] Did you know about the [text] bit at the end? Do you want that?
    1 point
This leaderboard is set to New York/GMT-05:00
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.