{TEASER_EX} Replacement tag v1.90 - 10.1.2007
Any news on code problem?
Hi Erich
I saw that you were back on the board and wanted to ask you if you noticed the problem with the rendering of code such as , [PHP] etc.?
If that problem could be fixed it would really make my day - or year even!
/Kvist
I saw that you were back on the board and wanted to ask you if you noticed the problem with the rendering of code such as , [PHP] etc.?
If that problem could be fixed it would really make my day - or year even!
/Kvist
Re: Any news on code problem?
Hello Kvist
Erich as posted the solution at page 10 of this thread.
Check for Erich's post at the bottom: Tue Nov 22, 2005 05:55
It solves the parsing of different formating tags but not sure about th PHP tag...
Erich as posted the solution at page 10 of this thread.
Check for Erich's post at the bottom: Tue Nov 22, 2005 05:55
It solves the parsing of different formating tags but not sure about th PHP tag...
Kvist wrote:Hi Erich
I saw that you were back on the board and wanted to ask you if you noticed the problem with the rendering of code such as , [PHP] etc.?
If that problem could be fixed it would really make my day - or year even!
/Kvist
PhpWCMS Evangelist, -- iRoutier.com Running phpWCMS 1.4.2, r354 -> Great Version!!!!
Oooh
Oh, so you actually have to have your eyes open on this board?? Thanks!
/Kvist
Am I being stupid if I ask whicht file he's referring to and that the text in line 482 originally is? (Never comprehended the line numbers - I guess you have to have a special editor whereas I use notepad.)Replace line 482 (v1.0.6) with
Kode:
return str_replace("<br /><br />", "<br />", html_parser(render_PHPcode($listing)));
/Kvist
I added the file here for you, to be able to download the latest
http://www.malouin.ws/design/downloads-phpwcms.phtml
Cheers,
http://www.malouin.ws/design/downloads-phpwcms.phtml
Cheers,
PhpWCMS Evangelist, -- iRoutier.com Running phpWCMS 1.4.2, r354 -> Great Version!!!!
Merci
Merci bien mec, C très gentile!
Re: Oooh
In notepad:Kvist wrote:I guess you have to have a special editor whereas I use notepad.)
/Kvist
CTRL + G = goto line
Re: Oooh
VERY handy information - thanks!DeXXus wrote:In notepad:Kvist wrote:I guess you have to have a special editor whereas I use notepad.)
/Kvist
CTRL + G = goto line
Hi
Is it possibly to show just one page.... in place of several?
Example.
I have a news section on my site witch contains 20 news article.
on my Homepage I just want to show the teasers from the last 2 Article.
at the moment I use the tag like this:
{TEASER_EX:news:2:article_tstamp|DESC:0:Seite:1:159}
Thanks, Sven
Is it possibly to show just one page.... in place of several?
Example.
I have a news section on my site witch contains 20 news article.
on my Homepage I just want to show the teasers from the last 2 Article.
at the moment I use the tag like this:
{TEASER_EX:news:2:article_tstamp|DESC:0:Seite:1:159}
Thanks, Sven
Hi
it would look something like this
{TEASER_EX:news|2:2:article_created|DESC:0:Page:1:}
then put a link on the bottom directing the user too http://yourdomain/?news
it would look something like this
{TEASER_EX:news|2:2:article_created|DESC:0:Page:1:}
then put a link on the bottom directing the user too http://yourdomain/?news
Hi All,
If you don't want the updated version of the reptag_teaser_ex file to cause your old reptags to crash then ADD this line
AFTER the following
Erich, correct me if I'm wrong.
Here's another enhancement to allow you to show the article creation date in the article listing:
in reptag_teaser_ex ADD:
BELOW this line:
You'll also need to REPLACE the function render_cnt_date() in include/inc_front/front.func.inc.php with this:
Great work, Erich, and good idea with the generator! This reptag is really awesome, a little tricky to set up, but the generator takes care of that I hope.
A suggestion for next release: Maybe make it backwards compatible with previous versions. Seems like this thread gets flooded with formatting issues...
Cheers,
Jens
If you don't want the updated version of the reptag_teaser_ex file to cause your old reptags to crash then ADD this line
Code: Select all
$content["all"] = preg_replace('/\{TEASER_EX:(.*?):(.*?):(.*?):(.*?):(.*?):(.*?):(.*?)\}/ie', 'get_teaser_ex_content("$1", "$2", "$3", "$4", "$5", "$6", "$7", "", -1, "", $db);', $content["all"]);
Code: Select all
$content["all"] = preg_replace('/\{TEASER_EX:(.*?):(.*?):(.*?):(.*?):(.*?):(.*?):(.*?):(.*?):(.*?):(.*?)\}/ie', 'get_teaser_ex_content("$1", "$2", "$3", "$4", "$5", "$6", "$7", "$8", "$9", "$10", $db);', $content["all"]);
Here's another enhancement to allow you to show the article creation date in the article listing:
in reptag_teaser_ex ADD:
Code: Select all
$tmpl = render_cnt_date($tmpl, $article_list[$key]["article_created"], "CREATEDATE");
BELOW this line:
Code: Select all
$tmpl = render_cnt_date($tmpl, $article_list[$key]["article_date"]);
Code: Select all
function render_cnt_date($text='', $date, $tag='DATE') {
// render date by replacing placeholder tags by value
//$language="EN", $format="Y/m/d", $date_now=0
$text = preg_replace('/\{'.$tag.':(.*?):(.*)\}/ie', 'international_date_format("$2","$1","'.$date.'")', $text);
$text = preg_replace('/\{'.$tag.':(.*?)\}/ie', 'date("$1",'.$date.')', $text);
return $text;
}
Great work, Erich, and good idea with the generator! This reptag is really awesome, a little tricky to set up, but the generator takes care of that I hope.
A suggestion for next release: Maybe make it backwards compatible with previous versions. Seems like this thread gets flooded with formatting issues...
Cheers,
Jens
Hi
I update the RT to V 1.5. it works all fine except the template usage.
Do I understand right? If I define a template (temp.tmpl) the teaser should use this template for listing the article not the one that was defined in the article. Because if I change the Art. List. Temp. to temp.tmpl it works fine...
{TEASER_EX:news|2:2:article_tstamp|ASC:0:seite:1::temp.tmpl:150:}
Ich habe auf die aktuelle Version 1.5 upgedatet, alles funktioniert. Ausser das der Teaser nicht das Template verwendet welches ich angeben. Zum Beispiel temp.tmpl. Verstehe ich das richtig, der Teaser sollte das Template verwenden welches im RT angeben ist und nicht das im Artikel selber.
Wenn ich es im Artikel umstelle funktioniert es....
{TEASER_EX:news|2:2:article_tstamp|ASC:0:seite:1::temp.tmpl:150:}
thanks for help, Sven
I update the RT to V 1.5. it works all fine except the template usage.
Do I understand right? If I define a template (temp.tmpl) the teaser should use this template for listing the article not the one that was defined in the article. Because if I change the Art. List. Temp. to temp.tmpl it works fine...
{TEASER_EX:news|2:2:article_tstamp|ASC:0:seite:1::temp.tmpl:150:}
Ich habe auf die aktuelle Version 1.5 upgedatet, alles funktioniert. Ausser das der Teaser nicht das Template verwendet welches ich angeben. Zum Beispiel temp.tmpl. Verstehe ich das richtig, der Teaser sollte das Template verwenden welches im RT angeben ist und nicht das im Artikel selber.
Wenn ich es im Artikel umstelle funktioniert es....
{TEASER_EX:news|2:2:article_tstamp|ASC:0:seite:1::temp.tmpl:150:}
thanks for help, Sven
Hi Sven!
Fixed in ver 1.51!
Att.: now we have three possible values for the parameter "listtemplate":
default: to render all articles with the default-template settings
system: to render the articles with the template set in the backend
or the Templatename of the template you want to use for rendering, regardless of which template is set in the backend
Erich
Fixed in ver 1.51!
Att.: now we have three possible values for the parameter "listtemplate":
default: to render all articles with the default-template settings
system: to render the articles with the template set in the backend
or the Templatename of the template you want to use for rendering, regardless of which template is set in the backend
Erich