Explain this please

SpaceshipSpaceship
Namecheap AuctionsNamecheap Auctions
Namecheap AuctionsNamecheap Auctions
Watch
Impact
19
Code:
<?php
$line = date("m.d.y") . "|" . $HTTP_POST_VARS['name'];
$line .= "|" . $HTTP_POST_VARS['news'];
$line = str_replace("\r\n","<BR>",$line);
$line .= "\r\n";
?>

Okay, I am reading a tutorial and i really dont get this part and they didnt explain it either

y is there 4 $line variables? i thought u could only have one
and y is there a "." before the "="

and whats "/r/n" etc...
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
unknowngiver said:
Still the same
here is the code now

Code:
$password='zubair'
if($HTTP_POST_VARS['submit']) {
    if($HTTP_POST_VARS['password'] == $password) {
        if(!$HTTP_POST_VARS['name']) {
            echo "You must enter a name";
            exit;
        }
        if(!$HTTP_POST_VARS['news']) {
            echo "You must enter some news";
            exit;
        }
PHP:
$password='zubair';
if($HTTP_POST_VARS['submit']) {
    if($HTTP_POST_VARS['password'] == $password) {
        if(!$HTTP_POST_VARS['name']) {
            echo "You must enter a name";
            exit();
        }
        if(!$HTTP_POST_VARS['news']) {
            echo "You must enter some news";
            exit();
        }
}
 
0
•••
. means append
\r\n means Winodws newline
 
0
•••
Help

didnt work guys
 
0
•••
nvmd

Just changed a couple of things.. Modified from my original post.
PHP:
<?php
$password = 'zubair';
if($HTTP_POST_VARS['submit']) {
    if($HTTP_POST_VARS['password'] == $password) {
        if(!$HTTP_POST_VARS['name']) {
            echo "You must enter a name";
            exit;
        }
        if(!$HTTP_POST_VARS['news']) {
            echo "You must enter some news";
            exit;
        }
}
?>
 
0
•••
CatchedCatched

We're social

Escrow.com
Spaceship
Escrowly
CryptoExchange.com
Domain Recover
URLs.com
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back