#1
|
|||
|
|||
![]()
I need help to write RegEx for Package Customizer... I am downloading stuff from links like this one:
hxxp://www.somesite.com/my-holy_grail/filename.ext Is it possible to create package with name "my_holy_grail" using RegEx and Package Customizer ? Can someone help me to set this correctly? ![]() Last edited by fanatic_; 18.11.2011 at 15:42. |
#2
|
||||
|
||||
![]()
hi
If you like a tight regep use '(?i).*?my\-holy\_grail.*?' which will only pick up 'my-holy_grail' or if your used to wildcard expression *my-holy_grail* within url. or if the characters separating are not always the same you can try '(?i).*?my.*?holy.*?grail.*?' this will pick up combinations in sequence of 'my holy grail' or with traditional wildcard expression '*my*holy*grail*'. You can use/set any package name with matches.
__________________
raztoki @ jDownloader reporter/developer http://svn.jdownloader.org/users/170 Don't fight the system, use it to your advantage. :] |
#3
|
|||
|
|||
![]()
thank you for help, but my links are just a little bit different
![]() hxxp://content.somesite.com/2011/10/SomethingHere/filename.mp4 In my previous post I didn't give you a good example, here is almost same link which I am downloading.... So, SomethingHere should be my Package Name and it can contain underline, dots, etc (. , - , _ , ...) if it does matter ![]() How to code that? ![]() If I understand you I should put your Regex code to Regex Field in jD and what is going to Package Name field? ![]() thanks for help in advance ![]() |
#4
|
||||
|
||||
![]()
so use my second example it will allow any other characters (unlimited) in between and either side those words. You can also use '[\.\-\_]+' if you rather to only limit too those characters, using '\' escapes the normal use within regep so its means the character instead and '+' means unlimited times
original example (removed leading/ending .*? as its not needed) '(?i)my.*?holy.*?grail' or this '(?i)my[\.\-\_]holy[\.\-\_]grail' so this works for one of the characters within [] its only repeated once. Add '+' at the closing of square bracket []+ for unlimited or use []{3} for repeated 3 times might be best to just google regular expressions. Plenty info online about it
__________________
raztoki @ jDownloader reporter/developer http://svn.jdownloader.org/users/170 Don't fight the system, use it to your advantage. :] |
#5
|
|||
|
|||
![]()
OK, I will google it...
I will put regex code to Regex field in jD, but what I need to put in Package Name field in jD? ![]() |
#6
|
||||
|
||||
![]()
anything you want, this will be static
__________________
raztoki @ jDownloader reporter/developer http://svn.jdownloader.org/users/170 Don't fight the system, use it to your advantage. :] |
![]() |
Thread Tools | |
Display Modes | |
|
|