logs archiveIRC Archive / Freenode / #php / 2006 / April / 10 / 1
Jemt
Xen0n: Great! dirname() was exactly what I was looking for. You are hardcore, man ;)
Xen0n
Jemt, ^_^ I do try and help if i know something
JFDionne
Hi, what is the best way for calcul the Centreal time Or EST if I have the time in gmt?
Xen0n
(Action) drools at the prospect of properly-enforced member access on classes
Jemt
Xen0n: That's the spirit ^^
Hehe :)
freeone3000
Either: Create a timestamp from that value, then time() it out.
*JFDionne:
Xen0n
JFDionne, why not use gm_date() when outputting?
freeone3000
Xen0n: Like.. private, public, static, protected, synchronized, etc.?
Xen0n
freeone3000, yeah :D
         

JFDionne
Xen0n because my computer is not on that time zone :)
freeone3000
JFDionne: Check if it's DST, subtract DST?5:6 hours from the time for CST.
Xen0n
JFDionne, doesnt matter ... gmdate will automatically fix the date according to the offset your computer is on
JFDionne, oh
sorry
I read that all wrong >.<
(Action) kicks self
damn :(
JFDionne
:)
freeone3000
JFDionne: And the same for the rest... EST I think is 4|5.
JFDionne
freeone3000 but for the saving light...
Xen0n
I thought you had the time in something else and wanted GMT
JFDionne
right now est time is -4 but was -5 before the last sunday of march I think...
freeone3000
Yeah. Daylight Savings Time.
Except for Arizona and Hawaii. Those don't observe it, iirc.
JFDionne
do I need to "calcul" that myself?
freeone3000
Meh. Why not. Until someone reorganizes the time zones, it's pretty much going to be that way.
JFDionne
because if i'm right, only 4 time zones use the Daylight Savings time... i'm doing something for people from europe and canada too.. so i'm sure about how they work in europe
Stormchaser
well... Most europe is DST-aware.
kieran776
I know how to fix it, but I was just wondering why if(empty($UserInfo->getBrowserCookieEnabled())) returns errors :S
Stormchaser
php.net/empty. READ it.
kieran776
it returns the same value as $cookieval = $UserInfo->getBrowserCookieEnabled(); if(empty($cookieval))
ok
ah, I see. Thanks Stormchaser
Waldo
How can I screen-scrape a website?
Digitalbear
Good afternoon. I need to ask a simple question, can someone assist me?
Xen0n
!+g1
bah
!tell Digitalbear about g1
zircu
Waldo: pull in the websites content
         

