php-windows Digest 20 Jun 2003 20:27:51 -0000 Issue 1786

Topics (messages 20435 through 20466):

Re: PHP i need help please
        20435 by: Daniel Beulshausen

Re: Help changing code HELP!!!!!!!!!!!!!!!!!
        20436 by: Mark Clarkstone
        20437 by: Luis Moreira
        20439 by: Mark Clarkstone
        20448 by: sven
        20451 by: erythros
        20452 by: erythros

Re: Parse error    what's this, what to do?
        20438 by: sven
        20443 by: Alejandro C. Garrammone
        20444 by: Ildiko Nyari
        20446 by: sven
        20449 by: Cristian MARIN
        20450 by: Ildiko Nyari

Subject: Parse error    what's this, what to do?
        20440 by: Neil Smith

Accessing Excel Using ADO
        20441 by: Herhuth, Ron

Sessiom Problem
        20442 by: Waldemar Brand Neto
        20445 by: Andrei BEJENARU
        20447 by: Cristian MARIN

What is the best way to post here?
        20453 by: Jon Harrell
        20465 by: erythros

Re: [SMARTY] section problem
        20454 by: Carlos Castillo

Fatal error: main(): Failed opening required..... Dreamweaver MX
        20455 by: Ildiko Nyari
        20456 by: Ildiko Nyari
        20458 by: Radovan Radic
        20461 by: Ildiko Nyari
        20463 by: Radovan Radic

Phpinfo.php
        20457 by: Mathias

PHP Standalone Engine?
        20459 by: Galen P. Zink
        20462 by: Manuel Lemos

adodb-PEAR.inc.php   issues
        20460 by: Ildiko Nyari

Session Problem
        20464 by: Waldemar Brand Neto

Access denied for user: '[EMAIL PROTECTED]'. Dreamweaver MX
        20466 by: Ildiko Nyari

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message --- At 03:25 20.06.2003 +0200, Christoph Grottolo wrote:
[EMAIL PROTECTED] (Daniel Beulshausen) wrote:

>mit freundlichen grüßen aus berlin,
>daniel

welcome back to php... and thanks a lot for having implemented network
access on win32.

trying to get buisness rolling again... ( slowly :) )


mit freundlichen grüßen aus berlin,
daniel

