[PHP-DB] ob_gzhandler

2002-09-21 Thread kras

Hello!
Is there any possibility to apply more than one callback function in output
buffer?
For example, first should convert one characterset to another and the last
one would be gzhandler to compress all converted content.

regards
kras


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] regex problem

2002-05-18 Thread kras

Hello!

I have got a big problem:

I have html content in $html variable, which contains href, src and
background tags. Those tags may contain relative adressess and absolute
addressess which begin with http(s): or cid: (mail inline attachements) and
mailto:

I have also variable $basewwwservername, which contains servername of
current server. I have to insert this $basewwwservername into all href,src
and background tags which are relative and NOT into absolute.
In other words I must preg_replace with some pattern that match for example
(src)=(\"|)..and not following WORDS: http|cid|mailto and correct rest of
string.

Does anybody relief my pain?;-)
I've lost at least 3 days (not 3x24hrs;-)

Regards
Konrad

--
e-mail: [EMAIL PROTECTED]




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP-DB] Date Returns

2002-03-16 Thread kras



> Does anyone know if the date function returns false if it cannot convert
the
> specified date/time to the format?  If not, does anyone have a rule set
they
> use to verify the date is a valid convertible date?  I need to update a
row
> in MSSQL, and it will fail if the date is incorrect.  I've validated for
the
> basic things, but just am not sure what the best way would be to validate
> the actual date itself.  I was thinking of RegExp, but not certain if that
> would really work for multiple date formats for example:
>
> March 15, 2002
> 03/15/2002
> 3/15/2002
>
> and so on and so forth.  The field actually requests a dd/mm/yy format,
but
> you know how people follow instructions.
>

Use "MMDD HH:MM:SS" (without "-") format date when inserts or updates
fields in MSSQL, MYSQL etc.
For example: INSERT INTO tblxxx (fielddatetime,fieldother) VALUES ('20020311
18:33:44','something else')

I use it in that way and it is the best method I think.
Mayby you may use odbc structure {ts '-mm-dd hh:mm:ss'}
For example: INSERT INTO tblxxx (fielddatetime,fieldother) VALUES ({ts
'20020311 18:33:44'},'something else')

good luck with dates ;-)
BTW I recommend you to explore MSSQL Book Online! It has quite good and a
lot of knowledge.

Konrad





-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] datetime in MSSQL7

2001-10-22 Thread kras

Hello!

How can I force PHP to fetch datetime field i 'mmdd hh:mm:ss'  WITHOUT
using MSSQL query like *SELECT convert(varchar,dtfield,20) as 'dtfield'* and
so on?
I have a few tables on MSSQL with the different structures and some of
fields are datetime. I have to use CLASS in php with querys inside the code
that are independent on order of fields.

setlocale? but what?

regards
Konrad



-- 
PHP Database 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]