Tuesday, 21 February 2023

What is AI- Artificial Intelligence - தமிழில்

Artificial Intelligence :

Artificial intelligence leverages computers and machines to mimic the problem-solving and decision-making capabilities of the human mind.


செயற்கை நுண்ணறிவு மனித மனதின் சிக்கலைத் தீர்க்கும் மற்றும் முடிவெடுக்கும் திறன்களைப் பிரதிபலிக்கும் வகையில் கணினிகள் மற்றும் இயந்திரங்களைப் பயன்படுத்துகிறது.

தகவல் தொழிநுட்ப துறையில் தற்போது கண்டுபிடிப்புகளில் முன்னணியில் உள்ளது இந்த ஆர்டிபிசியல் இன்டெலிஜென்ஸ் தான் (Artificial Intelligence) .  ஆர்டிபிசியல் இன்டெலிஜென்ஸ் என்பது தானாக எந்த ஒரு முடிவும் எடுக்காது.

ஆர்டிபிசியல் இன்டெலிஜென்ஸ் தரக்கூடிய தரவுகளின் அடிப்படையில் முடிவுகளை எடுக்கும் வல்லமை கொண்டது.  இன்னும் கூற வேண்டுமானால் தன்னிடம் உள்ள தரவுகள் (DATA) மற்றும் அனுபவங்களை (EXPERINCE) வைத்து ஒரு இயந்திரம் ஒரு முடிவு எடுக்கும் செயற்பாடு தான் ஆர்டிபிசியல் இன்டெலிஜென்ஸ் ஆகும். 

செயற்கை நுண்ணறிவு (AI) இயந்திரங்கள் அனுபவத்திலிருந்து கற்றுக்கொள்வதையும், புதிய உள்ளீடுகளுக்கு ஏற்ப மாற்றுவதையும், மனிதனைப் போன்ற பணிகளைச் செய்வதையும் சாத்தியமாக்குகிறது. 

AI எடுத்துக்காட்டுகள் :

இன்று நீங்கள் கேள்விப்படும் பெரும்பாலான AI எடுத்துக்காட்டுகள் - 

சதுரங்கம் விளையாடும் கணினிகள் முதல் 

சுய-ஓட்டுநர் கார்கள் வரை 

குரல் பதிவை பெற்று, அதற்கு பதில் அளிக்கக்கூடிய,

ஆழமான கற்றல் மற்றும் இயல்பான மொழி செயலாக்கத்தை பெரிதும் நம்பியுள்ளன.

TOP  ARTIFICIAL INTELLIGENCE APPS EXAMPLE : 



Thursday, 7 July 2022

Automatic Schedule a Task in PHP

 AUTOMATIC SCHEDULE A TASK IN PHP

AUTOMATIC EXECUTION CODE

1. Cron Jobs

2.Schedule a Task

What is Schedule a Task?

In case to set time, automatically execute any script or logic then we can define "Schedule". That script can execute particular date, week, month, hours, daily etc. In PHP in easy way to do Schedule task. so many methods in command line arguments code.

In PHP, Webserver have Schedule task section






Add Task

Have three option 

    Run Command
    Fetch URL
    Run a PHP Script

 httpdoc/crontask.php


If you need PHP script execute automatically, then specify / Browse the PHP file 

Ex: httpdoc/crontask.php

<?php
$st=date("Y-m-d");
include("config.php");
$q="insert into crontask values('','$st')";
$r=mysqli_query($con,$q);
?>

Select Cron Style : */1 * * * *

It means  Each 1 mins script run automattically.

use the UNIX crontab format "min hour day-of-month month-of-week" 

for example 0 22 ** 1-5.

Webserver Plesk use the default system timezome to run the task.


NOTE : 

In case timezone not working in your server, Configure the PHP.INI file, set timezone settings.

What of need your automatic schedule task and command set after apply the settings

Finally Run the Task

Thats all.. Your code automatically working when your server on/off anytime, that code was working automatically.





Wednesday, 6 July 2022

URL bar color change in html -Simple Method

HOW TO CHANGE BROWSER THEME-COLOR / URL / ADDRESS BAR COLOR CHANGE

URL BAR COLOR CHANGE IN HTML

In HTML page URL/ADDRESS BAR section to change color or theme,

In this post, we will know how to change URL/Address bar theme color change in HTML document. If you designing dark theme based web document, but URL section only displayed white. We feel that section should same theme then good. Its very simple and easy method, Just add theme-color in Meta-tags attribute. 

META-TAG

the <meta> tag is used to inside the <head> tag. 

It defines meta-data about the HTML document.

HOW TO USE

<meta> tag used two attributes

name  attribute = name of the theme attribute - theme-color

content attribute = color of theme - Hexadecimal value

SYNTAX & EXAMPLE

<meta name="theme-color" content="#1bb566">

FULL CODE

<!DOCTYPE html>

<html>

  <head>

    <title>Easy Making Web Apps</title>

    <meta name="theme-color" content="#1bb566">

 </head>

  <body>

    <h1>Welcome To Easy Making Web Apps</h1>