/*--
Daniel Beulshausen - [EMAIL PROTECTED]
Using PHP on Windows? http://www.php4win.com



--- End Message ---
--- Begin Message ---
Something about lumer?

"Erythros" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> what are the errors that you get?
>
> "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Hey I need your help I want to change a part of the config.php file in
my
> > script which is
> >
> > $allow = "1"; // to allow comments 1 = yes  0 = no
> >
> > I'm trying to change it to $allow = "0"; using a other file I have this
> code
> > but i get errors
> >
> > <?
> > require("config.php");
> > $changeallow = substr_replace($allow, '0', 0);
> >
> > if ($configallow=="yes") {
> >
> > $data = "$allow = /"0/";";
> > $fp = fopen("config.php",'a');
> > $fw = fwrite($fp,$data);
> > fclose($fp);
> > }
> > ?>
> >
> > If you have another code i could use please help me
out!!!!!!!!!!!!!!!!!!!
> >
> > Thanks
> >
> >
>
>



--- End Message ---
--- Begin Message ---
This is not very clear to me.
First, what errors do you get ?
Second, in one place you have

$changeallow (that you don't use)

and further ahead

$configallow (that is not initializazed)

Which one is the good one ?


Luis

----- Original Message -----
From: "erythros" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, June 19, 2003 3:51 PM
Subject: [PHP-WIN] Re: Help changing code HELP!!!!!!!!!!!!!!!!!


> what are the errors that you get?
>
> "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Hey I need your help I want to change a part of the config.php file in
my
> > script which is
> >
> > $allow = "1"; // to allow comments 1 = yes  0 = no
> >
> > I'm trying to change it to $allow = "0"; using a other file I have this
> code
> > but i get errors
> >
> > <?
> > require("config.php");
> > $changeallow = substr_replace($allow, '0', 0);
> >
> > if ($configallow=="yes") {
> >
> > $data = "$allow = /"0/";";
> > $fp = fopen("config.php",'a');
> > $fw = fwrite($fp,$data);
> > fclose($fp);
> > }
> > ?>
> >
> > If you have another code i could use please help me
out!!!!!!!!!!!!!!!!!!!
> >
> > Thanks
> >
> >
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


--- End Message ---
--- Begin Message ---
this

Parse error: parse error, unexpected T_LNUMBER in
c:\www\apache\htdocs\scripts\string\test.php on line 9

"Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Something about lumer?
>
> "Erythros" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > what are the errors that you get?
> >
> > "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> > > Hey I need your help I want to change a part of the config.php file in
> my
> > > script which is
> > >
> > > $allow = "1"; // to allow comments 1 = yes  0 = no
> > >
> > > I'm trying to change it to $allow = "0"; using a other file I have
this
> > code
> > > but i get errors
> > >
> > > <?
> > > require("config.php");
> > > $changeallow = substr_replace($allow, '0', 0);
> > >
> > > if ($configallow=="yes") {
> > >
> > > $data = "$allow = /"0/";";
> > > $fp = fopen("config.php",'a');
> > > $fw = fwrite($fp,$data);
> > > fclose($fp);
> > > }
> > > ?>
> > >
> > > If you have another code i could use please help me
> out!!!!!!!!!!!!!!!!!!!
> > >
> > > Thanks
> > >
> > >
> >
> >
>
>



--- End Message ---
--- Begin Message ---
what about the escaped doublequotes?
should be \" not /" (backslash, not slash).
ciao SVEN

"Mark Clarkstone" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> this
>
> Parse error: parse error, unexpected T_LNUMBER in
> c:\www\apache\htdocs\scripts\string\test.php on line 9
>
> "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Something about lumer?
> >
> > "Erythros" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> > > what are the errors that you get?
> > >
> > > "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> > > news:[EMAIL PROTECTED]
> > > > Hey I need your help I want to change a part of the config.php file
in
> > my
> > > > script which is
> > > >
> > > > $allow = "1"; // to allow comments 1 = yes  0 = no
> > > >
> > > > I'm trying to change it to $allow = "0"; using a other file I have
> this
> > > code
> > > > but i get errors
> > > >
> > > > <?
> > > > require("config.php");
> > > > $changeallow = substr_replace($allow, '0', 0);
> > > >
> > > > if ($configallow=="yes") {
> > > >
> > > > $data = "$allow = /"0/";";
> > > > $fp = fopen("config.php",'a');
> > > > $fw = fwrite($fp,$data);
> > > > fclose($fp);
> > > > }
> > > > ?>
> > > >
> > > > If you have another code i could use please help me
> > out!!!!!!!!!!!!!!!!!!!
> > > >
> > > > Thanks
> > > >
> > > >
> > >
> > >
> >
> >
>
>



--- End Message ---
--- Begin Message ---
please also include config.php....

"Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hey I need your help I want to change a part of the config.php file in my
> script which is
>
> $allow = "1"; // to allow comments 1 = yes  0 = no
>
> I'm trying to change it to $allow = "0"; using a other file I have this
code
> but i get errors
>
> <?
> require("config.php");
> $changeallow = substr_replace($allow, '0', 0);
>
> if ($configallow=="yes") {
>
> $data = "$allow = /"0/";";
> $fp = fopen("config.php",'a');
> $fw = fwrite($fp,$data);
> fclose($fp);
> }
> ?>
>
> If you have another code i could use please help me out!!!!!!!!!!!!!!!!!!!
>
> Thanks
>
>



--- End Message ---
--- Begin Message ---
i think this has to do with the value you set in $allow. in config.php you
set it to "1" then in test.php you checked for the value "yes".... hence
unexpected number value when it was looking for a char....

"Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> this
>
> Parse error: parse error, unexpected T_LNUMBER in
> c:\www\apache\htdocs\scripts\string\test.php on line 9
>
> "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Something about lumer?
> >
> > "Erythros" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> > > what are the errors that you get?
> > >
> > > "Mark Clarkstone" <[EMAIL PROTECTED]> wrote in message
> > > news:[EMAIL PROTECTED]
> > > > Hey I need your help I want to change a part of the config.php file
in
> > my
> > > > script which is
> > > >
> > > > $allow = "1"; // to allow comments 1 = yes  0 = no
> > > >
> > > > I'm trying to change it to $allow = "0"; using a other file I have
> this
> > > code
> > > > but i get errors
> > > >
> > > > <?
> > > > require("config.php");
> > > > $changeallow = substr_replace($allow, '0', 0);
> > > >
> > > > if ($configallow=="yes") {
> > > >
> > > > $data = "$allow = /"0/";";
> > > > $fp = fopen("config.php",'a');
> > > > $fw = fwrite($fp,$data);
> > > > fclose($fp);
> > > > }
> > > > ?>
> > > >
> > > > If you have another code i could use please help me
> > out!!!!!!!!!!!!!!!!!!!
> > > >
> > > > Thanks
> > > >
> > > >
> > >
> > >
> >
> >
>
>



--- End Message ---
--- Begin Message ---
do you have some code?

"Ildiko Nyari" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
Hello
Parse error: parse error, unexpected '<' in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 129

what's this?
I always get this error when I want to display the php files on the web, so
can't.
What do I do wrong?

thanks,
ildiko



--- End Message ---
--- Begin Message ---
Ildiko, every time you want to use php code you must start with a "<?". For
example, if you want to write some code in php you must do:
<?
[Code]
?>
so, here you want to embeded html code and then you want to write another
part of the code so it's look like this:
<?
[Code]
?>
<HTML>
[Html Code]
</HTML>
<?
[code]
?>

Hope this helps...

But it isn't the answer...please post you code!!!!!!

----- Original Message -----
From: "Ildiko Nyari" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, June 19, 2003 9:43 PM
Subject: [PHP-WIN] Parse error what's this, what to do?


Hello
Parse error: parse error, unexpected '<' in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 129

what's this?
I always get this error when I want to display the php files on the web,
so can't.
What do I do wrong?

thanks,
ildiko


--- End Message ---
--- Begin Message ---
Hello, Thank you
line129:      <td class="TDinfo"><?php require(<select name="select3"
class="SELECTSize">

But the whole stuff look-a-like this:

<td align="right" class="TDinfo"> search by</td>
<td class="TDinfo"><?php require(<select name="select3" class="SELECTSize">
<option selected>new</option>
<option>used</option>
</select>); ?></td>

What I want is the option selected should be an input for the search, that's
what I try to figure out in Dreamweaver MX


THANKS,
ildiko


----- Original Message ----- 
From: "Max Graham" <[EMAIL PROTECTED]>
To: "Ildiko Nyari" <[EMAIL PROTECTED]>
Sent: Thursday, June 19, 2003 11:34 PM
Subject: Re: Parse error what's this, what to do?


> What does your code look like? Can you show us what line 129 looks like in
> advanced3.php?
>
>
> ----- Original Message -----
> From: "Ildiko Nyari" <[EMAIL PROTECTED]>
> Newsgroups: php.windows
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, June 19, 2003 6:43 PM
> Subject: Parse error what's this, what to do?
>
>
> Hello
> Parse error: parse error, unexpected '<' in C:\Program Files\Apache
> Group\Apache2\htdocs\advanced3.php on line 129
>
> what's this?
> I always get this error when I want to display the php files on the web,
so
> can't.
> What do I do wrong?
>
> thanks,
> ildiko
>
>



--- End Message ---
--- Begin Message ---
that codepart isn't very useful.

look around line 129, maybe a line above a command isn't correctly
terminated by semicolon. could be, that your php-termination ?> before
<html> isn't recognized as it is interpreted as depending to stings from
lines above? maybe some brackets of conditions or functions do not
correspond correctly?

do you use an editor with syntax-highlighting? than the problem should be
found soon. if not, send some lines of code before line 129.

ciao SVEN


"Alejandro C. Garrammone" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> Ildiko, every time you want to use php code you must start with a "<?".
For
> example, if you want to write some code in php you must do:
> <?
> [Code]
> ?>
> so, here you want to embeded html code and then you want to write another
> part of the code so it's look like this:
> <?
> [Code]
> ?>
> <HTML>
> [Html Code]
> </HTML>
> <?
> [code]
> ?>
>
> Hope this helps...
>
> But it isn't the answer...please post you code!!!!!!
>
> ----- Original Message -----
> From: "Ildiko Nyari" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, June 19, 2003 9:43 PM
> Subject: [PHP-WIN] Parse error what's this, what to do?
>
>
> Hello
> Parse error: parse error, unexpected '<' in C:\Program Files\Apache
> Group\Apache2\htdocs\advanced3.php on line 129
>
> what's this?
> I always get this error when I want to display the php files on the web,
> so can't.
> What do I do wrong?
>
> thanks,
> ildiko
>



--- End Message ---
--- Begin Message ---
It's very wrong your code:
I don't know what should do but it should look like this:

<td align="right" class="TDinfo"> search by</td>
<td class="TDinfo">
<?php require("file_name_here.php"); ?>
 <select name="select3" class="SELECTSize">
 <option selected>new</option>
 <option>used</option>
 </select></td>

You have mixed the php with the HTML in a very wrong way. You cannot require
a html code, you have to require a file. Please the PHP manual first.

-------------------------------------------------
Cristian MARIN - Developer
InterAKT Online (www.interakt.ro)
Tel:         +4021 312.53.12
Tel/Fax:  +4021 312.51.91
[EMAIL PROTECTED]


"Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hello, Thank you
> line129:      <td class="TDinfo"><?php require(<select name="select3"
> class="SELECTSize">
>
> But the whole stuff look-a-like this:
>
> <td align="right" class="TDinfo"> search by</td>
> <td class="TDinfo"><?php require(<select name="select3"
class="SELECTSize">
> <option selected>new</option>
> <option>used</option>
> </select>); ?></td>
>
> What I want is the option selected should be an input for the search,
that's
> what I try to figure out in Dreamweaver MX
>
>
> THANKS,
> ildiko
>
>
> ----- Original Message ----- 
> From: "Max Graham" <[EMAIL PROTECTED]>
> To: "Ildiko Nyari" <[EMAIL PROTECTED]>
> Sent: Thursday, June 19, 2003 11:34 PM
> Subject: Re: Parse error what's this, what to do?
>
>
> > What does your code look like? Can you show us what line 129 looks like
in
> > advanced3.php?
> >
> >
> > ----- Original Message -----
> > From: "Ildiko Nyari" <[EMAIL PROTECTED]>
> > Newsgroups: php.windows
> > To: <[EMAIL PROTECTED]>
> > Sent: Thursday, June 19, 2003 6:43 PM
> > Subject: Parse error what's this, what to do?
> >
> >
> > Hello
> > Parse error: parse error, unexpected '<' in C:\Program Files\Apache
> > Group\Apache2\htdocs\advanced3.php on line 129
> >
> > what's this?
> > I always get this error when I want to display the php files on the web,
> so
> > can't.
> > What do I do wrong?
> >
> > thanks,
> > ildiko
> >
> >
>
>



--- End Message ---
--- Begin Message ---
THANKS,
I am just a beginner, but you made my life easier. Now I understand it, hope so.
ildiko


"Cristian MARIN" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]
> It's very wrong your code:
> I don't know what should do but it should look like this:
> 
> <td align="right" class="TDinfo"> search by</td>
> <td class="TDinfo">
> <?php require("file_name_here.php"); ?>
>  <select name="select3" class="SELECTSize">
>  <option selected>new</option>
>  <option>used</option>
>  </select></td>
> 
> You have mixed the php with the HTML in a very wrong way. You cannot require
> a html code, you have to require a file. Please the PHP manual first.
> 
> -------------------------------------------------
> Cristian MARIN - Developer
> InterAKT Online (www.interakt.ro)
> Tel:         +4021 312.53.12
> Tel/Fax:  +4021 312.51.91
> [EMAIL PROTECTED]
> 
> 
> "Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Hello, Thank you
> > line129:      <td class="TDinfo"><?php require(<select name="select3"
> > class="SELECTSize">
> >
> > But the whole stuff look-a-like this:
> >
> > <td align="right" class="TDinfo"> search by</td>
> > <td class="TDinfo"><?php require(<select name="select3"
> class="SELECTSize">
> > <option selected>new</option>
> > <option>used</option>
> > </select>); ?></td>
> >
> > What I want is the option selected should be an input for the search,
> that's
> > what I try to figure out in Dreamweaver MX
> >
> >
> > THANKS,
> > ildiko
> >
> >
> > ----- Original Message ----- 
> > From: "Max Graham" <[EMAIL PROTECTED]>
> > To: "Ildiko Nyari" <[EMAIL PROTECTED]>
> > Sent: Thursday, June 19, 2003 11:34 PM
> > Subject: Re: Parse error what's this, what to do?
> >
> >
> > > What does your code look like? Can you show us what line 129 looks like
> in
> > > advanced3.php?
> > >
> > >
> > > ----- Original Message -----
> > > From: "Ildiko Nyari" <[EMAIL PROTECTED]>
> > > Newsgroups: php.windows
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Thursday, June 19, 2003 6:43 PM
> > > Subject: Parse error what's this, what to do?
> > >
> > >
> > > Hello
> > > Parse error: parse error, unexpected '<' in C:\Program Files\Apache
> > > Group\Apache2\htdocs\advanced3.php on line 129
> > >
> > > what's this?
> > > I always get this error when I want to display the php files on the web,
> > so
> > > can't.
> > > What do I do wrong?
> > >
> > > thanks,
> > > ildiko
> > >
> > >
> >
> >
> 
> 
> 
> -- 
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 

--- End Message ---
--- Begin Message --- Dude - do you think we're telepathic or something ? How the hell are we supposed to know what you have written on line 129 ?!?!

Neil.

At 08:09 20/06/2003 +0000, you wrote:
Message-ID: <[EMAIL PROTECTED]>
Reply-To: "Ildiko Nyari" <[EMAIL PROTECTED]>
From: "Ildiko Nyari" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Date: Thu, 19 Jun 2003 20:43:22 -0400
MIME-Version: 1.0
Content-Type: multipart/alternative;
        boundary="----=_NextPart_000_012F_01C336A3.6CA61A20"
Subject: Parse error    what's this, what to do?

Hello
Parse error: parse error, unexpected '<' in C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on line 129


what's this?
I always get this error when I want to display the php files on the web, so can't.
What do I do wrong?


thanks,
ildiko


--- End Message ---
--- Begin Message ---
I'm trying to access an Excel document as a database using ADO.  I've
found several snippets of code on the subject but I'm not having any luck
getting it going.  So far I am using just this fragment of code to connect
but I'm getting an error that I don't know how to correct:

Code:

<?
$conn = new COM("ADODB.Connection");
$dsn = "DRIVER={Microsoft.Jet.OLEDB.4.0}; DBQ=" .
realpath("D:\public\testing\touchContactsWithTatumEmails.xls");
$conn->Open($dsn);
?>


Error:
Warning: Invoke() failed: Exception occurred. Source: Microsoft OLE DB
Provider for ODBC Drivers Description: [Microsoft][ODBC Driver Manager]
Data source name not found and no default driver specified in
D:\public\testing\excelCOM.php on line 10


I'm not sure what I am doing wrong or how to correct it.

If you have any information on this subject or have any ideas, I would be
grateful for your input.



-- Ron Herhuth
-- Senior Developer
-- [EMAIL PROTECTED]



--- End Message ---
--- Begin Message ---
Hy

whwn I tried to use a sessiom this error ocours:

Warning: Cannot send session cookie - headers already sent by

and this:

Warning: Cannot send session cache limiter 


In my php.ini the save path points to a valid directory and php creates a file session.

Thank´s in advance.

Wbn

--- End Message ---
--- Begin Message ---
In your script page are you displaying something *before*
starting the session?

Andrei BEJENARU


"Waldemar Brand Neto" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Hy

whwn I tried to use a sessiom this error ocours:

Warning: Cannot send session cookie - headers already sent by

and this:

Warning: Cannot send session cache limiter


In my php.ini the save path points to a valid directory and php creates a
file session.

Thank´s in advance.

Wbn



--- End Message ---
--- Begin Message ---
This is happening because the session_start() is not the first line in your
page and the others lines beside the session_start are already sending data
or the header informations to the browser so when you are using the
session_start he can't integrate the session cookie to the header so all the
session features are disabled. Try moving the session_start in the bottom of
the source.

It's not the php.ini you have to change is your code.
If the file couldn't be created another warning that the php cannot save
session in /tmp/askldjkj0981312klj1231... on file xxxx.php on line 0 you'll
receive.

"Waldemar Brand Neto" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Hy

whwn I tried to use a sessiom this error ocours:

Warning: Cannot send session cookie - headers already sent by

and this:

Warning: Cannot send session cache limiter


In my php.ini the save path points to a valid directory and php creates a
file session.

Thank´s in advance.

Wbn



--- End Message ---
--- Begin Message ---
It seems that most if not all of my NG posts are
ignored through my news client... but I can email
the list... What is the most effective way of
posting here?


jh



--- End Message ---
--- Begin Message ---
what do you mean ignored? do you mean no one responds to your posts?

"Jon Harrell" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> It seems that most if not all of my NG posts are
> ignored through my news client... but I can email
> the list... What is the most effective way of
> posting here?
>
>
> jh
>
>



--- End Message ---
--- Begin Message ---
well esteban, here is the way ill do that:

 [php]
 $response = array();
 $link = db_connect();
 $result = mysql_query("SELECT * FROM news WHERE news_status LIKE 1
 ORDER BY
 news_date ASC");
 while ($row = mysql_fetch_array($result)) {
    array_push($response,$row);
 }
 $smarty->assign("row", $response);
 $smarty->display("news.tpl");
 [/php]
 
 And your Smarty code
 
 {secion name=news loop=$row}
 Title: {$row[1]}<br>
 Content: $row[2]}<br>
 {/section}

i hope that this can help you!.

Carlos Castillo


-----Original Message-----
From: "Esteban Fernandez" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Date: Fri, 20 Jun 2003 11:42:45 -0400
Subject: [SMARTY] section problem

> Hi there
> 
> I think this is a very basic question, but i'm newbie in Smarty, i hope
> someone can help me. I try list all the content in a table called
> "news",
> this display news of cource in the main page, well that's the main
> idea..
> 
> I have this PHP code:
> 
> [php]
> $link = db_connect();
> $result = mysql_query("SELECT * FROM news WHERE news_status LIKE 1
> ORDER BY
> news_date ASC");
> while ($row = mysql_fetch_array($result)) {
>     $smarty->assign("row", $row);
> }
> 
> $smarty->display("news.tpl");
> [/php]
> 
> And my Smarty code
> 
> {secion name=news loop=$row[0]}
> Title: {$row[1]}<br>
> Content: $row[2]}<br>
> {/section}
> 
> The problem: i have 5 != news in the table, but the Smarty list the
> just the
> last new in 5 times!, how can i resolv this problem ?. Comments and
> suggest
> are welcome.
> 
> Thanks in advanced.
> 
> EF.
> 
> 
> 
> 
> -- 
> Smarty General Mailing List (http://smarty.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php


--- End Message ---
--- Begin Message ---
What is this about? I can connect to mySQL database, but the website in Explorer gives 
me this error.
What do I wrong? in Dreamweaver MX.
thanks

Warning: main(../../Connections/storeunclesam.php): failed to open stream: No such 
file or directory in C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on 
line 1

Fatal error: main(): Failed opening required '../../Connections/storeunclesam.php' 
(include_path='.;c:\php4\pear') in C:\Program Files\Apache 
Group\Apache2\htdocs\advanced3.php on line 1

--- End Message ---
--- Begin Message ---
this is line1:
<?php require_once('../../Connections/storeunclesam.php'); ?>


----- Original Message ----- 
From: "Ildiko Nyari" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, June 20, 2003 12:47 PM
Subject: [PHP-WIN] Fatal error: main(): Failed opening required.....
Dreamweaver MX


What is this about? I can connect to mySQL database, but the website in
Explorer gives me this error.
What do I wrong? in Dreamweaver MX.
thanks

Warning: main(../../Connections/storeunclesam.php): failed to open stream:
No such file or directory in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 1

Fatal error: main(): Failed opening required
'../../Connections/storeunclesam.php' (include_path='.;c:\php4\pear') in
C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on line 1



--- End Message ---
--- Begin Message ---
Maybe you dont have permission to open it. I think using chown could do the
trick. I have user 'www' in apache and if scripts are not owned by 'www' i
get this error like you.
If i am not correct, please someone enlighten me.

PS. My applications work ok on Unix and Linux with this trick, although i am
concerned for security.

"Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
What is this about? I can connect to mySQL database, but the website in
Explorer gives me this error.
What do I wrong? in Dreamweaver MX.
thanks

Warning: main(../../Connections/storeunclesam.php): failed to open stream:
No such file or directory in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 1

Fatal error: main(): Failed opening required
'../../Connections/storeunclesam.php' (include_path='.;c:\php4\pear') in
C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on line 1




--- End Message ---
--- Begin Message ---
Thanks, I have the feeling it is something with the pear, but I always get similar 
errors, and the pear is always there.
What do you think?
ildiko


-------------------------------------------------------------------------------------------------
Maybe you don't have permission to open it. I think using show could do the
trick. I have user 'www' in apache and if scripts are not owned by 'www' i
get this error like you.
If i am not correct, please someone enlighten me.

PS. My applications work ok on Unix and Linux with this trick, although i am
concerned for security.

"Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
What is this about? I can connect to mySQL database, but the website in
Explorer gives me this error.
What do I wrong? in Dreamweaver MX.
thanks

Warning: main(../../Connections/storeunclesam.php): failed to open stream:
No such file or directory in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 1

Fatal error: main(): Failed opening required
'../../Connections/storeunclesam.php' (include_path='.;c:\php4\pear') in
C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on line 1




-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


--- End Message ---
--- Begin Message ---
Must be wrong path, check if it is correct path, calculate all '../' and
find is there such file on that path

"Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Thanks, I have the feeling it is something with the pear, but I always get
similar errors, and the pear is always there.
What do you think?
ildiko


----------------------------------------------------------------------------
---------------------
Maybe you don't have permission to open it. I think using show could do the
trick. I have user 'www' in apache and if scripts are not owned by 'www' i
get this error like you.
If i am not correct, please someone enlighten me.

PS. My applications work ok on Unix and Linux with this trick, although i am
concerned for security.

"Ildiko Nyari" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
What is this about? I can connect to mySQL database, but the website in
Explorer gives me this error.
What do I wrong? in Dreamweaver MX.
thanks

Warning: main(../../Connections/storeunclesam.php): failed to open stream:
No such file or directory in C:\Program Files\Apache
Group\Apache2\htdocs\advanced3.php on line 1

Fatal error: main(): Failed opening required
'../../Connections/storeunclesam.php' (include_path='.;c:\php4\pear') in
C:\Program Files\Apache Group\Apache2\htdocs\advanced3.php on line 1




--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





--- End Message ---
--- Begin Message ---
I use Microsoft Windows XP Pro, and PHP4. Im reading the book Sams teach
yourself PHP, Mysql and Apache.
I setup mysql apache2 and php4. I cannot get <? phpinfo(); ?> to work. Can
anyone HELP PLEASE?!?!???



--- End Message ---
--- Begin Message --- I work for a small networking company. We're working on a piece of software that will be run server-side with PHP and MySQL. It allows the user to develop an online store and handles all the complex shopping cart stuff with ease. It is a port of an originally client-side application. We would like to be able to hand out demo discs that do not require the internet to try it out - having a standalone try-out version is a big source of customers.

Is there any kind of standalone PHP/MySQL engine that could be reasonably installed from a CD and run on most Windows machines? If there was some method to compile the PHP into a binary or otherwise protect it, it would be really good because our company would not be too excited about handing out the near-complete source to our product on all the demo discs. It would be nice if there was support for non-Windows OSes, but Windows is by far the majority in market share and the other OSes could easily just pop into an HTML document that directs them to our online version.

Thanks,

Galen P. Zink


--- End Message ---
--- Begin Message --- Hello,

On 06/20/2003 02:58 PM, Galen P. Zink wrote:
I work for a small networking company. We're working on a piece of software that will be run server-side with PHP and MySQL. It allows the user to develop an online store and handles all the complex shopping cart stuff with ease. It is a port of an originally client-side application. We would like to be able to hand out demo discs that do not require the internet to try it out - having a standalone try-out version is a big source of customers.

Is there any kind of standalone PHP/MySQL engine that could be reasonably installed from a CD and run on most Windows machines? If there was some method to compile the PHP into a binary or otherwise protect it, it would be really good because our company would not be too excited about handing out the near-complete source to our product on all the demo discs. It would be nice if there was support for non-Windows OSes, but Windows is by far the majority in market share and the other OSes could easily just pop into an HTML document that directs them to our online version.

PHP for Windows comes with an installer that also provides the PHP CGI/CLI executable version. You can use that to run PHP applications out of a Web server if you need that.


As for protecting the scripts, you can try Turck, which is multi-purpose extension (cache, optimizer, encoder) that you can use to encode your scripts for free because it is Open Source.

http://www.turcksoft.com/en/e_mmc.htm


--


Regards,
Manuel Lemos

Free ready to use OOP components written in PHP
http://www.phpclasses.org/


--- End Message ---
--- Begin Message ---
Hello,
I heard you wrote the PEAR web codes. 
Can you pls let me know what is the problem with my pear and what to do about.
I always get this type error messages;

Warning: main(PEAR.php): failed to open stream: No such file or directory in 
C:\Program Files\Apache Group\Apache2\htdocs\ADOdb\adodb-pear.inc.php on line 41

Fatal error: main(): Failed opening required 'PEAR.php' 
(include_path='.;c:\php4\pear') in C:\Program Files\Apache 
Group\Apache2\htdocs\ADOdb\adodb-pear.inc.php on line 41


my PHP is the newest: 4.3.2.
THANKS,
ildiko


--- End Message ---
--- Begin Message ---
Thank you guys now it´s working fine.

[]´s Waldemar

--- End Message ---
--- Begin Message ---
Does anybody have a clue about this?
I get this error message:

Warning: mysql_pconnect(): Access denied for user: '[EMAIL PROTECTED]' (Using 
password: NO) in C:\Program Files\Apache 
Group\Apache2\htdocs\www\Connections\storeunclesam.php on line 9
Access denied for user: '[EMAIL PROTECTED]' (Using password: NO)


and line 9 is:

$storeunclesam = mysql_pconnect($hostname_storeunclesam, $username_storeunclesam, 
$password_storeunclesam) or die(mysql_error());
in the Connections file.

Do you have any guess?
thanks.

--- End Message ---

Reply via email to