Symbianize Forum

Most of our features and services are available only to members, so we encourage you to login or register a new account. Registration is free, fast and simple. You only need to provide a valid email. Being a member you'll gain access to all member forums and features, post a message to ask question or provide answer, and share or find resources related to mobile phones, tablets, computers, game consoles, and multimedia.

All that and more, so what are you waiting for, click the register button and join us now! Ito ang website na ginawa ng pinoy para sa pinoy!

[tutorial] php (procedurals) tagalog na ako mismo gumawa

Dapat kinompleto mo na, like Indexing, Sorting, Paganation, at Report convert to excel or pdf file boss
 
Dapat kinompleto mo na, like Indexing, Sorting, Paganation, at Report convert to excel or pdf file boss

manghihingi ka na nga lang, nagmamadali ka pa... baka naman may sariling buhay din yang gumawa niyan. Buti nga at may ganyan nagse-share ng nalalaman eh. Matuto ka din maghintay.
 
Dapat kinompleto mo na, like Indexing, Sorting, Paganation, at Report convert to excel or pdf file boss


hindi po lahat ng bagay ay dapat isubo sa inyo, mat mga bagay lang din na ibibigay lang sayo yung guide at ikaw na ang bahala mag explore for your own knowledge sake.

just saying. thanks for drop by.

- - - Updated - - -

manghihingi ka na nga lang, nagmamadali ka pa... baka naman may sariling buhay din yang gumawa niyan. Buti nga at may ganyan nagse-share ng nalalaman eh. Matuto ka din maghintay.

yung mga ganyan boss tamad yan. di marunong mag research. kung gusto mo maging IT, matuto rin sana mag research. di yung puro pasubo. hahaha thanks mate.
 
Sa second figure mo, napansin ko lang sa conditions mo,

if(empty($_POST["name"]))

suggest lang, cguro gamitin mo ang mga functions ng php para maging secure ang system. For now cguro oke lang yan kc basi panaman.


try mo to sa baba

1. Problem with empty value

<?php

$_POST["name"]=" "; ////puro space walang laman na character


if(!empty($_POST["name"])) //check if empty
{

echo "Your name is =". $_POST["name"]; ////echo the value

}
else
{

echo "Your name is ="empty"; ////echo the value

}
?>


OUTPUT: Your name is


So ang space ay valid value.

-> correct


a) if(!empty(trim($_POST["name"])) //trim spaces before checking if empty :note space between letters are not trim sample trim("he llo") = he llo
b) $name = trim($_POST["name"]; //trim spaces before checking if empty trim(" hello") = hello, trim(" hello ") = hello, trim(" h e l l o") = h e l l o
if(!empty($name)){}

FIX: gamit ka ng trim() function

ltrim() = trim spaces/empty value on left
rtrim() = trim spaces/empty value on right
trim() = trim spaces/empty value both sides


2) HTML tags will be inserted XSS attack

$_POST['"><script>document.write(document.cookie());</script>'];
so "><script>document.write(document.cookie());</script> is valid input

you can add htmlspecialchars()

htmlspecialchars($_POST['"><script>document.write(document.cookie());</script>'])

OUTPUT : "><script>document.write(document.cookie());</script>

3) SQL injection

dangerous when executed

$_POST['' or 1=1; --'];
$_POST['' or 1=1 drop table_users; --']; ' or 1=1 drop table_users; --
$_POST['' or 1=1 drop database ; --'];


str_replace('"', "", $string);
str_replace("'", "", $string);

Otherwise, go for some regex, this will work for html quotes for example:

preg_replace("/<!--.*?-->/", "", $string);
C-style quotes:

preg_replace("/\/\/.*?\n/", "\n", $string);
CSS-style quotes:

preg_replace("/\/*.*?\*\//", "", $string);
bash-style quotes:

preg-replace("/#.*?\n/", "\n", $string);




echo $_POST['lastname']; // O\'hack
echo addslashes($_POST['lastname']); // O\\\'hack



if (get_magic_quotes_gpc()) {
$lastname = stripslashes($_POST['lastname']);
}
else {
$lastname = $_POST['lastname'];
}


mysql_real_escape_string($user),
mysql_real_escape_string($password));



Marami pa....


-> dito kayo mag test online

https://eval.in/877730


Dagdag din sa mga nasabi mas oki kung gamitin na rin ang mysqli(MySQL Improved) o di kaya PDO(PHP Data Objects) upang mas maging secure ang pagcocode gamit ang prepared statements etc. To learn more maraming references online, can start sa http://php.net/manual/en/book.pdo.php at http://php.net/manual/en/book.mysqli.php
 
up para sa mga tropa jan na beginners hahahaha

- - - Updated - - -

up lang ng up para sa inyo talga yan hahaha
 
G lang ng G mga tropa!
para sa inyo yan ;) up lang natin para may makapag download pa. :D
 
up para sa mga tropa nyo. hehehehe naishare ko narin pala to sa facebook. nasa mag spread lalo ngayong darating na sem para sa mga IT/CS
 
pasubok boss newbie on php malaki matutulong nito para sa kinabukasan ko
 
Well done TS. Keep it up . I suggest i upload mo itong gawa mo sa github para maiadd mo din sa credentials mo .
 
:clap::clap: ang galing sir!!! tnx, pero ung Lesson 9 result.php sir ayaw gumana sa akin my error bakit kya ts kinopya ko nmn lahat he5....
 
- - - Updated - - -

- - - Updated - - -

HOW TO FIX XAMPP APACHE ERROR
 

Attachments

  • 1.png
    1.png
    77.4 KB · Views: 29
  • 6.png
    6.png
    98.4 KB · Views: 42
  • 22.png
    22.png
    87.9 KB · Views: 48
  • 16.png
    16.png
    81 KB · Views: 35
  • 21.png
    21.png
    91.1 KB · Views: 33
  • Xamp Error Fix.zip
    2.4 MB · Views: 187
Last edited:
up lang tropa para sa inyo yan e, ginagawa ko na pala yung season 2 nito :) hehehe happy codings
 
hello season 2!


23844834_1730655333620364_1799391507165013908_n.jpg
 
Last edited:
Back
Top Bottom