Skip to content

Instantly share code, notes, and snippets.

View amin007's full-sized avatar
🏠
Working from home

amin007 amin007

🏠
Working from home
View GitHub Profile
@amin007
amin007 / paparTable.php
Last active May 22, 2022 06:39
cara buat mysqli yang simple sangat
<?php
include 'tatarajah.php';
$search = isset($_GET['search']) ? $_GET['search'] : '';
$rd = "\r\t";
#--------------------------------------------------------------------------------------------------
$conn = mysqli_connect($servername, $dbusername, $dbpassword, $dbname);
// Check connection
if (mysqli_connect_errno())
{
@amin007
amin007 / web-iis.php
Created January 1, 2020 01:07
tukar .htaccess kepada web.config daa
<?php
/*
# https://cbsa.com.br/tools/online-convert-htaccess-to-web-config.aspx
#--------------------------------------------------------------------------------------------------
# dalam apache guna laragon
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
@amin007
amin007 / Sql_Create.php
Last active July 28, 2021 14:44
buat sql create dari php array
<?php
namespace Aplikasi\Kitab;//echo __NAMESPACE__;
class Sql_Create
{
#=================================================================================================
#-------------------------------------------------------------------------------------------------
function __construct() { }
#-------------------------------------------------------------------------------------------------
function fieldsType()
{
@amin007
amin007 / contoh000.html
Last active December 9, 2019 10:45
masalah nak paparkan borang terapung dan data ambil dari fail lain
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Borang Terapung 000</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="description" content="Nama saya Amin, berasal dari muar, johor.">
<meta name="keywords" content="idea kreatif inovatif projek link Dunia Imaginasi Saya">
<meta name="author" content="Amin007 Ledang">
@amin007
amin007 / list_files.php
Created September 10, 2019 08:51
papar fail / list files in php
<?php
#-------------------------------------------------------------------------------------------------------------
/*
$fileList = glob('/*.*');
foreach($fileList as $filename)
{
# Use the is_file function to make sure that it is not a directory.
if(is_file($filename))
{
echo $filename . '<br>';
@amin007
amin007 / login.html
Created July 22, 2019 07:17
Mengayakan borang daftar
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<title>Contoh Borang Login</title>
<link href="https://use.fontawesome.com/releases/v5.4.2/css/all.css" rel="stylesheet" type="text/css">
@amin007
amin007 / showcsv.php
Last active October 8, 2019 02:18
papar csv untuk buat table dan insert semua data
<?php
#---------------------------------------------------------------------------------------------------
function bersih($papar)
{
# lepas lari aksara khas dalam SQL
//$papar = mysql_real_escape_string($papar);
# buang ruang kosong (atau aksara lain) dari mula & akhir
$papar = trim($papar);
return $papar;
@amin007
amin007 / contoh_dropmenu_papar_hilang.php
Created July 1, 2018 16:33
contoh jika klik dropmenu, akan papar textbopx yang berkenaan sahaja
<!--A Design by W3layouts
Author: W3layout
Author URL: http://w3layouts.com
License: Creative Commons Attribution 3.0 Unported
License URL: http://creativecommons.org/licenses/by/3.0/
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
@amin007
amin007 / Fungsi.php
Created April 12, 2018 00:28
baca csv dan buat table sql
<?php
function bukafail($path = 'test.csv', $field = '', $row = 0)
{
$myTable = basename($path, '.csv');
if (($handle = fopen($path, 'r')) !== FALSE)
{
while (($data = fgetcsv($handle, 1000, ',')) !== FALSE)
{
@amin007
amin007 / api_jakim.xml
Last active July 9, 2017 16:14
contoh panggil xml dalam jquery
<rss version="2.0"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
xmlns:admin="http://webns.net/mvcb/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
<title>eSolat JAKIM : Waktu Solat Hari Ini</title>
<link>Batu Pahat, Muar, Segamat, Gemas</link>