School Map:  Home / Enroll $ Student Records; Class  
$ News @ LIVE Tech Radio * Support/FAQ | Store | FORUMS

 

 (#373 2003-11-10 17:59:08) Post Reply
Page 0 1 2 3 4 5 6 7 8

Arrio
Need To Set


Enrolled: Nov 2003
Posts: 2
AP: 1

<HTML>
<HEAD>
<TITLE>Assignment</TITLE>
</HEAD>
<BODY>
<?
// my info
$name = Arrio;
$favsite = http://www.google.com;
// telling it to say my name and my fav. site
print (My name is $firstname , and my favorite site is $favsite.);
?>
</BODY>
</HTML>

 

 (#374 2003-11-10 18:05:16) Post Reply
Page 0 1 2 3 4 5 6 7 8

Arrio
Need To Set


Enrolled: Nov 2003
Posts: 2
AP: 1

i kinda forgot the " in it, here is the better one

<HTML>
<HEAD>
<TITLE>Assignment</TITLE>
</HEAD>
<BODY>
<?
// my info
$name ="Arrio";
$favsite ="http://www.google.com";
// telling it to say my name and my fav. site
print (My name is $firstname , and my favorite site is $favsite.);
?>
</BODY>
</HTML>

 

 (#376 2003-11-15 22:00:50) Post Reply
Page 0 1 2 3 4 5 6 7 8

tassyrose
Need To Set


Enrolled: Nov 2003
Posts: 1
AP: 1



<html>
<head>
<title>php test</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php //setting variables
$firstname='Rosemary';
$nickname='tassyrose';
$url='http://www.google.com';
//displaying in browser
print("My first name is $firstname <br>My nickname is $nickname<br> and my favourite website is $url");
?>

what is the difference between single and double quotes ?

</body>
</html>



 

 (#378 2003-11-16 12:09:16) Post Reply
Page 0 1 2 3 4 5 6 7 8

coinweb
Need To Set


Enrolled: Nov 2003
Posts: 4
AP: 1

<html>
<head>
<title>Homework for Week #1</title>
</head>
<body bgcolor="yellow">

<?php

//Homework Lesson for Week #1

//First Name
$first = '<b><font color="blue">Jeff</font></b>';

//Last Name
$last = '<b><font color="red">Workman</font>';

//Nickname
$nick = '<b><font color="green">Coinweb</font>';

//Website
$web = '<a href="http://www.coinwebstore.com">http://www.coinwebstore.com</a>';

//Now I'll put it all together

//This is what will be displayed in your browser!
print ("<b>Hello, my name is $first $last.<br>But you can call me $nick ,<br>Please visit my website - $web.</b>");

?>

</body>
</html>

 

 (#381 2003-11-17 13:11:53) Post Reply
Page 0 1 2 3 4 5 6 7 8

PureGrain
Need To Set


Enrolled: Nov 2003
Posts: 14
AP: 1

[CODE]
<HTML>
<HEAD>
<TITLE>Assignment 1</TITLE>
</HEAD>
<BODY>

// Week One
//Assigning the variables
<?php
$mYnick = "PureGrain";
$mYsite = "http://www.completronics.com";
/php?>

//Printing to browser.
<?php
print ("Hello my nick name is $mYnick <BR>My website is $mYsite. <BR>Which is not working at the moment!!;)
php?>


</BODY>
</HTML>

Please tell me if this is ok. I just started learning this today.
[/CODE]

 

 (#382 2003-11-17 13:14:17) Post Reply
Page 0 1 2 3 4 5 6 7 8

RamblnRick
Need To Set


Enrolled: Nov 2003
Posts: 6
AP: 1

Hi, I started this course once long ago. Here I am starting over.

[PHP]
<?php
// This script will display my name and favorite website
// Assign Variables
$firstname='Ramblin ';
$lastname='Rick';
$favsite='<a href="http://www.scriptschool.com">ScriptSchool';
// Print to browser
print("Hello! My name is $firstname $lastname.<br>My Favorite website is $favsite");
?>
[/PHP]


 

 (#383 2003-11-17 13:21:33) Post Reply
Page 0 1 2 3 4 5 6 7 8

PureGrain
Need To Set


Enrolled: Nov 2003
Posts: 14
AP: 1

I am correcting what I think is wrong with my last post.

<HTML>
<HEAD>
<TITLE>Assignment 1</TITLE>
</HEAD>
<BODY>

// Week One
//Assigning the variables
<?php
$mYnick = 'PureGrain';
$mYsite = 'http://www.completronics.com';
?>

//Printing to browser.
<?php
print ("Hello my nick name is $mYnick <BR>My website is $mYsite. <BR>Which is not working at the moment!!;)
?>


</BODY>
</HTML>

Please let me know if it is right?

 

 (#387 2003-11-17 18:29:48) Post Reply
Page 0 1 2 3 4 5 6 7 8

Topher
Need To Set


Enrolled: Nov 2003
Posts: 3
AP: 1

<HTML>
<HEAD><TITLE>Learning PHP</title></head>
<BODY>

<?
//This code is being made to display my name and favorite website
//This is the string for my name
$name="Topher";
//This is the string for my favorite website
$website="http://www.musicfreaksonline.com";
//This is the print line where I place the strings to display them
print("My name is $name and my favorite website, that I also built myself, is $website");
?>
</body>
</html>

 

 (#394 2003-11-20 16:05:51) Post Reply
Page 0 1 2 3 4 5 6 7 8

TDavid
php mySQL Perl C/C++
Principal


Enrolled: Mar 2000
Posts: 193
AP: 1

Welcome to the new students taking the course :)

 

 (#395 2003-11-20 18:49:30) Post Reply
Page 0 1 2 3 4 5 6 7 8

mizmerry
Need To Set


Enrolled: Nov 2003
Posts: 1
AP: 1

When I save the file in Wordpad, I get some weird characters at the top; I don't get that in Notepad.

<?
// Introductory statement
printf(Hi, my name is );
// My name
$my_name=MizMerry;
print($my_name);
// 2nd statement
printf(, and one of my favourite sites is );
// URL
$fav_url=www.moby.com;
print($fav_url);
?>

 

 (#396 2003-11-21 14:57:24) Post Reply
Page 0 1 2 3 4 5 6 7 8

Quicksaver
Need To Set


Enrolled: Sep 2003
Posts: 90
AP: 1

dont save it to wordpad then :)

 

 (#398 2003-11-21 18:21:01) Post Reply
Page 0 1 2 3 4 5 6 7 8

hatiangeek
Need To Set


Enrolled: Nov 2003
Posts: 2
AP: 1

<?php
// This string varialbe is used to store my name
$myName="HaitianGeek";
//Wbsite stores my favorite website
$Wbsite1="Akolad.com";
$Wbsite2="http://www.expresswebsite.com";

// print my name and my favorite website using the print function
print("My name name is: ");
print($myName);
print(", and my favorites websites are: " );
print($Wbsite1);
print(", and ");
print($Wbsite2);
?>

 

 (#403 2003-11-25 01:04:36) Post Reply
Page 0 1 2 3 4 5 6 7 8

hyspeed1
Need To Set


Enrolled: Nov 2003
Posts: 1
AP: 1

<HTML>
<HEAD>
<TITLE>The Hyspeed1's Comeback, Assignment 1</TITLE>
</HEAD>
<BODY>
<?
//This will show my name and website using variables
//assign the variables
$firstname="Jim";
$lastname="Embrey";
$nickname="hyspeed1";
$prayer="please php gods let the script work";
$living="My lovely wife Angela, and my son Andrew";
$website="www.h1cc.net";
//Print command to display information into a browser
print("Hi, I'm $firstname $lastname also known as $nickname, and I'll throw in a random plug for $living, oh and by the way my website is $website " );
//Prayer to see if code worked
print("$prayer");
?>
</BODY>
</HTML>


 

 (#406 2003-11-28 02:17:09) Post Reply
Page 0 1 2 3 4 5 6 7 8

DJRemiasz
Need To Set


Enrolled: Nov 2003
Posts: 3
AP: 1

<?
$DJ = "DJRemiasz";
$site = "http://www.stuff4u.risata.org";
//Below is the site name
print("Hey Wassup my name is $DJ and I manage the site $site");
?>

 

 (#412 2003-12-10 03:56:36) Post Reply
Page 0 1 2 3 4 5 6 7 8

junwei
Need To Set


Enrolled: Dec 2003
Posts: 1
AP: 1

<script language="php">
$myname = "Junwei"; // my first name
$mynick = "jw"; // my initial or nick
$myfavoriteweb = "http://www.google.com"; // my favorite website

printf("My name is $myname.<br>");
printf("My nickname is $mynick.<br>");
printf("My favorite website is <a href=$myfavoriteweb target='new'>$myfavoriteweb</a>.<br>");
</script

 

 (#413 2003-12-10 08:23:18) Post Reply
Page 0 1 2 3 4 5 6 7 8

fudded
Need To Set


Enrolled: Dec 2003
Posts: 5
AP: 1



<html>
<head>
<title>Lesson One</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<center>
<?php
// set variables
$firstname= 'Sean';
$lastname= 'Knowles';
$nick= 'fudded';
$url='http://members.lycos.co.uk/seanknowles/';
// display information to web page
print("My name is $firstname $lastname, my IRC nick is $nick <br> My new web site is $url")
?>

<body>
</center>
</body>
</html>


 

 (#425 2003-12-23 13:19:11) Post Reply
Page 0 1 2 3 4 5 6 7 8

JayWilson
Need To Set


Enrolled: Dec 2003
Posts: 1
AP: 1

<html>
<head>
<title>Script School Week 1</title>
</Head>
<body>

<?php

//This is a comment, the lines below are strings
$MYNAME = Jay
$WEBSITE = www.HappyHacker.org

//The line below will print to the webpage
print(My name is $MYNAME, and my favorite website is $WEBSITE.)

?>

</body>
</html>

 

 (#427 2003-12-25 12:15:02) Post Reply
Page 0 1 2 3 4 5 6 7 8

TylerTT
Need To Set


Enrolled: Dec 2003
Posts: 2
AP: 1



<html>
<head>
<title>Variables</title>
</head>
<body>
<?php
// Set the variables
$nickname = "Tyler";
$URL = "google.com";

// Print the variables
print("$nickname<br>");
print(
"<a

href=
\"http://www.$URL\">http://www.$URL</a>"

);
?>
</body>
</html>


 

 (#428 2003-12-26 00:24:36) Post Reply
Page 0 1 2 3 4 5 6 7 8

n2o2k
Need To Set


Enrolled: Dec 2003
Posts: 6
AP: 1

<html>
<?
/*
* To do Assignement #1
*/
//Store the name
$name="life";
//store my favorite url
$url="www.hotmail.com";

//print the name and the favoritr url
echo("My name is ".$name. " <br>My favorite url is <a href=\"http://".$url."\">".$url."</a>");

?>
</html>

 

 (#430 2003-12-26 12:34:43) Post Reply
Page 0 1 2 3 4 5 6 7 8

TDavid
php mySQL Perl C/C++
Principal


Enrolled: Mar 2000
Posts: 193
AP: 1

Welcome to the course, n2o2k. You do not need to use concatenation with those variables enclosed in double quotes (this is called interpreted).

 

 (#432 2003-12-27 18:38:47) Post Reply
Page 0 1 2 3 4 5 6 7 8

n2o2k
Need To Set


Enrolled: Dec 2003
Posts: 6
AP: 1

ok!

 

 (#454 2004-01-07 19:29:23) Post Reply
Page 0 1 2 3 4 5 6 7 8

Alex88
Need To Set


Enrolled: Jan 2004
Posts: 1
AP: 1

<?
// week 1 assignmnet
$name = "Alex88";
// faorite url
$favURL = "www.ferreira.com"
print($name);($favURL);
?>


Don't have the means to test the code yet, but how does it look?
Thanks

 

 (#455 2004-01-08 02:07:39) Post Reply
Page 0 1 2 3 4 5 6 7 8

Zeyix
Need To Set


Enrolled: Jan 2004
Posts: 2
AP: 1

This is my very first time ever using PHP and this code i have hear didn't seem to work on my server. :(



<html>

<head>Assignment #1</head>

<body>

<? // start of php code

$myname = "Shane"; // $myname will now show as Shane

$myfavwebsite = "http://www.opentechsupport.net"; // $mywebsite will now show as that site

print(Hey, my name is $myname and my favorite website is $myfavwebsite); // prints this text on the page
?> // end of php code
</body>
</html>


 

 (#456 2004-01-08 18:33:56) Post Reply
Page 0 1 2 3 4 5 6 7 8

Zeyix
Need To Set


Enrolled: Jan 2004
Posts: 2
AP: 1

I see what i did wrong now.



<html>
<head>
<title> This is a test! </title>
</head>
<body>

<? //starts php code

$myname="Shane"; //sets "$myname" to show as "Shane"
$favsite="http://www.opentechsupport.net"; //sets "$favsite" to show as that website

print("Hey, my name is $myname and my favorite website is $favsite");
//prints what I have there onto the page changing the strings to what they were set to

?>

</body>
</html>


 

 (#457 2004-01-09 18:53:22) Post Reply
Page 0 1 2 3 4 5 6 7 8

Ash2k4
Need To Set


Enrolled: Jan 2004
Posts: 7
AP: 1



<HTML>
<HEAD>
<TITLE>ScriptSchool.com - 16 week PHP Course - To-do Assignment #1</TITLE>
</HEAD>
<BODY>
<?
// Assigns the values to the strings
$firstname = 'Ashley';
$lastname = 'Czirok';
$favsite = '<a href="http://www.my-symbian.com">www.my-symbian.com</a>';
$email = '<a href="mailto:a_czirok@hotmail.com">a_czirok@hotmail.com</a>';
// Prints the strings created
print("My name is: $firstname $lastname<br />My favourites site is: $favsite<br />My e-mail is: $email")
?>
</BODY>
</HTML>


 

 (#461 2004-01-11 13:31:51) Post Reply
Page 0 1 2 3 4 5 6 7 8

brad
Need To Set


Enrolled: Jan 2004
Posts: 2
AP: 1

First Assignment :)



*/First assignment for Script Schools,
Date : 11/01/04
/*

<?php
//Assigning variables

$name="Brad";
$fav_site="<a href="http://www.dynofusion.com">Dynofusion</a>;
$fav_site2="<a href="http://www.google.com">Google</a>;

//Printing the variables

print("<strong>Hey Scriptschool,</strong><br>My nick name is $name, and my website is $fav_site.
<br>Being my web site it is obviously one of my favorites :).
<br>I also visit $fav_site2 pritty often. You'v probably never heard of it but i like it"
)

print(
$name); //printing firstname variable.
print($fav_site); //printing favorite site variable.
print($fav_site2); //printing second favorite site.
?>



 

 (#462 2004-01-11 13:34:10) Post Reply
Page 0 1 2 3 4 5 6 7 8

brad
Need To Set


Enrolled: Jan 2004
Posts: 2
AP: 1

Whoops didint mean to post the
print($name); //printing firstname variable.
print($fav_site); //printing favorite site variable.
print($fav_site2); //printing second favorite site.



Ignore it

Thanks

 

 (#463 2004-01-13 08:12:02) Post Reply
Page 0 1 2 3 4 5 6 7 8

Sety
Need To Set


Enrolled: Jan 2004
Posts: 5
AP: 1

<?
print("What's up , motherfuckers");

print " GIA !!! print() also works without parentheses.";

print "First line...
second line....Do you see something special man?";
print "First line...second line.This damn lines don't want to change!!!HAHAHA";

// Listen man !!! Did you know that you can use variables inside of a print statement ?
$myname = "Sety Power";
$mysite = "www.sety.go.ro";

print "My name moderfuckers is $myname"; // My name moderfuckers is Sety Power

// Take that rats !!! Using single quotes will print the variable name, not the value
print 'Sety is $myname'; // Sety is $myname

// Notice that giantrats !!! When you print a string you do not need the quotes surrounding the string
print($mysite); // www.sety.go.ro
PLEASE teacher...don't delete this post!!!
Damn...is all I can!!!
I promis to be a good student!!!
CYA lesson 1,damn it!!!
?>

 

 (#464 2004-01-13 15:55:46) Post Reply
Page 0 1 2 3 4 5 6 7 8

vladdrac
Need To Set


Enrolled: Dec 2003
Posts: 14
AP: 1

<html>
<head>
<title> <?php echo " PHP page"?>
</title>
</head>
<body>

<?php
$first="Vlad";
$last="Drac";
$email="<a href='mailto:0vladdrac@aol.com'>here</a>";
$url="<a href='http://www.geocities.com/ruffryder23_2002'>VladdracWorld</a>";



print("whassup fools? <br />My name is $first$last. <br />You can email me $email. <br /> Visit my website at $url.");



?>

</body>
</html>

oh, my editor is not php freindly, by the way how do you post is color?

 

 (#465 2004-01-13 16:11:50) Post Reply
Page 0 1 2 3 4 5 6 7 8

vladdrac
Need To Set


Enrolled: Dec 2003
Posts: 14
AP: 1




<html>
<head>
<title> <?php echo " PHP page"?>
</title>
</head>
<body>

<?php
$first
="Vlad";
$last="Drac";
$email="<a href='mailto:0vladdrac@aol.com'>here</a>";
$url="<a href='http://www.geocities.com/ruffryder23_2002'>VladdracWorld</a>";



print(
"whassup fools? <br />My name is $first$last. <br />You can email me $email. <br /> Visit my website at $url.");



?>

</body>
</html>




ok thanks TD, could you remove the previous?

 

  Page 0 1 2 3 4 5 6 7 8

View Previous Thread
Print this page Print This Page

View Next Thread

School Map:  Home / Enroll $ Student Records; Class  
$ News @ LIVE Tech Radio * Support/FAQ | Store

Advertising | Link To Us | Privacy 
Copyright 2000-2002 Script School Productions / KMR Enterprises 
No part of this website may be reproduced, copied and/or distributed in any medium 
without express written permission