Source: tingletechcloud based machine learning tools /via http://news.ycombinator.com/item?id=3639746
The Fray - Heartless
In the night, I hear ‘em talk
The coldest story ever told.
Somewhere far along this road he lost his soul…
To a woman so heartless.
How could you be so heartless?
How could you be so heartless?
How could you be so
Cold as the winter wind when it breeze, yo
Just remember that you talking to me, yo
You need to watch the way you talking to me, yo
I mean after all the things that we been through
I mean after all the things we got into
And yo, I know some things that you ain’t told me
Yo, I did some things but that’s the old me
And now you wanna gimme back
And you gon’ show me
So you walk round like you don’t know me
You got a new friend
I got homies
But in the end it still so lonely
In the night, I hear ‘em talk
The coldest story ever told.
Somewhere far along this road he lost his soul…
To a woman so heartless.
How could you be so heartless?
How could you be so heartless?
How could you be so Dr. Evil
You’re bringing out a side of me that I don’t know,
I decided we weren’t gon’ speak so why we’re up 3 a.m. on the phone,
Why does she be so mad at me for
Honey I don’t know she’s hot and cold,
I won’t stop won’t mess my groove up cause I already know how this thing go,
You run and tell your friends that you’re leavin’ me,
They say that they don’t see what you see in me,
You wait a couple months then you gone’ see,
You’ll never find nobody better than me
In the night, I hear ‘em talk
The coldest story ever told.
Somewhere far along this road he lost his soul…
To a woman so heartless.
How could you be so heartless?
How could you be so heartless?
Talkin’, talkin’, talkin’, talk
Baby let’s just knock it off
They don’t know what we been through
They don’t know ‘bout me and you
So I got something new to see
And you just gon’ keep hatin’ me
And we just gonna be enemies
I know you can’t believe
I could just leave it wrong
And you can’t make it right
So I’m gon’ take off tonight
Into the night
I hear ‘em talk
The coldest story ever told.
Somewhere far along this road he lost his soul…
To a woman so heartless.
How could you be so heartless?
How could you be so heartless?
Cobra Starship - Nice Guys Finish Last
I was just a kid working for the man for the first time
He said listen kid you better hear my advice
Treat’em like dirt
They stick forever to the bottom of your shoe (ooooh, ooh)
I said Mr. Man that ain’t nice
You gotta treat a girl right
Take her out, wine and dine her,
Always be polite
Kid, all good does you,
But soon you’ll see she don’t want no goody two shoes
Boy just a goody two
Goody two shoes
Just a goody two
Two shoes
You got style, you got grace
But, kid, you try so hard she just laughs in your face
You’re a nice guy with the wrong attitude
She want a bad boy (bad boys bad boys all we want is bad boys)
I treat her dirt, she loves me good (so good)
And I just hate to have to tell you
‘Cause you’re a nice guy but that just won’t do
She want a bad boy (bad boys bad boys all we want is bad boys)
Listen kid, you hear them sirens coming for me
But, when I get downtown she will already be
Posting bail in her favorite dress
Smiling at me because I’m no good
You can buy her everything she likes, and I’m sure she’ll be obliged
To let you steal a kiss, maybe even spend the night
Kid, all good, just know that she’ll be thinking of me, even when she’s with you
Boy just a goody two
Goody two shoes
Just a goody two
Two shoes
You got style, you got grace
but kid you try so hard she just laughs in your face
You’re a nice guy with the wrong attitude
She want a bad boy (bad boys bad boys all we want is bad boys)
I treat her bad, she loves me good (so good)
And I just hate to have to tell you
‘Cause you’re a nice guy but that just won’t do
She want a bad boy (bad boys bad boys all we want is bad boys)
Whoa, alright now,
Singles ladies (yeah)
I’m gonna need your help now
(Tell us whatcha want us to do now [x2])
I need help your girls
(You’re a bad boy)
I say I need help now (help now)
So bad (so bad)
So good (so good)
So bad (bad)
Good (good)
Goddamn, You got style, you got grace
You try so hard she just laughs in your face
You’re a nice guy with the wrong attitude
She want a bad boy (bad boys bad boys all we want is bad boys)
I treat her bad, she loves me good(so good)
And I just hate to have to tell you
‘Cause you’re a nice guy but that just won’t do
She want a bad boy (bad boys bad boys all we want is bad boys)
Boy just a goody two
Goody two shoes
Just a goody two
Two shoes
Login Form
let’s assume that a valid username should be alphanumeric characters only, start with a letter, have a minimum length of 6, and maximum length of 20; they will be normalized to lowercase. Passwords must be a minimum of 6 characters.
$form = new Zend_Form();
$form->setAction('/user/login')
->setMethod('post');
$username = $form->createElement('text', 'username');
$username->addValidator('alnum')
->addValidator('regex', false, array('/^[a-z]+/'))
->addValidator('stringLength', false, array(6, 20))
->setRequired(true)
->addFilter('StringToLower');
$password = $form->createElement('password', 'password');
$password->addValidator('StringLength', false, array(6))
->setRequired(true);
$form->addElement($username)
->addElement($password)
->addElement('submit', 'login', array('label' => 'Login'));
UserController
As you’ll note from the controller code, there’s more work to do: while the submission may be valid, you may still need to do some authentication using Zend_Auth or another authorization mechanism.
class UserController extends Zend_Controller_Action {
public function getForm() {
return $form;
}
public function indexAction() {
$this->view->form = $this->getForm(); // render user/form.phtml
$this->render('form');
}
public function loginAction() {
if (!$this->getRequest()->isPost()) { return $this->_forward('index'); }
$form = $this->getForm();
if (!$form->isValid($_POST)) {
// Failed validation; redisplay form
$this->view->form = $form;
return $this->render('form');
}
$values = $form->getValues();
}
}
View
Please login:
<?php echo $this->form ?>
Using a Zend_Config Object
All Zend_Form classes are configurable using Zend_Config; you can either pass a Zend_Config object to the constructor or pass it in with setConfig().
We might create the above form using an INI file.
[development] ; general form metainformation user.login.action = "/user/login" user.login.method = "post" ; username element user.login.elements.username.type = "text" user.login.elements.username.options.validators.alnum.validator = "alnum" user.login.elements.username.options.validators.regex.validator = "regex" user.login.elements.username.options.validators.regex.options.pattern = "/^[a-z]/i" user.login.elements.username.options.validators.strlen.validator = "StringLength" user.login.elements.username.options.validators.strlen.options.min = "6" user.login.elements.username.options.validators.strlen.options.max = "20" user.login.elements.username.options.required = true user.login.elements.username.options.filters.lower.filter = "StringToLower" ; password element user.login.elements.password.type = "password" user.login.elements.password.options.validators.strlen.validator = "StringLength" user.login.elements.password.options.validators.strlen.options.min = "6" user.login.elements.password.options.required = true ; submit element user.login.elements.submit.type = "submit"
Form Constructor
$config = new Zend_Config_Ini($configFile, 'development'); $form = new Zend_Form($config->user->login);
MotoHelper é uma aplicação de computador que mantém seus drivers de dispositivos Motorola atualizados. Além disso, os telefones que suportam o MotoHelper avisam sobre atualizações de software quando disponíveis para o dispositivo e automaticamente as baixam. Aplicações tais como Motorola Media Link e Motorola Phone Portal serão atualizadas automaticamente quando seu celular está conectado ao PC via USB.