Hello,
The code below works great. It creates a table that shows the 25 most recently added tables to a MySQL database called "sitefeather."
Each one of these tables has the following structure:
Code: id INT(11) NOT NULL auto_increment, site VARCHAR(1000) NOT NULL, action1 BIGINT(9) NOT NULL, action2 BIGINT(9) NOT NULL, createddatetime TIMESTAMP DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY(id), UNIQUE (site)
I would like to echo a list of "site" and "CURRENT_TIMESTAMP" for the 25 most recently added rows, regardless of which table they are in. This may be tricky since the number of tables is variable. Someone advised me that I would have to use a query involving INFORMATION_SCHEMA.TABLES. How can I do this?
Thanks in advance,
John
Code: echo "<table class="samples">";
$index = mysql_query("select TABLE_NAME from INFORMATION_SCHEMA.TABLES where TABLE_SCHEMA='sitefeather' order by CREATE_TIME desc limit 25");
while ($row = mysql_fetch_array($index))
{
echo '<tr><td><a href="sitesearch.php?find='.urlencode($row['TABLE_NAME']).'&searching=yes&search=search">'.$row['TABLE_NAME'].'</a></td></tr>';
}
echo "</table>";
Production of mango in processing industry
Hi,
rename the file
File.txtCode: ***DOCUMENT***..DN:000044255..CB:..SN:..PY:2009..ED:LA..ED:Home..ID:***DOCUMENT***..DN:000044254..CB:..SN:..PY:2009..ED:LA..ED:Edition..PT:ID:Code: <?php$file = fopen($argv[1],
Is it possible to put an entire 500-page book in a database with PHP?
I am working on an intranet and I was wondering if its possible to code php with mysql to enter a full-text 500 page book into a database since I will be doing lots of updates to the pages? thanks
Pagination won't carry results past page 2.
Hi all,I've worked out my pagination script and its paginating fine until I click next from page 2 at which point it stops displaying results. I know its something really simple, but can't see what
admin with my register system?
Hey i wana make it so i can make a admin level on my register system , I'm kinda new to php to im not sure how, i wana do something like a 'if' statment so when they click the page if the admin level
using variables in another page
I have a test database set up on localhost. I have a form that I can type a name into, hit the button and it puts the name into the database and into a list on my page. it works fine. Now, I wanted to
Why do I get this error
Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/a5488351/public_html/bbdemo.php on line 90Code:<?php session_start(); ?><?php require
What am I missing here? Help!
Hello all!. I can't seem to get this working right. Well - it renders right, but something is going wrong. It's a set of filters for events. The filter marked "type" (category) works
losing session vars when arriving from an email link
Hi,I've got a confirmation script made that sends an email with a link for a user to confirm their email. This all works pretty good with the exception of not being able to direct them to where they
Execure stored procedure on a timer
Can someone tell me an easier way to execute a stored procedure on a timer? I am using Oracle 10g R2 DB on windows 2003 server. I have a batch file that calls an SQL file, which runs fine when I