</body>

  </html>


Easy convert two digit decimal points in PHP with Source Code

CONVERT TWO DIGIT DECIMAL POINTS IN PHP 

Hi friends & Students

In this post we see, how to convert two digit decimal points in PHP detailed

Ex:

20.0 = 20.00

1450.5 = 1450.00

PHP CODE

$variable="20.5"; // 20.50

$variable="1450.5"; //1450.50

Like this kind of needs, Use number_format() methods, very easy varibalename,number of digits. 

Ex:

number_format($variable, 2);

PHP EXAMPLE CODE :

<?php

$price="20.5";

$res=number_format($price, 2);

echo "Rs.".$res;

?>

OUTPUT

Rs.20.50

Monday, 16 August 2021

PHP Script date Difference Example with Source code

PHP Script for Date Difference :

    PHP Date function are used to get current date and time.

            $today=date("Y-m-d");

            echo $today;


You can result 2021-08-16 


Update soon.....

Thursday, 28 June 2018

PHP File uploads example with Source Code

Easy File Uploads in PHP Application.

There are some simple steps, you can done file upload in PHP applications

Step 1 : 

Create your Form, Additionally add attributes in form element.

Step 2: 

When your form submits, action page will be redirected, that page received all form values

 receive normal form values as usual format $var=$_POST["formcontrolname"]; metods
Note 1:

This section Using ,PHP File uplaods, have there are 4 methods
$_FILE["file"]["name"]               // This is choosing filename
$_FILE["file"]["type"]                 // This file type, png,pdf,doc,jpg
$_FILE["file"]["size"]                 // this is file size , Its take KB, you can convert MB format
$_FILE["file"]["tmp_name"]       // This is temp file,

Note 2:

If you restricted, allow some format files only uploaded in server, you can check if condition file type is JPG then upload files,

if you restricted, allow some limit size files only uploaded in server, you can check  if condition file size is "1000KB" then upload files,

if your not check, that is any kind of files uploaded then , need not to check any conditions

Step 3:

Next create uploading file to save some directory or folder, that folder create in your root directory, and assign target file path with uploading filename,

$uploadfildir="../products/".$_FILE["file"]["name"];
$target_file = $uploadfildir;

Step 4:

Finally you can store values in database, write connection and query methods, if query executes, then file is uploaded in your server

use move_uploaded_file() method,

Step 5

Finish,



Source Code

The above steps are using below examples, you can copy paste run your server,

Create products folder in root directory in your server,

Create products table in mysql, 

then create forms,

product.php

<form role="form" method="post" action="product_add.php" enctype="multipart/form-data">
   Category Name  <input type="text" name="categoryname"  placeholder="Enter Category Name">
   Product Name<input type="text" name="productname"  placeholder="Enter Product Name">
   Product Picture<input type="file" name="file"   placeholder="Choose file Name">
    <input type="submit" name="submit" value="ADD PRODUCT" class="btn btn-default"/>    
</form>


in action page, receive all form values, and store mysql table, and file uploaded in products folder,

product-save.php


<?php
$categoryname=$_POST["categoryname"];
$productname=$_POST["productname"];
$pic="JS-".$productname."-".$_FILES["file"]["name"];
$uploadfildir="../products/".$pic;
$target_file = $uploadfildir;
include("config.php");
 $insertsql="insert into products values('','$categoryname','$productname','$productpic')";
 $insertsqlres=mysqli_query($con,$insertsql);
 if($insertsqlres)
{
    if (move_uploaded_file($_FILES["file"]["tmp_name"], $target_file))
   {
echo "The file ". basename( $_FILES["file"]["name"]). " has been uploaded.";
   }
}
else
{
echo "Products not added!";
}
?>


Monday, 25 June 2018

PHP- How to convert PHP application to exe (Windows Application)

Hi Dear friends

Many more websites and blogs and forums to check more option for PHP application is convert into desktop application..That time we have more doubts and more questions comes out in mind.. 

A most peoples strongly challenged "PHP to EXE Conversion is Possible ot Not?" 

A Result is "Not"

Its most peoples sharing as for reason is, PHP is scripting language, to make web based application,  Not a desktop application.

But We can use PHP application both Desktop and Web Based 


Here am explained PHP Application is used to Desktop mode, in following steps

Step 1 :

Create your PHP application, and Testing your Xampp server,

Step 2 :

To Set Xampp server is Automatic Running Mode, Bcoz when your system starts, server also started,

Step 3

Copy Paste Google Chrome browser in your desktop,

Next right click, icon properties, and open properties window, in target section in end of line,




to set --app=http://localhost/yourPHPprojectname/

After to change icon, 

Step 4:

Finally you click that icon,your PHP application working in EXE format, Its look like window application, No URLS, Address section, etc


Thank you.. we will see another important topics



PHP- Step by Step To Store and Retrieve Tamil Fonts in PHP and MySQL?

