PDA

View Full Version : cute news



ofi
April 17th, 2006, 03:09 PM
Hi
i am using cutenews, when i try to edit user comment, i get this error

Parse error: parse error, unexpected ';' in /var/www/localhost/htdocs/undirskrif/news/inc/editcomments.mdu on line 135


line 135
if($idnumber == "" and !$deletecomment)( $idnumber = "Idnumber"; )

any idea why this is

hl
April 17th, 2006, 03:12 PM
Show line 134.
edit:/
Wait wait... that second set of perentheces is supposed to be brackets.

ofi
April 17th, 2006, 03:14 PM
Line 132 - 141

if(!$poster and !$deletecomment){ echo"<br /><br><br />The poster can not be blank !!!"; exit(); }
if($mail == "" and !$deletecomment){ $mail = "none"; }
if($poster == "" and !$deletecomment){ $poster = "Anonymous"; }
if($idnumber == "" and !$deletecomment)( $idnumber = "Idnumber"; )
if($home == "" and !$deletecomment)( $home = "Home"; )
if($place == "" and !$deletcomment)( $palce = "place"; )
if($comment == "" and !$deletecomment){ die("comment can not be blank"); }

$comment = str_replace("\r\n","<br />",$comment);
$comment = str_replace("|","I",$comment);

ofi
April 17th, 2006, 03:16 PM
sorry, I forgot to tell, that i am trying to add in more feilds, see link
http://undirskriftir.com/index.php?subaction=showcomments&id=1145193252&archive=&start_from=&ucat=3&

hl
April 17th, 2006, 03:26 PM
if(!$poster and !$deletecomment){ echo"<br /><br><br />The poster can not be blank !!!"; exit(); }
if($mail == "" and !$deletecomment){ $mail = "none"; }
if($poster == "" and !$deletecomment){ $poster = "Anonymous"; }
if($idnumber == "" and !$deletecomment){ $idnumber = "Idnumber";} if($home == "" and !$deletecomment){ $home = "Home"; }
if($place == "" and !$deletcomment){ $place = "place"; }
if($comment == "" and !$deletecomment){ die("comment can not be blank"); }

$comment = str_replace("\r\n","<br />",$comment);
$comment = str_replace("|","I",$comment);

ofi
April 17th, 2006, 04:08 PM
thx, working great

ofi
April 18th, 2006, 04:01 PM
Still working on this, i am wondering about show.inc.php in line 616 does that line close it

Line 616

echo"<form $CN_remember_form method=\"post\" name=\"comment\" id=\"comment\" action=\"\">".$template_form."<div><input type=\"hidden\" name=\"subaction\" value=\"addcomment\" /><input type=\"hidden\" name=\"ucat\" value=\"$ucat\" /><input type=\"hidden\" name=\"show\" value=\"$show\" />$user_post_query</div></form>
\n $CN_remember_include";

now i have add in more feilds, how do i add the "new feilds" in this line, if its right line to add in.

"sorry my English"

hl
April 18th, 2006, 04:08 PM
Look for the $template_form.

ofi
April 18th, 2006, 04:24 PM
Hi
I found in this file this
Line 592

$template_form = str_replace("{config_http_script_dir}", "$config_http_script_dir", $template_form);

Line 614

$template_form = str_replace("{smilies}", $smilies_form, $template_form);

and in line 616

hl
April 18th, 2006, 04:27 PM
There's nothing before that? Send me the file.. it's probably in an include.

ofi
April 18th, 2006, 04:34 PM
http://www.koddinn.com/shows.inc.rar

thank you

hl
April 18th, 2006, 04:44 PM
Isn't there a folder of templates in cutenews? There should be something like comment_form in there. I haven't used cutenews in a while, so I may be wrong.

edit:/ In fact! Aren't templates editable from the admin panel?

ofi
April 18th, 2006, 04:52 PM
yes it is editable from the admin panel, foder called skins, there is included compact.skin.php
defaullt.skin.php
simple.skin.php

ofi
April 18th, 2006, 04:55 PM
There is no errors showing up, i am just not sure "how" to connect the new feilds together