RE: [fw-general] Broken after upgrade to Apache 2.2

2008-03-14 Thread Eric Marden
 
The first one is supposed to be AllowOverride none.

Only the second should be loosened.

This is fine in dev or on your local, but don't do that on Production.

 
--
Eric Marden
Sr. PHP Developer


-Original Message-
From: Chuck Bai [mailto:[EMAIL PROTECTED] 
Sent: Friday, March 14, 2008 5:44 PM
To: Bryan Dunlap
Cc: fw-general@lists.zend.com
Subject: Re: [fw-general] Broken after upgrade to Apache 2.2

It is working now. There are two places to set AllowOverride in
httpd.conf. I set only one. My app is working fine with Apache 2.2 now. 
Thanks for pointing out the right direction.

Bryan Dunlap wrote:
>  Original Message 
> Subject: Re: [fw-general] Broken after upgrade to Apache 2.2
> From: Chuck Bai <[EMAIL PROTECTED]>
> Date: Thu, March 13, 2008 10:01 am
> To: Isaak Malik <[EMAIL PROTECTED]>, fw-general@lists.zend.com
>
>   
>> When I am trying to access login page: 
>> http://localhost/my-app/auth/login (where AuthController/loginAction)

>> I got this Apache error log:
>> [time] [error] [client 127.0.0.1] File does not exist: 
>> C:/doc-root/my-app/auth, referer: http://localhost/my-app/
>> 
>
>   
>> I have another PHP application not using ZF. It is working fine. So 
>> the web server is not a problem. Seems the problem is due to ZF MVC, 
>> which is not functional after the upgrade. It could not find the 
>> controller and do the action I requested. It is working fine with 
>> Apache 2.0 and I did not have any code change after the upgrade.
>> 
>
>
> What you're describing screams mod_rewrite problem to me.
>
> How are you utilizing mod_rewrite for your ZF application? Using 
> .htaccess file(s) or directly within an apache virtual host
definition?
> If using .htaccess, did you verify that AllowOverride was configured 
> properly after your upgrade?
>
> You say you verified that mod_rewrite was loaded. Did you verify that 
> it was working properly? Try enabling rewrite logging and make sure 
> that you're even engaging the rewrite engine when you make your
requests.
>
> I develop against ZF every day, using some combination of both PHP 
> 5.2.x and Apache 2.0.x/2.2.x. I'm certain your problem is related to 
> some change in your web server environment (specifically mod_rewrite 
> related) and not a problem with the ZF itself.
>
>
> Thanks,
> -B
>
>
>
>   



[fw-general] ZF 1.5- all systems go!

2008-03-14 Thread Wil Sinclair
Hi all- it has been an exhausting week to say the least. As you may have
suspected from our relative silence on the list in the past few days, we
Zenders have been busily preparing for the 1.5 launch. And I'm very
happy to say the countdown has begun!
If all goes well, Zend Framework 1.5 will be landing on Monday 3/17. You
should be able to read all about it on your favorite (PHP) blog soon:
http://www.technorati.com/search/zend+framework. And don't forget to
blog about ZF 1.5 yourself- we've all earned a little horn tooting.
But for now *I* have to get back to work. Don't forget to swing by the
site on Monday for the official announcement and a few surprises.

Thanks- and have a great weekend!
,Wil


Re: [fw-general] Broken after upgrade to Apache 2.2

2008-03-14 Thread Chuck Bai
It is working now. There are two places to set AllowOverride in 
httpd.conf. I set only one. My app is working fine with Apache 2.2 now. 
Thanks for pointing out the right direction.


Bryan Dunlap wrote:

 Original Message 
Subject: Re: [fw-general] Broken after upgrade to Apache 2.2
From: Chuck Bai <[EMAIL PROTECTED]>
Date: Thu, March 13, 2008 10:01 am
To: Isaak Malik <[EMAIL PROTECTED]>, fw-general@lists.zend.com

  
When I am trying to access login page: 
http://localhost/my-app/auth/login (where AuthController/loginAction)

I got this Apache error log:
[time] [error] [client 127.0.0.1] File does not exist: 
C:/doc-root/my-app/auth, referer: http://localhost/my-app/



  
I have another PHP application not using ZF. It is working fine. So the 
web server is not a problem. Seems the problem is due to ZF MVC, which 
is not functional after the upgrade. It could not find the controller 
and do the action I requested. It is working fine with Apache 2.0 and I 
did not have any code change after the upgrade.




What you're describing screams mod_rewrite problem to me.

How are you utilizing mod_rewrite for your ZF application? Using
.htaccess file(s) or directly within an apache virtual host definition?
If using .htaccess, did you verify that AllowOverride was configured
properly after your upgrade?

You say you verified that mod_rewrite was loaded. Did you verify that it
was working properly? Try enabling rewrite logging and make sure that
you're even engaging the rewrite engine when you make your requests.

I develop against ZF every day, using some combination of both PHP 5.2.x
and Apache 2.0.x/2.2.x. I'm certain your problem is related to some
change in your web server environment (specifically mod_rewrite related)
and not a problem with the ZF itself.


Thanks,
-B



  




Re: [fw-general] Zend_PDF and Barcode

2008-03-14 Thread Willie Alberty

On Mar 14, 2008, at 5:11 AM, billyildirim wrote:

I am pretty sure it is possible to put Barcode in PDF file using  
Zend_Pdf

but I couldn't find any information about that.
Can someone show me any tutorial about it?



Barcode generation in Zend_Pdf is a planned feature, but is not  
implemented yet. You can watch this issue for progress updates:


http://framework.zend.com/issues/browse/ZF-1712

However, as Troels mentioned, if your needs are simple, there are  
several free or low-cost TrueType barcode fonts available online.


--

Willie Alberty, Owner
Spenlen Media
[EMAIL PROTECTED]

http://www.spenlen.com/



[fw-general] Problem with CookieJar

2008-03-14 Thread David Koblas
Just to point this out, but the Zend_Http_Cookie assumes that values are 
urlencoded.  This means that when using this class with services that 
are 'good' about encoding you cannot roundtrip a cookie via ..._Cookie 
and _CookieJar.


It makes some sense to urlencode() cookies if they are being set via 
->setCookie() in a client application, however if they're comming back 
via a client request and stuffed into a cookie jar the assumption of 
encoding is incorrect.


--koblas


RE: [fw-general] 'The mysql driver is not currently installed'

2008-03-14 Thread Eric Marden
What's your O/S?

I know when I've seen this before its due to a couple things, so try
these:

* Ensure that your extension_dir path in PHP.ini is set correctly.
* If on windows, sometimes it can't find the libmysql.dll file. This can
usually be found in either your MySQL dir or even in your PHP dir. I've
found that sometimes you have to drop it in to c:\windows\system32 for
it to work.

See if this helps


 
--
Eric Marden
Sr. PHP Developer


-Original Message-
From: debussy007 [mailto:[EMAIL PROTECTED] 
Sent: Thursday, March 13, 2008 11:41 PM
To: fw-general@lists.zend.com
Subject: [fw-general] 'The mysql driver is not currently installed'


Hi,

Whenever I try to execute a Db query, I have the following error :
Fatal error: Uncaught exception 'Zend_Db_Adapter_Exception' with message
'The mysql driver is not currently installed'

I have installed Php with the extension MySQL, PDO, PDO_MySQL, ...
Here are all my extensions:

[PHP_GD2]
extension=php_gd2.dll
[PHP_GETTEXT]
extension=php_gettext.dll
[PHP_MBSTRING]
extension=php_mbstring.dll
[PHP_MYSQL]
extension=php_mysql.dll
[PHP_PDO]
extension=php_pdo.dll
[PHP_PDO_MYSQL]
extension=php_pdo_mysql.dll
[PHP_PHPDOC]
extension=php_phpdoc.dll

I tried to restart the server, but the message will still appear... I'm
clueless, can anyone help ?

Thank you.
--
View this message in context:
http://www.nabble.com/%27The-mysql-driver-is-not-currently-installed%27-
tp16043858s16154p16043858.html
Sent from the Zend Framework mailing list archive at Nabble.com.



Re: [fw-general] Broken after upgrade to Apache 2.2

2008-03-14 Thread Chuck Bai
I used .htaccess and I verified that 'AllowOverride All' has been set in 
httpd.conf. The mod_rewrite is loaded as confirmed with phpinfo. here is 
my .htaccess for the root folder:

**
RewriteEngine on
RewriteRule .* index.php
php_flag magic_quotes_gpc off
php_flag register_globals off
**
Othe folders has "deny from all" set in .htaccess.

I agree this is probably a mod_rewrite setup problem, but I don't know 
where is wrong. Thanks.


Bryan Dunlap wrote:

 Original Message 
Subject: Re: [fw-general] Broken after upgrade to Apache 2.2
From: Chuck Bai <[EMAIL PROTECTED]>
Date: Thu, March 13, 2008 10:01 am
To: Isaak Malik <[EMAIL PROTECTED]>, fw-general@lists.zend.com

  
When I am trying to access login page: 
http://localhost/my-app/auth/login (where AuthController/loginAction)

I got this Apache error log:
[time] [error] [client 127.0.0.1] File does not exist: 
C:/doc-root/my-app/auth, referer: http://localhost/my-app/



  
I have another PHP application not using ZF. It is working fine. So the 
web server is not a problem. Seems the problem is due to ZF MVC, which 
is not functional after the upgrade. It could not find the controller 
and do the action I requested. It is working fine with Apache 2.0 and I 
did not have any code change after the upgrade.




What you're describing screams mod_rewrite problem to me.

How are you utilizing mod_rewrite for your ZF application? Using
.htaccess file(s) or directly within an apache virtual host definition?
If using .htaccess, did you verify that AllowOverride was configured
properly after your upgrade?

You say you verified that mod_rewrite was loaded. Did you verify that it
was working properly? Try enabling rewrite logging and make sure that
you're even engaging the rewrite engine when you make your requests.

I develop against ZF every day, using some combination of both PHP 5.2.x
and Apache 2.0.x/2.2.x. I'm certain your problem is related to some
change in your web server environment (specifically mod_rewrite related)
and not a problem with the ZF itself.


Thanks,
-B



  




Re: [fw-general] Zend_PDF and Barcode

2008-03-14 Thread Isaak Malik
>
> Isaak Malik wrote: On Fri, Mar 14, 2008 at 1:11 PM, billyildirim <
> [EMAIL PROTECTED]> wrote:
>
> >
> > Hi there,
> > I am pretty sure it is possible to put Barcode in PDF file using
> > Zend_Pdf
> > but I couldn't find any information about that.
> > Can someone show me any tutorial about it?
> >
> > Thanks
> > B
>
> That is perfectly possible if you add the barcode as an image to the PDF
> document, if you need a barcode library then I suggest you browse the PEAR
> packages at pear.php.net as the Zend Framework doesn't support barcode
> generating.
>


-- 
Isaak Malik
Web Developer
[EMAIL PROTECTED]


RE: [fw-general] Zend_PDF and Barcode

2008-03-14 Thread Steven Brown
Ah ofcourse, yeah well get a TTF and draw the barcode...couldn't be easier!

-Original Message-
From: troels knak-nielsen [mailto:[EMAIL PROTECTED] 
Sent: Friday, 14 March 2008 11:58 PM
To: Steven Brown
Cc: billyildirim; fw-general@lists.zend.com
Subject: Re: [fw-general] Zend_PDF and Barcode

Not sure how Zend_PDF works, but drawing barcodes, can be done using a
special font. Each number is the rendered as a different sequence of
bars.

--
troels

On Fri, Mar 14, 2008 at 2:44 PM, Steven Brown <[EMAIL PROTECTED]>
wrote:
> I imagine it would be something like drawing the lines yourself and
setting
>  the line width etc...?
>
>
>
>  -Original Message-
>  From: billyildirim [mailto:[EMAIL PROTECTED]
>  Sent: Friday, 14 March 2008 10:11 PM
>  To: fw-general@lists.zend.com
>  Subject: [fw-general] Zend_PDF and Barcode
>
>
>  Hi there,
>  I am pretty sure it is possible to put Barcode in PDF file using Zend_Pdf
>  but I couldn't find any information about that.
>  Can someone show me any tutorial about it?
>
>  Thanks
>  B
>  --
>  View this message in context:
>  http://www.nabble.com/Zend_PDF-and-Barcode-tp16048071s16154p16048071.html
>  Sent from the Zend Framework mailing list archive at Nabble.com.
>
>
>
>



-- 
troels




Re: [fw-general] Zend_PDF and Barcode

2008-03-14 Thread troels knak-nielsen
Not sure how Zend_PDF works, but drawing barcodes, can be done using a
special font. Each number is the rendered as a different sequence of
bars.

--
troels

On Fri, Mar 14, 2008 at 2:44 PM, Steven Brown <[EMAIL PROTECTED]> wrote:
> I imagine it would be something like drawing the lines yourself and setting
>  the line width etc...?
>
>
>
>  -Original Message-
>  From: billyildirim [mailto:[EMAIL PROTECTED]
>  Sent: Friday, 14 March 2008 10:11 PM
>  To: fw-general@lists.zend.com
>  Subject: [fw-general] Zend_PDF and Barcode
>
>
>  Hi there,
>  I am pretty sure it is possible to put Barcode in PDF file using Zend_Pdf
>  but I couldn't find any information about that.
>  Can someone show me any tutorial about it?
>
>  Thanks
>  B
>  --
>  View this message in context:
>  http://www.nabble.com/Zend_PDF-and-Barcode-tp16048071s16154p16048071.html
>  Sent from the Zend Framework mailing list archive at Nabble.com.
>
>
>
>



-- 
troels


RE: [fw-general] Zend_PDF and Barcode

2008-03-14 Thread Steven Brown
I imagine it would be something like drawing the lines yourself and setting
the line width etc...?

-Original Message-
From: billyildirim [mailto:[EMAIL PROTECTED] 
Sent: Friday, 14 March 2008 10:11 PM
To: fw-general@lists.zend.com
Subject: [fw-general] Zend_PDF and Barcode


Hi there,
I am pretty sure it is possible to put Barcode in PDF file using Zend_Pdf
but I couldn't find any information about that.
Can someone show me any tutorial about it?

Thanks
B
-- 
View this message in context:
http://www.nabble.com/Zend_PDF-and-Barcode-tp16048071s16154p16048071.html
Sent from the Zend Framework mailing list archive at Nabble.com.





[fw-general] Re: Zend_Form bug - dIsplay groups within a sub form

2008-03-14 Thread Matthew Weier O'Phinney
-- Simon Mundy <[EMAIL PROTECTED]> wrote
(on Friday, 14 March 2008, 02:07 PM +1100):
> I wanted to know if this is a known issue, or an expected behaviour (or
> neither?!)
> 
> I'm creating a form composed of a subform and a submit element. The idea is to
> create a long list of skills that are returned in array notation so I can more
> easily aggregate the results and store in a database. So the subform works 
> well
> for this. However I also wanted to use the display group feature within the
> subform to group sub-categories together to make the form more readable. The
> expected output should be:-

I know exactly where this is going -- somebody reported it on #zftalk
yesterday, and I was able to confirm it:

http://framework.zend.com/issues/browse/ZF-2883

Basically, when you have a display group *within* a sub form, the sub
form's name is not pushed into the elements, and as a result, they are
not namespaced properly.

Until I get a fix in, you can "correct" for it by explicitly calling the
following on all elements of such a display group:

$element->setBelongsTo();

I've scheduled this for 1.5.1, as it's only going to affect a subset of
users.

-- 
Matthew Weier O'Phinney
PHP Developer| [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/


Re: [fw-general] Controller Testing: Zend_View::clearVars() ?

2008-03-14 Thread reto
Hi,

Thanks for the magic lines!

Sincerely,
 Reto

On Fri, Mar 14, 2008 at 1:46 PM, Matthew Weier O'Phinney
<[EMAIL PROTECTED]> wrote:
> -- reto <[EMAIL PROTECTED]> wrote
>  (on Friday, 14 March 2008, 03:50 AM +0100):
>
> > Hi everyone,
>  >
>  > I'm trying to test my ZF-Controllers with phpunit.
>  > The internet (http://www.alexatnet.com/node/12) gave me the following
>  > code to start a request to a given controller/action and then check
>  > the rendered output:
>  >
>  >  $front = Zend_Controller_Front::getInstance();
>  >  $request = new
>  > Zend_Controller_Request_Http('http://localhost/main/user/register');
>  >  $response = new Zend_Controller_Response_Http();
>  >  
> $front->returnResponse(true)->setRequest($request)->setResponse($response);
>  >  $front->dispatch();
>  >  $this->assertContains('', $response->getBody());
>  >
>  > My problem is now, that if I run this code twice while testing (for
>  > testing two different controller/actions) all the View's variable's
>  > are still set.
>  > So if my first controller for the url "/main/user/register" sets
>  > $this->view->foo=1, then I can run another request for "/main/image",
>  > and the $this->view->foo variable is still set to "1".
>  >
>  > So I think this is, because the Fron-Controller is a
>  > singleton-instance, and there's also only one view instantiated per
>  > frontcontroller?
>  > So  I thought maybe I should reset all those view-variables with
>  > Zend_View::clearVars(), but I have no idea, how I could reach the
>  > current view for example from a phpunit setUp()-method..
>
>  The same way you'd reach it from a plugin: grab the ViewRenderer, make
>  sure the view is initialized, and then clear the vars:
>
> $viewRenderer = 
> Zend_Controller_Action_HelperBroker::getStaticHelper('ViewRenderer');
> $viewRenderer->initView();
> $viewRenderer->view->clearVars();
>
>
>
>  > Am I already doing something wrong with my frontcontroller-dispatch
>  > code? Or should I really clear those variables out before every
>  > request?
>  > Any help is appreciated!
>  > I'm using th ZF 1.5 RC3
>
>  --
>  Matthew Weier O'Phinney
>  PHP Developer| [EMAIL PROTECTED]
>  Zend - The PHP Company   | http://www.zend.com/
>


Re: [fw-general] Controller Testing: Zend_View::clearVars() ?

2008-03-14 Thread Matthew Weier O'Phinney
-- reto <[EMAIL PROTECTED]> wrote
(on Friday, 14 March 2008, 03:50 AM +0100):
> Hi everyone,
> 
> I'm trying to test my ZF-Controllers with phpunit.
> The internet (http://www.alexatnet.com/node/12) gave me the following
> code to start a request to a given controller/action and then check
> the rendered output:
> 
>  $front = Zend_Controller_Front::getInstance();
>  $request = new
> Zend_Controller_Request_Http('http://localhost/main/user/register');
>  $response = new Zend_Controller_Response_Http();
>  $front->returnResponse(true)->setRequest($request)->setResponse($response);
>  $front->dispatch();
>  $this->assertContains('', $response->getBody());
> 
> My problem is now, that if I run this code twice while testing (for
> testing two different controller/actions) all the View's variable's
> are still set.
> So if my first controller for the url "/main/user/register" sets
> $this->view->foo=1, then I can run another request for "/main/image",
> and the $this->view->foo variable is still set to "1".
> 
> So I think this is, because the Fron-Controller is a
> singleton-instance, and there's also only one view instantiated per
> frontcontroller?
> So  I thought maybe I should reset all those view-variables with
> Zend_View::clearVars(), but I have no idea, how I could reach the
> current view for example from a phpunit setUp()-method..

The same way you'd reach it from a plugin: grab the ViewRenderer, make
sure the view is initialized, and then clear the vars:

$viewRenderer = 
Zend_Controller_Action_HelperBroker::getStaticHelper('ViewRenderer');
$viewRenderer->initView();
$viewRenderer->view->clearVars();

> Am I already doing something wrong with my frontcontroller-dispatch
> code? Or should I really clear those variables out before every
> request?
> Any help is appreciated!
> I'm using th ZF 1.5 RC3

-- 
Matthew Weier O'Phinney
PHP Developer| [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/


[fw-general] Re: Zend_Form feature request

2008-03-14 Thread Matthew Weier O'Phinney
-- Simon Mundy <[EMAIL PROTECTED]> wrote
(on Friday, 14 March 2008, 01:09 PM +1100):
> I've just created a small feature request for Zend_Form to add an 'init()' 
> method to the base class. I'd imagine it implemented the same way as it's 
> used for Zend_Controller_Action and Zend_Db_Table, as a 'safe' way to add 
> behaviours and logic to a form model when subclassing Zend_Form. Ideally it 
> would be called as the last step in the base __construct method.

I noted the issue this morning, and aded a note to it. For those who
don't like to browse the issue tracker... Instead of calling init() as
the *last* call in __construct(), I'm recommending it happen just prior
to the call to loadDefaultDecorators(). This would prevent loading the
default decorators in the case that you wish to set your own during
init() -- saving some cycles and reducing overhead.

Otherwise, I'm in agreement at this point over adding it, and plan to
add it to each of the Zend_Form classes.

-- 
Matthew Weier O'Phinney
PHP Developer| [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/


[fw-general] Zend_PDF and Barcode

2008-03-14 Thread billyildirim

Hi there,
I am pretty sure it is possible to put Barcode in PDF file using Zend_Pdf
but I couldn't find any information about that.
Can someone show me any tutorial about it?

Thanks
B
-- 
View this message in context: 
http://www.nabble.com/Zend_PDF-and-Barcode-tp16048071s16154p16048071.html
Sent from the Zend Framework mailing list archive at Nabble.com.