Go Back   Webmaster Malaysia Forum » Website Design & Development » Website Programming

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 16-04-2008, 09:13 AM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
Smile Assalamualaikum

Lama x masuk dalam forum ni...
actually just a simple question maybe bg yg expert dlm PHP memang tau jawapan nye.. so harap dapat membantu...

Mukadimah:
Dari ASP --> ASP.Net & skang ni baru nak menjinak kan diri dalam PHP ni..
maybe bg webmaster yg lain tergelak ngan keterbalikan cara saya belajaQ...

Maklumat
Windows SERVER 2003 ENT SP2
IIS 6
MS SQL V8.0
Mozilla firefox2, Ie7
WAMP 2 "Apache2,MySQL5,PHP5"PHPmyadmin,SQLiteManager"
terdapat 4 Localhost di berlainan DRIVE
Text Editor Dreamweaver,Notepad++,Notepad

Masalah
Wamp server dah jalan ngan cantik "alahamdullilah"
akan tetapi pabila saya memulakan kerja utk membina web "PHP"
data atau value yg sepatutnya keluar contoh simple calculation / tarikh tak keluar..

Solution
Apa yang salah?
Dimana yang salah?
Apa yang patut saya buat?
Kat mana patut saya check?

So harap benar boleh membantu

Contoh
Link contoh PHP yang bermasalah

Mail
Izzuan@linuxmail.org
Dehackers@linuxmail.org
Dehackerz@gmail.com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 16-04-2008, 09:42 AM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
sepatutnya kerja kod kenalah ada kodnya sekali, baru boleh dibantu.

saya rasa, berkemungkinan berkaitan Register Global = off .
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 16-04-2008, 04:07 PM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
reply

Ahaks...
dah register_globals = On dah lama di on kan nye..
tapi sedey nye cam x leh gak aje...

ok ok coding nye ni :

<?
// Hello Dunia Ku.
// Dehackers™ Works.
$tarikh = date('dd/M/Y');
// cetakkan tarikh dalam page.
echo "Tarikh Hari ini : $tarikh ";
?>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 16-04-2008, 04:48 PM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
dan 1 lagi contoh yang tak kuaQ value

upload_form.html
<HTML>
<HEAD>
<TITLE>Upload File</TITLE>
</HEAD>
<BODY>
<H1>Upload A File</H1>
<FORM METHOD="POST" ACTION=" do_upload.php" ENCTYPE="multipart/form-data">
<p><strong>File to Upload:</strong><br>
<input type="file" NAME="img1" SIZE="30"></p>
<p><INPUT type="submit" NAME="submit" VALUE="Upload File"></p>
</FORM>
</BODY>
</HTML>


do_upload
<?

if ($_FILES[img1] != "") {

@copy($_FILES[img1][tmp_name],"http://www.fce.uitm.edu.my/Izzuan/wamp/bin/apache/apache2.2.8/htdocs".$_FILES[img1] [name])
or die("Couldn`t copy the file.");

} else {

die("No input file specified");
}

?>
<html>
<head>
<title>Successful File Upload</title>
</head>
<body>
<H1>Success!</H1>

<p>You sent: <? echo_FILES[img1] [name]; ?>, a <? echo $_FILES[img1][size]; ?> byte file with a mime type of <? echo $_FILES[img1][type]; ?>.</p>

</body>
</html>

kalau nak nengok link kat sini
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 16-04-2008, 08:13 PM
amaRDaniel's Avatar
Inspired Webmaster
 
Join Date: Sep 2005
Location: shah alam
Posts: 111
Rep Power: 40
amaRDaniel is on a distinguished road
Quote:
Originally Posted by Dehackers View Post
Ahaks...
dah register_globals = On dah lama di on kan nye..
tapi sedey nye cam x leh gak aje...

ok ok coding nye ni :

<?
// Hello Dunia Ku.
// Dehackers™ Works.
$tarikh = date('dd/M/Y');
// cetakkan tarikh dalam page.
echo "Tarikh Hari ini : $tarikh ";
?>
result kat pc aku kuar gini..
Tarikh Hari ini : 1616/Apr/2008

so mungkin yg "dd" dua ekor tu.. ko buang tinggalkan sekor jer..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 16-04-2008, 08:14 PM
amaRDaniel's Avatar
Inspired Webmaster
 
Join Date: Sep 2005
Location: shah alam
Posts: 111
Rep Power: 40
amaRDaniel is on a distinguished road
Quote:
Originally Posted by Dehackers View Post
dan 1 lagi contoh yang tak kuaQ value

upload_form.html
<HTML>
<HEAD>
<TITLE>Upload File</TITLE>
</HEAD>
<BODY>
<H1>Upload A File</H1>
<FORM METHOD="POST" ACTION=" do_upload.php" ENCTYPE="multipart/form-data">
<p><strong>File to Upload:</strong><br>
<input type="file" NAME="img1" SIZE="30"></p>
<p><INPUT type="submit" NAME="submit" VALUE="Upload File"></p>
</FORM>
</BODY>
</HTML>


do_upload
<?

if ($_FILES[img1] != "") {

@copy($_FILES[img1][tmp_name],"http://www.fce.uitm.edu.my/Izzuan/wamp/bin/apache/apache2.2.8/htdocs".$_FILES[img1] [name])
or die("Couldn`t copy the file.");

} else {

die("No input file specified");
}

