hi. if this is the wrong forum for this post, mod, please feel free to move. I am trying to modify the rating_error.html file. I am having trouble displaying the <%$title%> tag to appear. code is as follows:
Here is the php:Code:<%include file="header.html" title="Rate a link" meta_keywords="" %> <meta http-equiv="refresh" content="4;URL=javascript: history.go(-1)"> </td> </tr> <tr> <td> <!-- main content here --> <br /> <b>Rate a Link</b> <p>There was an error rating<b><%$title%></b></p> <p><%$error_msg%>.</p> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /> <!-- end of main content --> </td> </tr> <tr> <td> <%include file="footer.html"%>
I have tried to change the position of the $title var in the php, but no luck. I can see that the variableCode:<?php function ProcessRating() { // vars global configuration global $theme_path, $top_rated_limit; // vars url & form global $id, $rating; // vars messages global $msg, $title; // vars template global $error_msg; $links_obj = new clsLink; $links_obj->query = "select * from idx_link where link_id = '$id'"; $links_obj->table_name = "idx_link"; $links_obj->votes_table_name = "idx_votes"; $links_obj->top_rated_limit = $top_rated_limit; $rating_result = $links_obj->RateLink($id, $rating); if ($rating < 1 || $rating > 5) { $rating_result = 2; // error } // success if ($rating_result == 0) { $title = $links_obj->GetLinkTitle($id); DisplayTemplate($theme_path . "rating_ok.html", "\$title"); } // user already rated elseif ($rating_result == 1) { $error_msg = $msg["10171"]; DisplayTemplate($theme_path . "rating_error.html", "\$error_msg"); } // rated fail else { $error_msg = $msg["10172"]; $title = $links_obj->GetLinkTitle($id); DisplayTemplate($theme_path . "rating_error.html", "\$error_msg", "\$title"); } } /*=================================================== main ===================================================*/ include "application.php"; RunPreFilter(__FILE__); $query = "select suspended from idx_link where link_id = '$id'"; $result = $dbConn->Execute($query); $suspended = $result->Fields("suspended"); if ($suspended) { DisplayTemplate($theme_path . "suspended.html"); RunPostFilter(__FILE__); } ProcessRating(); RunPostFilter(__FILE__);?>is taking on obviously it is something i haven't set correctly. any help greatly appreciated. Many thanks.Code:$rating_result = $links_obj->RateLink($id, $rating)
Version: 5.3


