[PHP] Re: Help with regular expresions! [ASAP]

2001-07-25 Thread maatt
$tag_name = "input"; $new_class = "yourclass"; eregi_replace("(<$tag_name)", "\\1 class=\"$yourclass\"", $yourstring); will work for simple cases, but isn't going to give you much more power than just applying a style to the tag iself - 'input { border : 1px }' say). If the design is consistent

Re: [PHP] include ("foo.php") not working

2001-07-25 Thread maatt
Errr... feel embaressed asking but I've done the same... You do have tags around your code? Easy to leave off when there's no HTML in the page. Matt "Ilari Kaartinen" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > when I include the statement then rather

[PHP] Re: regex for cleaning up username

2001-07-23 Thread maatt
> thinking it may be easier to parse for only allowed characters. *much* better idea. Try: preg_match('/[^\w]/', $string) to find all non-alphanumeric+underscore -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMA

Re: [PHP] passing variables from forms to the same page repetatively

2001-07-17 Thread maatt
I was doing something similar just yesterday. Ended up with a little function to automatically write hidden s for every variable that's submitted, whether posted or thru the url. Goes like this... // put this somewhere in your form // the function itself function get_param_inputs() { global $

[PHP] Re: eregi replace help

2001-07-07 Thread maatt
ereg_replace("> <[^<]*", "", $string); or ereg_replace("&.*\n", "", $string) if the unwanted bits end in new-lines ?? "Richard van Leeuwen" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I want to delete some lines > > original: > > http://www.example.com/1

[PHP] Re: mysql_insert_id()

2001-07-07 Thread maatt
> I have been reading about this function and I have a question. The PHP > manual warns about using it if your AUTO_INCREMENT ID field is a BIGINT. I > am using type INTEGER. Am I okay with this one, or should I use the MySQL > function. Works just fine in everything I do. Maat

[PHP] ng working? - ignore

2001-07-05 Thread maatt
Just trying to see... -- Matt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]

Re: [PHP] file upload

2001-04-13 Thread maatt
> Is there any way not to write those line into the uploaded file? It's a bug in 4.0.4pl1 on (AFAIK) RH7 and Apache. Will be fixed in 4.0.5. You can't avoid them, but use something like the following to strip them out: /* void fix_broken_header(reference file) * Incorporates fix for problem wit

Re: [PHP] www.php.net - gateway timeout?

2001-04-12 Thread maatt
> 208.247.106.187, running Apache/1.3.12 (Unix) DAV/0.9.18-dev PHP/4.0.5-dev. Dearly hope it's not 4.0.5-dev that's the prob! Been wanting to try it, which is why I can't use uk.php.net! > The site loads fine now, but last time I did it it was all being rejected on > that hop. The server was ref

Re: [PHP] Editors ... calling them, or PHP-based one?

2001-04-12 Thread maatt
What you're trying to do sounds a lot like content management. I'm no expert, but you should be able to do all this through the browser serverside (no need to download/upload). Have you checked out www.midgard-project.org, www.dotvoid.com/firesite.php, or http://phpwebsite.appstate.edu/? Matt "T

[PHP] www.php.net - gateway timeout?

2001-04-12 Thread maatt
Anyone else having probs getting through? Or is it just me? Been trying since the wee hours (GMT). -- Matt Kynaston remove the green eggs before replying -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECT

Re: [PHP] TTF Support

2001-04-11 Thread maatt
> Is there something that I can check to see if the FreeType > library is there when I only have a virtual server? Put phpinfo() on a page - look under the gd library section. > And if it wasn't installed, is there any way that I can do this > locally without having root access? Don't think so.

Re: [PHP] Nearly all (1755) PHP functions in a text file

2001-04-06 Thread maatt
Dammit, that's great Plutarck. Been wanting to write a documentating script for ages, that basically took the output from show_source() and added links to all the functions in the online manual, as well as any functions defined in the script or includes. Will be handy for a tutorial series I'm do

Re: [PHP] scramble the code

2001-04-05 Thread maatt
Save yourself the scramble, use sessions: http://www.php.net/manual/en/ref.session.php -- Matt Kynaston remove the green eggs before replying ""Scott Fletcher"" <[EMAIL PROTECTED]> wrote in message 9ai09g$9d$[EMAIL PROTECTED]">news:9ai09g$9d$[EMAIL PROTECTED]... > I see it! The login page whe

[PHP] RH7 4.0.4pl1 RPMs

2001-04-04 Thread maatt
Anyone else started getting problems after upgrading to these? Seem to get getting whitespace prepended to my post vars. Wondering if it's the RPMs or 4.0.4pl1 itself. Matt -- Matt Kynaston remove the green eggs before replying -- PHP General Mailing List (http://www.php.net/) To unsubscrib