Friday, October 1, 2010

Extremely slow > 5000 ms response time with Cake PHP, please help

Hi guys,

Me and my business partner bought a Cake PHP script off the shelf
which is built similar to Fiverr and we want to use it in Europe.
The script was in shambles when we bought it, so after hiring a
developer, customizing it and fixing numerous of bugs over the last 2
months, we are finally ready to launch but the response time is
prohibitive.
It's taking the script more than 5000 ms to load from a blank page,
whereas afterwards it instantly loads (our developer managed to
improve this, but did not find the reason for the slow response time).
We can't really start with this loading time, users click the page
away instantly :-(

We would appreciate any help or hints what the cause might be: please
take a look at the site at www.ejobba.de

I am more the entrepreneur & don't know which configuration settings
to post but can have our developer post in the group as well - if any
information is necessary needed please don't hesitate to ask. The
system runs on a dedicated managed server with Debian 5.0 and ping
response times are excellent - so we don't think it's the server.

Thank you all in advance!

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

datasource for twitter

Hello,

I was using http://bakery.cakephp.org/articles/view/twitter-component
for publishing content to twitter.
But now I get a basic authentication not supported.

Isn't there a newer component for twitter? I saw
http://code.google.com/p/cakephp-twitter-oauth-datasource/wiki/GettingRequestAndAuthTokens
but somebody says twitter API has changed.

any help?

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

Re: find with null

On Fri, October 1, 2010 9:04 am, lyba wrote:
> Anyone knows why the following does not produce valid SQL syntax and
> how to go get the right result?
>
> $TitleArray = array('a', 'b', 'c');
> $result = $this->Post->find('all',array(
> 'recursive'=>-1,
> 'conditions' => array(
> 'OR'=> array('title'=>null, 'title'=>$TitleArray)
> ),
> ));
>
> I want null or value in range
>
> but null is ingnored and I get only IN (a, b, c)

i suspect you want to change

'OR'=> array('title'=>null, 'title'=>$TitleArray)


to

'OR'=> array('title IS'=>null, 'title'=>$TitleArray)

YMMV

--
Mike Karthauser
Managing Director - Brightstorm Ltd

Email: mikek@brightstorm.co.uk
Web: http://www.brightstorm.co.uk
Tel: 07939 252144 (mobile)
Fax: 0870 1320560

Address: 1 Brewery Court, North Street, Bristol, BS3 1JS

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

Re: find with null

this works:
'OR'=> array('title'=>$TitleArray, 'title is null')

the other does not:
https://trac.cakephp.org/ticket/1075

the answer:
"You have duplicate array keys. PHP will merge them for you. Use
different keys"
is ignorant of the fact that SQL will not interpret properly this : IN
(1, 2, 3, null) so the idea behind merging is bad to start with.

Anyway, the above work around solution compensate for a designers
error.

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

Re: Cakephp 1.3.3 upgrade to 1.3.4 gives problems

I figured it out:

In a component i am checking if scaffolding is on:

if( $controller->view == 'scaffold' ) // works in cakephp 1.3.3

Something changed in 1.3.4, instead of a lowercased 'scaffold' i get
'Scaffold'.

I fixed my problem with a simple strtolower.But a few hours went to
wase thx to a simple upgrade :(


Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

Re: Help with foreach

I'm not sure I completely understand your problem but why not use for
instead. that way you can increment for how much you want.

On Oct 1, 7:23 am, "Dave Maharaj" <m...@davemaharaj.com> wrote:
> I have my find('list') which gives me my standard array (ordered
> alphabetically)
>
> (
>
>                 [16] => apples
>
>                 [24] => bananas
>
>                 [11] => cars        
>
> [8] => zoo
>
> ..
>
> ...
>
> and so on
>
> )
>
> Now this is where I cant get it the way I need. They become selects in a
> form so I need them layed out 3 across each row
>
> Label  [input]    |     Label  [input]         |     Label  [input]    
>
> Next row...
>
> I found a lot of 3 per rows examples online but the problem comes in with
> adding the foreach ($listItems as $key => $value).
>
> $i = 0;
>
> Sure count the $listitems
>
> $i%$row_count == 0 and build my rows but $i is only adding 1 each time.how
> do I get key [16] where $i = 0, [24] for 2 and so on..(I need the keys
> unchanged, I cnnot use 0,1,2,3 as the keys)
>
> Any ideas?

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

find with null

Anyone knows why the following does not produce valid SQL syntax and
how to go get the right result?

$TitleArray = array('a', 'b', 'c');
$result = $this->Post->find('all',array(
'recursive'=>-1,
'conditions' => array(
'OR'=> array('title'=>null, 'title'=>$TitleArray)
),
));

I want null or value in range

but null is ingnored and I get only IN (a, b, c)

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en