Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6373149
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T01:19:42+00:00 2026-05-25T01:19:42+00:00

I have noticed that my site in Cakephp is very very slow. I have

  • 0

I have noticed that my site in Cakephp is very very slow. I have rewritten my entire site in Cakephp with exactly the same functionality and it’s taking 400 ms to generate every page instead of 20ms. 400ms is far away from the 50-100ms parsetimes I am hoping to archieve. Site speed is very important for me, it was one of the reasons I moved away from learning more about Drupal.

When writing all SQL queries myself and working with simple incudes, there was no need to do much optimizing. I have to start optimizing the code now though.

All pages show in a block the number of users, newsposts, articles and a few other things that have been posted. This takes 9 SQL queries and seems to take away some performance. That’s what I want to use caching for.

At the moment my site doesn’t get that many visitors and I’m mainly rebuilding it to become a better webdeveloper and the high parsetime bums me out. I am going to remove Croogo alltogether and only work with self-written code. I already stumbled on many horrible performance degrading parts of Croogo.

I would like to save all those 9 query results in cache once an hour via a cronjob. I want to run a cronjob with the 9 queries that saves the results in the cache. My question is how I can save data longer in cache? It normally saves data 10minutes, but I’d like to save this specific data for 150 minutes and run a cronjob every 2 hours. I know it can be done via core.php, but I wouldn’t like to cache everything for 150 minutes, just the statistics-data for the leftmost block at http://www.daweb.nl.

Statistieken
Artikelen:
Leden:
Javascripts: 29
Nieuwsberichten: 4
Nodes: 16
PHP Scripts:

Members, Articles, PHP Scripts are empty, which means nobody has accessed the pages that generate the relevant data. I could make a long block of code with a lot of if (there is cache) and else (generate cache), but that’s not going to make things much prettier either. Also, I’d have no idea where to place that code. I am not looking to write bunchload of code in app_controller.php, can’t be good for the site.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T01:19:43+00:00Added an answer on May 25, 2026 at 1:19 am

    If site speed is important to you (more than those automagics Cake has to offer) then you might want to look at CodeIgniter.

    Anyway, here’s how to set cache setting for elements: http://book.cakephp.org/view/1083/Caching-Elements

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have facebook comments on my site. I noticed that when there are 10
I am developing a mobile site and have noticed that on android all the
I have noticed that sites like http://hypem.com which is a full ajax site have
I have an ajax based login form for my site and have noticed that
Over at my site, I have noticed that while the scrollTo() method in jQuery
I'm starting a Drupal 7 site and have noticed that almost every page will
Im writing a review site where the community rates posts. I have noticed that
So a site that I built for some reason is very slow on the
Just about to launch a WordPress site but have noticed that it's currently loading
I have noticed that while debugging my site, any request that results in a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.