GRUPOS DE DISCUSSÃO PROFISSIONAL
WINDEV
,
WEBDEV
e
WINDEV Mobile
Inicio
|
Mensagens recentes
|
Conecte-se...
|
Disconnect
|
Português
Inicio
→
WEBDEV 2024
→
PHPExecute() always empty result
PHPExecute() always empty result
Iniciado por Sebastian Arnold, jan., 10 2011 2:04 PM - 1 resposta
Conecte-se…
Sebastian Arnold
#1
Publicado em janeiro, 10 2011 - 2:04 PM
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
Denunciar
0
0
Sebastian Arnold
#2
Publicado em janeiro, 12 2011 - 7:15 PM
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
Denunciar
0
0
→ Voltar para WEBDEV 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (versões anteriores)
Français
English
Español
Portuguesa
Fermer cette fenêtre
Tipo de Pesquisa
Apenas tópicos
Todas as mensagens
Período de pesquisa
Qualquer momento
Última hora
Últimas 24 horas
Semana passada
Mês passado
Ano passado
Cancelar
Pré-visualização da sua mensagem
Adicionar imagem
Importar uma imagem de uma URL
Enviar uma imagem a partir do seu disco
Deixe um ficheiro ou clique em "Procurar ..."
ou
Cancelar
0%
WLanguage
SQL
XML, HTML
JAVA, Javascript
Texto