Quote
sasha2002 wrote:
I want change the code(like where need to be place 'readme' and delete info that i not needed)
The site is Offline(127.0.0.1)
I use default theme(Gilette).
you can do this from theme.php or if you so wish you can put some of that logic in news.php in your theme folder.
go to
my php-fusion themes and download the 4Newspapers 2.0, then in the theme.php file find
render_news function, where you can see an example of how you can add
read more link to your
news item, and remove all of the information that you don't want.
When page is rendered, news.php file uses render_news from theme.php to "print" out the html. Function
render_news can access all of the data about that particular
news item via
$info array, so if you need to get id of the news item you do the following:
[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]$info['news_id'][/syntaxhighlighter]
you can find all the items of that array at line 56 of /news.php
And this is how the data looks like:
[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]
"news_id" // link to the news item, href="/news.php?readmore=$info['news_id']
"user_id" // link to the user , href="/user.php?lookup=$info['user_id']
"user_name" // self explanatory
"user_status" // dunno
"news_date" // raw date value ( not pretty )
"cat_id" // link to all news in same category, href="/news_cats.php?cat_id=$info['cat_id']
"cat_name" // name of the category of the news item
"news_subject" // title of the news item
"news_ext" // I don't see how this can be used for a theme
"news_reads" // number of views
"news_comments" // number of comments
"news_allow_comments" // true false if comments are allowed
"news_sticky" // true false if news item is sticky [/syntaxhighlighter]
I hope that this was helpful