Gamestudio Links
Zorro Links
Newest Posts
ZorroGPT
by Grant. 05/23/26 20:53
Issues resuming trades on Demo account
by Martin_HH. 05/22/26 13:31
XTB
by pr0logic. 05/18/26 12:27
Purchase A8 full licence version
by NeoDumont. 05/13/26 20:17
Black Book, 4th edition
by TipmyPip. 05/11/26 08:40
No errors in the command line
by jcl. 05/08/26 10:59
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
3 registered members (TipmyPip, Grant, AndrewAMD), 1,728 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
jayden, liu, Koti, curry, DeepxKalsi
19220 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
dringende php frage #323191
05/12/10 08:17
05/12/10 08:17
Joined: Oct 2002
Posts: 8,939
planet.earth
ello Offline OP
Senior Expert
ello  Offline OP
Senior Expert

Joined: Oct 2002
Posts: 8,939
planet.earth
Hi,
ich hab ein problem mit folgendem code:
Code:
$regExp = "/^[a-z_]([a-z0-9_-]*\.?[a-z0-9_-])*\.[a-z]{3,4}$/i";
if (preg_match($regExp,$text)) ...



wie muß $regExp aussehen damit auch Unterstriche "_" erlaube sind??

danke schonmal,
Ello


www.earthcontrol.de
quoted: We want to maintain a clean, decent, American family suited forum look... which means you may post zombies or chainsaw massacres, but no erotic.
Re: dringende php frage [Re: ello] #323197
05/12/10 09:55
05/12/10 09:55
Joined: Feb 2005
Posts: 3,687
Hessen, Germany
T
Tempelbauer Offline
Expert
Tempelbauer  Offline
Expert
T

Joined: Feb 2005
Posts: 3,687
Hessen, Germany
bin jetzt nicht mehr so fit in sachen reguläre ausdrücke, aber wenn "/^" bedeutet "alles ausser", dann musst du nur die _ aus den eckigen klammern entfernen.
ansonsten: versuchs mal mit dem escapen der zeichen: [a-z\_]

es gibt einige nüttzliche test-tools für sowas, wie z.b. regex coach http://weitz.de/regex-coach/

Re: dringende php frage [Re: Tempelbauer] #323198
05/12/10 10:00
05/12/10 10:00
Joined: Oct 2002
Posts: 8,939
planet.earth
ello Offline OP
Senior Expert
ello  Offline OP
Senior Expert

Joined: Oct 2002
Posts: 8,939
planet.earth
danke Dir!


www.earthcontrol.de
quoted: We want to maintain a clean, decent, American family suited forum look... which means you may post zombies or chainsaw massacres, but no erotic.

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1