 |
$modox = "1"; // 0 - local 1 - Internet
if($modox == "0"){ // local
$sqlhostname = "localhost";
$xlogin = "root";
$password = "";
$base = "db_dra";
}else{ // Internet
$sqlhostname = "localhost";
$xlogin = "supimpa_shirley";
$password = "pontaweb2017";
$base = "supimpa_shirley";
}
/*
if($modox == "0"){ // local
$sqlhostname = "localhost";
$xlogin = "root";
$password = "";
$base = "db_dra";
}else{ // Internet
$sqlhostname = "200.185.44.4";
$xlogin = "drashirley28235";
$password = "gkf90gkv";
$base = "drashirleydecampos";
}
*/
$db_connect = mysql_connect($sqlhostname,$xlogin,$password);
$base_selection = mysql_select_db($base,$db_connect);
$objCategorias_ActiveConnection=$db_connect;
//*******************Caminho no Webserver**************************
//strCaminho = "G:\inetpub\domain\drashirleydecampos.com.br\db\ckless.mdb" 'Diretrio e nome do Banco
//strCaminho_Fotos = "g:\inetpub\domain\drashirleydecampos.com.br\www\adm\fotos_news\" 'Diretrio de fotos
//strWeb_Fotos = "/adm/fotos_news/" 'Diretrio de fotos para exibi?o(Pblico)
$strCaminho="g:\Inetpub\Domains\DRASHIRLEYDECAMPOS.COM.BR\www\db\ckless.mdb"; //Diretrio e nome do Banco
$strCaminho_Fotos="g:\Inetpub\Domains\DRASHIRLEYDECAMPOS.COM.BR\www\adm\fotos_news\ "; //Diretrio de fotos
$strWeb_Fotos="/adm/fotos_news/";//Diretrio de fotos para exibi?o(Pblico)
//*******************String de Conex?*****************************
// $objConexao is of type "ADODB.Connection"
//strConexao = "Driver={Microsoft Access Driver (*.mdb)};DBQ=" & strCaminho
//strConexao = "Provider=Microsoft.JET.OLEDB.4.0; Data Source=" & strCaminho
//StrConexao = "driver={MySQL ODBC 3.51 driver};server=200.185.44.4;uid=drashirley28235;pwd=gkf90gkv;database=drashirleydecampos"
//$StrConexao="driver={MySQL ODBC 3.51 driver};server=200.185.44.4 ; uid=drashirley28235;pwd=gkf90gkv;database=drashirleydecampos";
//objConexao.ConnectionString = "teste_drshirley"
$a2p_connstr=$StrConexao ;
$a2p_uid=strstr($a2p_connstr,'uid');
$a2p_uid=substr($d,strpos($d,'=')+1,strpos($d,';')-strpos($d,'=')-1);
$a2p_pwd=strstr($a2p_connstr,'pwd');
$a2p_pwd=substr($d,strpos($d,'=')+1,strpos($d,';')-strpos($d,'=')-1);
//$objConexao=mysql_connect("localhost",$a2p_uid,$a2p_pwd);
//mysql_select_db("",$objConexao);
//Fun?o para Capitalizar(Coloca a primeira letra em maiscula e o resto em minsculas)
/*function Capitalize22($Texto)
{
extract($GLOBALS);
if (strlen($Texto)>1)
{
$Texto=strtoupper(substr($Texto,0,1)).strtolower(substr($Texto,strlen($Texto)-(strlen($Texto)-1)));
}
else
{
$Texto=strtoupper($Texto);
}
$function_ret=$Texto;
return $function_ret;
}
*/
//Fun?o para localizar o nome de arquivo de uma URL com barras normais -> /
/*function NomeArquivo($EndURL)
{
extract($GLOBALS);
$function_ret=substr($EndURL,strlen($EndURL)-(strlen($EndURL)-(strrpos($EndURL,"/") ? strrpos($EndURL,"/")+1 : 0)));
return $function_ret;
}
*/
############
//Fun?o para formatar aspas simples
/*function SQLEncode($Texto)
{
extract($GLOBALS);
$function_ret=str_replace("'","''",$Texto);
return $function_ret;
}
*/
########
//Forma?o da Data
$strDia=strftime("%d");
$strMes=strftime("%m");
$strAno=strftime("%Y");
if (strlen($strDia)==1)
{
$strDia="0".$strDia;
}
if (strlen($strMes)==1)
{
$strMes="0".$strMes;
}
//Forma?o da Hora
$strHora=strftime("%H");
$strMinuto=strftime("%M");
if (strlen($strHora)==1)
{
$strHora="0".$strHora;
}
if (strlen($strMinuto)==1)
{
$strMinuto="0".$strMinuto;
}
$strData=$strDia."/".$strMes."/".$strAno;
$strHoraAtual=$strHora.":".$strMinuto;
$strDataInserir=strftime("%m/%d/%Y %H:%M:%S %p");
/*function Codificar($variavel)
{
extract($GLOBALS);
if ($variavel!="")
{
$variavel=str_replace(chr(10)," ",$variavel);
$variavel=str_replace("\"",""",$variavel);
$variavel=str_replace("'","'",$variavel);
$variavel=str_replace(",",",",$variavel);
$variavel=str_replace("'","'",$variavel);
$variavel=str_replace("-","-",$variavel);
$variavel=str_replace("`","`",$variavel);
$function_ret=$variavel;
}
else
{
$function_ret=$variavel;
}
return $function_ret;
}
*/
?>
 |
|
$SQL="Select CategoriaID, CategoriaDesc From Categorias order by CategoriaDesc";
// $objCategorias is of type "ADODB.RecordSet"
//mysql_query($objCategorias_CommandText,$objCategorias_ActiveConnection);$objConexao
$resultado=mysql_query($SQL,$objCategorias_ActiveConnection);
while($objCategorias=mysql_fetch_array($resultado))
{
?>
|
//$objCategorias=mysql_fetch_array($objCategorias_query);
}
//$objCategorias=null;
?>
|
|
 |
|
|
|
|
|
|
print $strassunto;?>
print $objRS["Titulo"];?>
|
echo $minha_data; ?>
|
if (strtoupper($objRS["Imagem"])!="NAO" && $objRS["Imagem"]!="")
{
?>
|
print " ";
?> |
} ?>
$txtConteudo = $objRS["Noticia"];
print $txtConteudo;
?>
IMPORTANTE
- Procure o seu médico para diagnosticar doenças, indicar tratamentos e receitar remédios.
- As informações disponíveis no site da Dra. Shirley de Campos possuem apenas caráter educativo.
|
Publicado
por:
print $objRS["InseridaPor"];?>
|
|
versão
para impressão
|
|
|
 |