Waldo
zircu, how can I do that?
Storkme
is it possible to grab the auto_increment value from the mysql_query i just executed, without having to execute another query
zircu
Storkme: mysql_insert_id(), be sure that mysql_query() was successful though
Storkme
awesome, thanks
zircu
if you dont you may get an insert_id not for that record that you thought you added
matadamas
i on gnome environment , but it is time to learn qt or gtk , what do you recommend?, people sya that gtk is better....
say*
Storkme
gtk is more widley used, i should think
Digitalbear
created a simple html page containing link <A HREF="welcome.php?name=David"> Hi, I'm David! </A> then created simple hello.php contining <?php
echo( "Welcome to our Web site, $name!" );
?> returns only Undefined variable: name in C:\Inetpub\wwwroot\testsite\welcome.php on line 13
what s wrong?
matadamas
Storkme, what do you use?
Xen0n
ARGH!
zircu
i'd say.. quartz is better :)
Storkme
matadamas, i don't. i'm a java programmer
Xen0n
Digitalbear, you are assuming register_globals is on, which it isnt
Digitalbear, you shouldnt do that... use the global arrays, like $_GET
matadamas
Storkme, i also need to learn java, do you recommend netbeans? on linux
Xen0n
so in that case, $_GET['name']
Digitalbear
<--- is novice (for calrity)
Hal9000
i have error reporting set to off, is there still a way to know if my sql connection is working or not?
matadamas
Storkme, or first start to program from console with jdk
Storkme
matadamas, to be honest, i'd recommend not using an IDE. it makes you lazy
Xen0n
Digitalbear, good to pick up good habits early :P
Stormchaser
<-- is a jumbo jet (for insanity)
Xen0n
(Action) doesnt exist
Storkme
i've been programming java quite a while, i've never used an IDE
Xen0n
(for anything)
Stormchaser
Xen0n: woof.
Storkme
meow.
Xen0n
baaaa!
(Action) runs from the Pretty Horny People channel
matadamas
Storkme, i see, i think as you, so i prefer total control from console, dont know if windows xp has jvm by default?
Digitalbear
I will look into this. thx
Storkme
matadamas, it doesn't
Xen0n
matadamas, it doesnt - licensing issues
Storkme
*shudder* windows
matadamas
ok thanks
Xen0n
hehe
matadamas
i think in few years it will be by default, dont think so
?
Xen0n
Storkme, couldnt agree more :P I havent used it in 10 months - its like going celibate, only in a good way
Storkme
hehe :p
Xen0n, what distro?
Xen0n
matadamas, no, it wont be
matadamas
why do you think that?
Xen0n
matadamas, it used to be, but they were forced to remove it because of licensing issues
in other words, Sun didnt like MS distributing Sun software
Storkme, Gentoo ^_^
matadamas
ohh i didnt know about it was in
Storkme
i need to install gentoo, but i don't have a spare hdd to back up my files with :(
matadamas
i see now
Remi_Woler
Xen0n: err, MS distributed their own version of java, right?
Storkme
*shudder*
ms java is worse then gcj
Xen0n
Remi_Woler, well, kinda... more like patent infringement actually...
Storkme
and that really says something
Remi_Woler
Xen0n: kay
Xen0n
All i know is, Sun got pissed about it
Remi_Woler
that's for usre
matadamas
so i should start with c++, syntaxis beetween java and c++ are similar or different totaly?
Xen0n
So MS removed it
Storkme
matadamas, up to you
Xen0n
Java is a piece of crap purely because of how slow it is...
Storkme
Xen0n, java isn't slow, if you're any good at coding.
Xen0n
or maybe people just code badly with it
Storkme
i've never coded a slow java application
Xen0n
Storkme, i have yet to use a sizeable Java app that isnt slow as hell
Storkme
azureus isn't slow.
Remi_Woler
i've never coded a java application
Xen0n
Storkme, sure it is, when compared to some other things like ktorrent
Storkme
true
Stormchaser
Java is slow by default.
Xen0n
Exactly.
Storkme
well, that's the price we pay for using a jvm :)
Xen0n
oh, and is this a little off-topic?
:P
Storkme
although, java's for loops are faster then c's for loops
Remi_Woler
but at the other hand, it is cross-platform
matadamas
java and c++ are similar about syntaxis?
Storkme
which is utterly insane
Xen0n
Storkme, ... how?
Storkme
i have no idea
Stormchaser
Woof. Yeah. The channel dog says stay on topic. Talk Python :)
Xen0n
Storkme, i doubt java would generate a 10,000x10,000 mandelbrot set image in less time than a C++ app :P
alakazam
matadamas: similar, but there are many fundamental differences
Storkme
Xen0n, true
Xen0n
Storkme, took me 40 minutes and 900MB of RAM ...
alakazam
matadamas: mostly with memory management. If you have no priori programming knowledge, I would recommend trying java out. If you know PHP, same thing.
matadamas
ok, so i prefer starting with java and after going to c++, i think so : /, c++ is not easy to start
Storkme
Xen0n, http://www.idiom.com/~zilla/Computer/javaCbenchmark.html
alakazam
matadamas: absolutely
Storkme
if anything, java has great memory management, due to the garbage collection :)
Xen0n
Storkme, how fscking old is THAT?
Storkme
Xen0n, meh.
Xen0n
seriously...
Storkme
true.
Xen0n
gcc 3.4 and gcc 4.1 are pretty good these days
matadamas
alakazam, i see, hey, white hackers has to know more than one language right?, so its not bad idea to start with java and atter going to c++, altough python is good option too
alakazam, while i got unix, linux, and im learning bash, so im new on this topic.
alakazam
pythonis very different syntax wise if i am not mistaken. And has a much more restricted usefullness, i think
Storkme
Xen0n, http://kano.net/javabench/
zircu
.
matadamas
alakazam, i know html, and little bit of php, wich one do you recommend for start in this great world of programming? after bash even it is just dor scripting.
python?
Stormchaser
hum... ISn't GCC 5 supposed to be out soon?
menace
e
Storkme
i would learn c++, but 'make' scares the pants off me :P
Stormchaser
matadamas: Yeah. Python is fun.
« prev 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 next »