FORUMS PROFESSIONNELS
WINDEV
,
WEBDEV
et
WINDEV Mobile
Accueil
|
Messages récents
|
Connexion
|
Déconnexion
|
Français
Accueil
→
WEBDEV 2024
→
PHPExecute() always empty result
PHPExecute() always empty result
Débuté par Sebastian Arnold, 10 jan. 2011 14:04 - 1 réponse
Connectez-vous…
Sebastian Arnold
#1
Posté le 10 janvier 2011 - 14:04
Has anyone tried to use the PHPExecute() function in WebDev?
Whatever I try I always get an empty result.
This is my button click code in WebDev:
s
Phpres is
string
IF
fFileExist
(
"phptest.php"
)
s
Phpres
=
PHPExecute
(
"phptest.php"
)
Info
(
"sPhpres: "
+
s
Phpres
)
ELSE
Info
(
"File missing!"
)
END
And these are my unsuccessfull trials with phptest.php:
FUNCTION
phptest
(
)
{
$res
= '
abc
'
;
RETURN
(
$res
)
;
}
{
$res
= '
abc
'
;
RETURN
(
$res
)
;
}
{
$res
= '
abc
'
;
echo $res
;
}
$res
= '
abc
'
;
RETURN
(
$res
)
;
Any help appreciated
TIA
Sebastian
Signaler
0
0
Sebastian Arnold
#2
Posté le 12 janvier 2011 - 19:15
I got help from PCSoft Support:
According to Patrick the PHP-Code should look like this:
<
?
php
echo
"Hello PHP !"
;
?
>
I tried this and it worked ok if I call it from localhost:
s
MyScript is
string
=
"http://localhost/script.php"
s is
string
s
=
PHPExecute
(
s
MyScript
)
Info
(s)
But if I change the script source to a path on one of my servers I get this error message
s
MyScript is
string
=
"http://mydomain.tld/mypath/script.php"
Strange thing is that although the error message says the script can't be found it runs perfectly when I enter the same link in the browser.
If I simply change the path to
s
MyScript is
string
=
"script.php"
I only get an empty result.
Is there anybody out there working with PHP and WebDev?
TIA
Sebastian
Signaler
0
0
→ Revenir à WEBDEV 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (précédentes versions)
Français
English
Español
Portuguesa
Fermer cette fenêtre
Type de recherche
Uniquement les sujets
Tous les messages
Période de recherche
Date indifférente
Moins d'une heure
Moins de 24 heures
Moins d'une semaine
Moins d'un mois
Moins d'un an
Annuler
Aperçu de votre message
Ajouter une image
Importer une image depuis une URL
Envoyer une image depuis un fichier de votre disque
Déposez ici un fichier ou cliquez sur "Parcourir..."
ou
Annuler
0%
WLangage
SQL
XML, HTML
JAVA, Javascript
Texte