Various variables
Rushian 0
From: -
From: -
Notice
This topic is archived. New comments cannot be posted and votes cannot be cast.Responses to this topic
1 Re: Various variables
Rushian
OP
0
From: -
From: -
Various variables
Ok, that'll be great!
Ok, that'll be great!
1 Re: Various variables
Philipp
From: Vienna, Austria
Administrator
1340From: Vienna, Austria
Various variables
Yes, I think this would be the best. Version 2.0 will store all stats in the database.
Yes, I think this would be the best. Version 2.0 will store all stats in the database.
1 Re: Various variables
Rushian
OP
0
From: -
From: -
Various variables
Hmm, I see. I'd rather have it in the 'headlines' block, but I'll move it to another template.
What about the other stuff? (hits, page views, page load time, number of DB queries) If ST 2.0 has it, I can wait till then..
Hmm, I see. I'd rather have it in the 'headlines' block, but I'll move it to another template.
What about the other stuff? (hits, page views, page load time, number of DB queries) If ST 2.0 has it, I can wait till then..
1 Re: Various variables
Philipp
From: Vienna, Austria
Administrator
1340From: Vienna, Austria
Various variables
The best thing is to move this code to a different template, such as site_header or login_header_xxxx.
The best thing is to move this code to a different template, such as site_header or login_header_xxxx.
1 Re: Various variables
Rushian
OP
0
From: -
From: -
Various variables
Originally posted by Philipp:
main_block_middle
Originally posted by Philipp:
Originally posted by Rushian:
I'm displaying this variable in the header block section. It works for the last 10 headlines section, but it also prints the same var for the last 10 forum posts. Can I either block the var from printing for the forum header, OR, better yet, get the last forum post var too, and then print the correct one at the correct place?
In which template did you add the code?
main_block_middle
1 Re: Various variables
Philipp
From: Vienna, Austria
Administrator
1340From: Vienna, Austria
Various variables
Originally posted by Rushian:
In which template did you add the code?
Originally posted by Rushian:
I'm displaying this variable in the header block section. It works for the last 10 headlines section, but it also prints the same var for the last 10 forum posts. Can I either block the var from printing for the forum header, OR, better yet, get the last forum post var too, and then print the correct one at the correct place?
In which template did you add the code?
1 Re: Various variables
Rushian
OP
0
From: -
From: -
Various variables
Originally posted by Philipp:
I don't mind about the overhead, I have a very low-use site.
This is close to what I need, but I'm dong something a bit tricky I guess.
I'm displaying this variable in the header block section. It works for the last 10 headlines section, but it also prints the same var for the last 10 forum posts. Can I either block the var from printing for the forum header, OR, better yet, get the last forum post var too, and then print the correct one at the correct place?
Sorry for all the questions, but I'm new to SQL and PHP..
Originally posted by Philipp:
The stats are stored in the file system. Adding them to the main page would cause more overhead to the server.
To get the time of the latest news item:
dbconnect():
$query = DBQuery(“SELECT story_time FROM esselbach_st_stories ORDER BY story_time DESC LIMIT 1”);
list($last_time) = mysql_fetch_row($query);
You find the time of the last item in the $last_time variable
I don't mind about the overhead, I have a very low-use site.
This is close to what I need, but I'm dong something a bit tricky I guess.
I'm displaying this variable in the header block section. It works for the last 10 headlines section, but it also prints the same var for the last 10 forum posts. Can I either block the var from printing for the forum header, OR, better yet, get the last forum post var too, and then print the correct one at the correct place?
Sorry for all the questions, but I'm new to SQL and PHP..
1 Re: Various variables
Philipp
From: Vienna, Austria
Administrator
1340From: Vienna, Austria
Various variables
The stats are stored in the file system. Adding them to the main page would cause more overhead to the server.
To get the time of the latest news item:
You find the time of the last item in the $last_time variable
Database queries, time, and bbwrapper need some modifications in the main script. I will look into it later.
The stats are stored in the file system. Adding them to the main page would cause more overhead to the server.
To get the time of the latest news item:
dbconnect():
$query = DBQuery(“SELECT story_time FROM esselbach_st_stories ORDER BY story_time DESC LIMIT 1”);
list($last_time) = mysql_fetch_row($query);
You find the time of the last item in the $last_time variable
Database queries, time, and bbwrapper need some modifications in the main script. I will look into it later.
I'm a bit of a stat freak, so I'm wondering how to get the number of hits the site has gotten, and page views per day.
Also, the timestamp of the most recent news item. (To be displayed in the news headline header block)
And possibly page load time, number of DB queries, etc.
When using BBwrapper, how do I pull the date of the posts? (Also to be displayed in a header block)
[Edited by Rushian on 2005-05-19 01:47:14]