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

  • SEARCH
  • Home
  • 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 6573815
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T15:10:53+00:00 2026-05-25T15:10:53+00:00

ok so i built a php search engine and it was working beautifully, but

  • 0

ok so i built a php search engine and it was working beautifully, but some people said to me that it was slow.

maybe it may appear slow on their machines when the thing outputs the results table on html but i know it’s running ludicrously fast.

so i decided to make a fancy feature like the one many search engines like google have saying that ”your search returned X results in Y time” as a way of telling people that probably isn’t my search engine fault that they’re taking a long time to see the results for their query.

i’ve made the feature that pretty much confirms what i already know, that is that the search engine is fast.

the problem is the results are echoed before the timer/resultcounter thing is, because for it to count the results it already has to have the results and for it to display the time it took to find them obviously the search engine had to finish running.

i’m using html+css+php for this project and i don’t want to have to use javascript, how should i display the timer / results counter before the actual results?

  • 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-25T15:10:53+00:00Added an answer on May 25, 2026 at 3:10 pm

    You can run the search queries with the time code, then echo them after the search has finished with the time code coming first.

    $start = microtime(true);
    $searchdata = //Search Functions    
    $end = microtime(true);
    $time = ($end - $start);
    echo $time."".$searchdata
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

A site I am working on that is built using PHP is sometimes showing
I have built a search engine using php and mysql. Problem: When I submit
i've built a search engine + indexer script for a website using php and
I've built a search index using the PHP Zend Framework Search (based on Lucene).
The basics have already been answered here . But is there a pre-built PHP
I have built a PHP calendar system and have pretty much everything done but
After using PHP for a while now, I've noticed that not all built-in PHP
Ok, just wondering on the versions of PHP that this class is built into.
I've built this little script that searches a table in my database, but for
hello i'v built a search, using MySQL, PHP and jQuery, this is the search

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.