?>
<html>
<head>
<title>Successful File Upload</title>
</head>
<body>
<H1>Success!</H1>

<p>You sent: <? echo_FILES[img1] [name]; ?>, a <? echo $_FILES[img1][size]; ?> byte file with a mime type of <? echo $_FILES[img1][type]; ?>.</p>

</body>
</html>

kalau nak nengok link kat sini
yg nie ok jer..
hak hak hak..
Quote:
Success!

You sent: , a byte file with a mime type of .
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 17-04-2008, 07:42 AM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
alamak amaRDaniel....
me dah tinggal kan D tu sorang2 tapi still problem...
thats mean masalah coding tu x berapa nak timbul..
tapi masalah value yg spatutnye kuaQ tak kuaQ...
PHP me setting senget kot?
tapi mana senget nye yerk?
mueheheheh
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 17-04-2008, 11:00 PM
amaRDaniel's Avatar
Inspired Webmaster
 
Join Date: Sep 2005
Location: shah alam
Posts: 111
Rep Power: 40
amaRDaniel is on a distinguished road
Quote:
Originally Posted by Dehackers View Post
alamak amaRDaniel....
me dah tinggal kan D tu sorang2 tapi still problem...
thats mean masalah coding tu x berapa nak timbul..
tapi masalah value yg spatutnye kuaQ tak kuaQ...
PHP me setting senget kot?
tapi mana senget nye yerk?
mueheheheh
owh tu susah ler nak tahu mana yg senget tu bey..
aku test code tu kat local pc jer.. ok jer..
try ler tanyal awek2 cun compscience kat uitm tu..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 18-04-2008, 01:07 AM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
PHP Code:
<p>You sent: <? echo_FILES[img1] [name]; ?>, a <? echo $_FILES[img1][size]; ?> byte file with a mime type of <? echo $_FILES[img1][type]; ?>.</p>
nih betul ker ?
<? echo_FILES[img1] [name]; ?>

ke sepatutnya :
<? echo $_FILES[img1] [name]; ?>

*lama tak main php nih, kekok dah
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 18-04-2008, 07:58 AM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
ahaks...
coding tu tersilap skit but it still wont work...
me rasa ada prob ngan PHP setting je...

arghh sedey la..
PHP setting lari laa..
nak kejaQ tak reti..
heheheh
cam ne yerk?
leh la bantu....
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #11 (permalink)  
Old 18-04-2008, 11:32 AM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
<?
// Hello Dunia Ku.
// Dehackers™ Works.
$tarikh = date('dd/M/Y');
// cetakkan tarikh dalam page.
echo "Tarikh Hari ini : $tarikh ";
?>

yang nih pun tak keluar ke?
kalau tak kuar.. ada prob ngan server la kot?
dah try kat lain2 hosting?
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #12 (permalink)  
Old 18-04-2008, 09:44 PM
Novice Webmaster
 
Join Date: Aug 2007
Location: UiTM Shah Alam Selangor
Posts: 13
Rep Power: 0
Dehackers is on a distinguished road
Quote:
Originally Posted by mysticmind View Post
<?
// Hello Dunia Ku.
// Dehackers™ Works.
$tarikh = date('dd/M/Y');
// cetakkan tarikh dalam page.
echo "Tarikh Hari ini : $tarikh ";
?>
yang ni memang tak kuaQ
tu arr masalah ngan SERVER but
kalau pakai posting language ASP ok plak isk isk...
.... your server pakai PHP yerk?
me nak check setting PHP ngan kamu nak buat compare setting..
leh x?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #13 (permalink)  
Old 19-04-2008, 12:28 AM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,633
Rep Power: 142
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
try guna <?php bukan sekadar <? je
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #14 (permalink)  
Old 22-04-2008, 03:30 PM
New kid on the block
 
Join Date: Apr 2007
Location: OZ
Posts: 1
Rep Power: 0
seventhakmal is on a distinguished road
aku rasa la masalahnye sebab srver tak jalan kot. dulu masa aku cuba mula2 ngetest php guna tutorial dr mystic, sama gak tak jadi. pastu cek punya cek rupanya sebab server. tapi ko nyer masalah, aku xtau la. mungkin sama cam aku. mungkin idak.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #15 (permalink)  
Old 26-04-2008, 07:09 AM
just's Avatar
Novice Webmaster
 
Join Date: Mar 2005
Location: JB
Posts: 14
Rep Power: 0
just is on a distinguished road
Send a message via Yahoo to just
Post

Quote:
Originally Posted by Dehackers View Post
Ahaks...
dah register_globals = On dah lama di on kan nye..
tapi sedey nye cam x leh gak aje...

ok ok coding nye ni :

<?
// Hello Dunia Ku.
// Dehackers™ Works.
$tarikh = date('d/M/Y');
// cetakkan tarikh dalam page.
echo "Tarikh Hari ini : $tarikh ";
?>

klau jln kat local pc, sy rs IIS n WAMP ang conflict. cuba ang stop IIS service. sbb sy pnh jd mcm nie, langsung xkeluar ape2, last2 stopkn IIS service trus idop.. check It zout.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Assalamualaikum and Hello ilmi_naj Member Introductions 0 16-02-2008 02:15 AM
Assalamualaikum wonggogel Member Introductions 3 19-11-2007 01:27 PM
Assalamualaikum Dehackers Member Introductions 3 23-08-2007 12:47 AM
assalamualaikum are_yusz Member Introductions 1 22-12-2006