Skip to content

PHP codes and news

Open Menu
May 22, 2012

Vérifier si méthode, une fonction ou une classe existe déjà

<?php
/*
bool function_exists (string nom_fonction)
bool method_exists (object objet, string nom_me
user
May 21, 2012

PHP: Créer un formulaire de ‘FeedBack’

<html>

 <head>
  <title>Formulaire de commentaire</title>
 </head>

 <body>

 <form action="feedba
May 20, 2012

Conversion hexadécimale avec la fonction ‘base_convert()’

<html>
<head>
<title> Fonction Mathématique</title>
</head>
<body>
<?php

$hex = 'a1'; // Nombre hex
user
May 19, 2012

Obtenir le type d’une instance ou d’une variable avec ‘gettype( )’

<?php
class Personne {
}


$elem = new Personne(  );
echo gettype($elem);
$x=15;
echo gettype($x);
user
May 18, 2012

Découper le lien d’un fichier

<?php
$nom_complet_rep = '/usr/local/php/php.ini';
$base = basename($nom_complet_rep);
echo $base."
user
May 17, 2012

Traitement d’une structure stockée

<?php
$bdh = dba_open('etudiant.db','c','gdbm') or die($php_errormsg);

if ($exists = dba_exists($_
user
May 16, 2012

Calcul de cosinus de l’arc avec la fonction ‘acos()’

		 <html>
		 <head>
		 <title> Fonction Math 'acos()'</title>
		 </head>
		 <body>
		 <table>
		 <t
user
May 15, 2012

Déplacer un fichier avec la méthode ‘copy()’

<?php
// Fonction pour déplacer un fichier
     function deplacer($source, $dest)
     {
          
user
May 14, 2012

Liste et exemple des Fonctions courante de calcule

<html>
<head>
<title> Fonction Mathématique</title>
</head>
<body>
<?php

/*
Nom            Descript
user
May 13, 2012

Afficher l’identifiant d’une session avec la méthode ‘session_id()’

<?
// Lancer une session
session_start ();

// Afficher l''ID de la session
print "Numéro d'identifi
user

Posts navigation

Older posts
Newer posts

Recent Posts

  • Hello world!
  • PHP Session et Cookies: Exemple d’utilisation de session_start()
  • PHP: Fermer un fichier avec la fonction fclosde()
  • PHP: Vérifier si un élément est un répertoire
  • PHP: Vérifier si un fichier existe sinon le créer

Recent Comments

  1. A WordPress Commenter on Hello world!
© 2025 PHP codes and news
 / Theme: Really Simple / License: GPLv3