JDownloader Community - Appwork GmbH
 

Closed Thread
 
Thread Tools Display Modes
  #1  
Old 10.08.2023, 21:45
Student im ersten Jahr Student im ersten Jahr is offline
Black Hole
 
Join Date: Nov 2020
Posts: 289
Default Regex Chinese/English issue

What regular expression for a file name beginning with A-Z excluding the beginning of a Chinese letter?
Looking for (File Name / Downlaods and LinkGrabber)
My expression doesn't work perfectly because it ignores all Chinese.
It seems to be very complicated.

English "Artist" - "Title" English/Chinese(mixed language)

Code:
^[A-Za-z][^一-龯]*$
Spoiler:
Include:
En - 间 (Summer).mp3

Exclude:
政香 - 香烟火柴 (Dj柳).mp3

This also ignores most Chinese, but also only includes some correctly:
Code:
^(?![一-龯])[A-Za-z]

Last edited by Student im ersten Jahr; 10.08.2023 at 21:50.
  #2  
Old 11.08.2023, 00:08
raztoki's Avatar
raztoki raztoki is offline
English Supporter
 
Join Date: Apr 2010
Location: Australia
Posts: 17,649
Default

because its a range, outside of your range wont be covered. For example in english b-z wouldn't include 'a' so you need to know the start of the range.
__________________
raztoki @ jDownloader reporter/developer
http://svn.jdownloader.org/users/170

Don't fight the system, use it to your advantage. :]
  #3  
Old 11.08.2023, 09:26
pspzockerscene's Avatar
pspzockerscene pspzockerscene is offline
Community Manager
 
Join Date: Mar 2009
Location: Deutschland
Posts: 72,055
Default

@Student im ersten Jahr
We're still not here to teach anyone how regular expressions work.
Learn them on your own and use webtools like regex101.com to test them.

Thread closed.
__________________
JD Supporter, Plugin Dev. & Community Manager

Erste Schritte & Tutorials || JDownloader 2 Setup Download
Spoiler:

A users' JD crashes and the first thing to ask is:
Quote:
Originally Posted by Jiaz View Post
Do you have Nero installed?
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 06:10.
Provided By AppWork GmbH | Privacy | Imprint
Parts of the Design are used from Kirsch designed by Andrew & Austin
Powered by vBulletin® Version 3.8.10 Beta 1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.