introduction screenshots faq forum blog modules components download
Please use the search function and/or read the FAQ first.

Go to Topic: PreviousNext
Go to: Message ListNew TopicSearchLog InPrint View

PHP does not interpret



Posted by: Manel
October 29, 2010 10:41AM
I intalled last EasyPhp
Connect MySql + Apache
Don't interpret PHP functions but if i use TXT-DB-API run OK...
Any idea?
Thank's all
Options: ReplyQuote
Posted by: Amour
October 29, 2010 10:47AM
How do you run PHP scripts ? Into your browser with a localhost or 127.0.0.1 url based ?
Options: ReplyQuote
Posted by: Manel
October 29, 2010 11:49AM
In [127.0.0.1]
Options: ReplyQuote
Posted by: Amour
October 29, 2010 11:58AM
File extension is .php ?

Can we see your code ? Maybe do you use short tags ?
Options: ReplyQuote
Posted by: Manel
October 29, 2010 12:06PM
True, the file to read and run is .php
Options: ReplyQuote
Posted by: Manel
October 29, 2010 12:05PM
My first code lines are:

<?
session_start();
require("conf/comun.php");
$idioma = "backoffice";

ProcesarPagina(True);

function Titulo(){
require("includes/bo_parametros.php");
?>
<html>
<head>
<title><?= $bo_NombreProducto ?></title>
//--------------------

I think the problem is that Apache don't LIKE the short sentence "<?"...
Options: ReplyQuote
Posted by: Thierry
October 29, 2010 12:09PM
use <?php tag.
Options: ReplyQuote
Posted by: Amour
October 29, 2010 12:20PM
Short tags as <? are too old, you can use <?php instead
Options: ReplyQuote
Posted by: Manel
October 29, 2010 12:21PM
Ok, i try it
Options: ReplyQuote
Posted by: Manel
October 29, 2010 01:37PM
It's work

1.- Change php.ini short_tag=On
2.- MySQL conection DD.BB requiered PASSWORD ALWAYS

Thank's to Everybody
Options: ReplyQuote
Posted by: Amour
October 29, 2010 02:37PM
It's a very bad idea... and soon or later you should modify your PHP scripts.
Options: ReplyQuote
Posted by: Réjean
November 08, 2010 05:05PM
Bonjour,
Je viens d'installer EasyPHP et le premier exemple proposé qui est sensé faire imprmer la date courante ne fonctionne pas.
Voici le code:
<html>
<head>
<title>Ma première page en PHP</title>
</head>
<body>

Date courante : <?php print (Date("l F d, Y")); ?>
</body>
</html>
Voici le résultat:
Date courante :
C'est comme si le la commande PHP n'était pas reconnue.
Vous pouvez m'aider? Merci!
Options: ReplyQuote
Posted by: Amour
November 08, 2010 09:22PM
Ici j'obtiens :

Date courante : Monday November 08, 2010

Est-ce que votre fichier est bien en ".php" ?
Vous le lisez bien via votre navigateur par l'url "[127.0.0.1"]; ?
Options: ReplyQuote


Go to: Message ListSearchLog In
Your Name: 
Your Email: 
Subject: 
Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.