Today

About Programming.

vineri, martie 24, 2006

O noua casa

M-am mutat pe http://www.locknet.ro/

joi, decembrie 15, 2005

PHP, 01==1.

So,

[aurelian@aurelian ~]$ php -r 'var_dump("01"=="1.");'
bool(true)



It's not a bug, it's a well-documented feature ("strings that look like numbers behave like numbers")


:D

duminică, octombrie 09, 2005

WSM, web site

Pagina web pentru proiectul wsm este aproapte gata, totusi ar trebui sa completez sectiunea API, sa mai adaug vreo 2-3 exemple. Apoi o sa trec la corectarea de typos si la reformularea unor propozitii.

Despre wsm, ar mai trebui adaugate cateva metode si sa pot instala un script php ca serviciu windows. Apoi cred ca o sa incerc mutarea in PECL. Totul depinde de cat de mult timp liber am.

Apropos, siteul este aici.

sâmbătă, august 13, 2005

WSM

Am reinceput lucrul la WSM, Windows Service Management.

Writing some code

Extensia fost rescrisa in proportie de 99%, de data aceasta programatorul php va avea la dispozitie un API Object Oriented pentru a controla serviciile windows din php.

Un mic exemplu de cod:

<?php
$service = new WSM_Service('FastWork2-Apache2', 'GREMLIN');
if ($service->status() == 1) {
$service->start();
} else {
$service->stop();
}
echo "Status: " . $service->status(TRUE) . "\n";
echo "Start Type: " . $service->getStartType() . "\n";


In cateva zile(7-10) o sa am si o mica pagina web si un nou release.

Pana atunci, codul se poate downloada de pe cvs: (enter pentru parola)

cvs -d:pserver:anonymous@cvs.wsm.berlios.de:/cvsroot/wsm login
cvs -z3 -d:pserver:anonymous@cvs.wsm.berlios.de:/cvsroot/wsm co wsm

Interfata web pentru cvs este aici.

sâmbătă, iulie 16, 2005

PHP 5, RSS Parsing

How simple?
SimpleXML.


<html>
<head>
<?php
$url = 'http://www.libertatea.ro/index20.xml';
$xml = simplexml_load_file($url);
$rss = $xml->channel;
?>
<title><?php echo $rss->title;?></title>
</head>
<body>
<h2>
<a
href="<?php echo $rss->link;?>"
target="_blank"
title="<?php echo $rss->description;?>"><?php echo $rss->title;?></a>
</h2>
<div>Data: <?php echo $rss->pubDate;?></div>
<hr />
<?php foreach ($rss->item as $item) { ?>
<div>
<a href="<?php echo $item->link;?>"
title="<?php echo $item->title;?>"
target="_blank"><?php echo $item->title;?></a>
</div>
<div><?php echo $item->description;?></div>
<hr />
<?php } ?>
</body>
</html>

joi, iulie 07, 2005

Ruby, The book

Open the book.

Vitamin R.
Goes straight to the head.
Ruby will teach you to express your ideas through a computer.
You will be writing stories for a machine.

Creative skills, people.
Deduction.
Reason.
Nodding intelligently.
The language will become a tool for you to better connect your mind to the world.
I’ve noticed that many experienced users of Ruby seem to be clear thinkers and objective.
(In contrast to: heavily biased and coarse.)

sâmbătă, iulie 02, 2005

Eclipse 3.1

Pe 28.06 a aparut versiunea stabila Eclipse 3.1.
Azi am downloadat-o si eu.


[aurelian@gremlin incoming]$ wget ftp://ftp.craiova.roedu.net/pub/mirrors/ftp.eclipse.org/eclipse/downloads/drops/R-3.1-200506271435/eclipse-SDK-3.1-linux-gtk.tar.gz
--11:35:23-- ftp://ftp.craiova.roedu.net/pub/mirrors/ftp.eclipse.org/eclipse/downloads/drops/R-3.1-200506271435/eclipse-SDK-3.1-linux-gtk.tar.gz
=> `eclipse-SDK-3.1-linux-gtk.tar.gz'
Resolving ftp.craiova.roedu.net... 193.226.37.6
Connecting to ftp.craiova.roedu.net[193.226.37.6]:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done. ==> PWD ... done.
==> TYPE I ... done. ==> CWD /pub/mirrors/ftp.eclipse.org/eclipse/downloads/drops/R-3.1-200506271435 ... done.
==> PASV ... done. ==> RETR eclipse-SDK-3.1-linux-gtk.tar.gz ... done.
Length: 103,755,736 (unauthoritative)

100%[================================================================================================================>] 103,755,736 397.82K/s ETA 00:00

11:40:58 (303.33 KB/s) - `eclipse-SDK-3.1-linux-gtk.tar.gz' saved [103,755,736]