PHP- How to Store and Retrieve Tamil Fonts in PHP and MySQL?


In this post explained for how to store and retrieved tamil fonts in PHP and MySQL database.  here explain step by step

Previous post explained how to display tamil fonts in webpage in detailed.. that way first design in form in your webpage

Step 1: Design form in your (HTML ) Webpage


Step 2 :   Below code copy and save customers.php



<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
</head>
<body>
<h2>Add New Customers</h2>
  <form name="customer" method="post" action="customers-add.php">
        <table>
         <tr><td>பெயர் </td><td><input type="text" name="cname" required /></td></tr>
        <tr><td>தொழில் </td><td><input type="text" name="occupation" required/></td></tr>
        <tr><td>விலாசம் </td><td><input type="text" name="address" required/></td></tr>
         <tr><td>ஊர் பெயர்  </td><td><input type="text" name="city" required/></td></tr>
        <tr><td>கைபேசி எண்  </td><td><input type="text" name="mobile" required/></td></tr>
        
        <tr><td></td><td><input type="submit" name="submit" value="SAVE CUSTOMER" /></td></tr>
        </table>
        </form>
</body>
</html>






Step 3 : 

Create Table in MySQL Database, just fieldname, length, additional SET as collation is
utf8_general_ci





Step 3 : 

Tables created successfully then go to coding action page


Step 4: 

Action page customers-add.php

<?php       
                 $cname=$_POST["cname"];
$occupation=$_POST["occupation"];
$address=$_POST["address"];
$city=$_POST["city"];
$address1=$address.",".$city;
$mobile=$_POST["mobile"];
$cusid=$branchcode."-$cname";

include("config1.php");
$q="insert into customers values('','$cname','$occupation','$address1','$mobile')";
$r=mysqli_query($link,$q);
if($r)
{
echo "<h3>கஸ்டமர் தகவல் பதிவு செய்யப்பட்டது !</h3>";
}
else
{
echo "<h3>கஸ்டமர் தகவல் பதிவு செய்ய முடியவில்லை  ! மன்னிக்கவும் </h3>";

}

?>



இந்த பதிவு பயன் உள்ளதாக இருக்கும் என நம்புகிறேன் ! நன்றி 



Sunday, 24 June 2018

PHP-How to Display Tamil Fonts in HTML Page?

How to Display Tamil Fonts in HTML Page?


Hi friends, this post for Tamil peoples,  

In normall html does not allow tamil fonts in webpage,  

So our tamil fonts displayed in webpage, just we set meta tag in UTF-8,

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
</head>
<body>
<h1>நண்பர்களுக்கு வணக்கம் </h1>
</body>
</html>



தமிழில் எழுதுங்கள் உங்கள் வலைப்பக்கத்தை  நன்றி !!!!!

PHP- How to find Due dates in PHP and MySQL?

Hi Dear friends,
In This post we see, how to find next due date in easily.

PHP- How to find next due dates in PHP and MySQL?


for example, Finance Management application need to calculated next number due dates, 
Just analysis, what we do?
Step 1: Just given date to add number of days then we get next due date,

for example, 20/06/2018 is given date, 30 days after next First due date then just 30 Days, add next 60 days then we get second due date etc,

In additionally,

Given Loan Date : 20/06/2018
I Due Date : 20/07/2018
II Due Date : 20/08/2018
II Due Date : 20/09/2018

The above example, solved below code, Its very simple logic and easily use to your application.

Loan Date is Current Date then you can use below code


$loandate=date("d/m/Y");

else

You are using HTML5 Date control, then control return default format, so we convert to needed format in below format,

$timestamp = strtotime($loandate);
$lldate = date("d/m/Y", $timestamp);

$duedateinterval=30; // Assign how many date intervals. 1 month then 30, 1 week then 7

$nm=0;
for($i=1;$i<=5;$i++)
{
$nm=$nm+$duedateinterval;
echo $i."Due Date is=".date('d/m/Y', strtotime("+$nm days"));
}


Enjoy! Use code.. If any doubts comments here


PHP- DataAdd methods in PHP?

How to Add to dates in PHP?

Simply example here explain, how to add two dates.

Just assign two dates in two variables

Manual Method

$d1="26/06/2018";
$d2="28/06/2018";
$sec=$d1-$d2; //Its returns in seconds, 
// To convert in Days
$days = $secs / 86400;
echo $days;


Result /Output is

-2 days

Find date difference between given to current date

Runtime Method

$inputdate=$_POST["gdate"]; // Its comes from form, i.e its the given input date
$d1=strtotime($loandate);    // Format to the date
$d2=strtotime(date("Y-m-d")); // Its Current date
$secs = $d1 - $d2;// == return sec in difference
$days = $secs / 86400
echo $days;


Thanks,

Next post we see another issues in PHP







What is AI- Artificial Intelligence - தமிழில்

Artificial Intelligence : Artificial intelligence leverages computers and machines to mimic the problem-solving and decision-making capabili...