Jump to content

idv

New Members
  • Posts

    8
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

idv's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. anybody have any idea with this? as I am trying to get the site back up and running :'(
  2. Also when looking at the templates_c directory in plesk Most of the files have under 'user' and 'group' ourusername psacln However one file %%97^97B^97B39B8E%%g-header.tpl.htm.php has apache and apache under 'user' and 'group' ? ??
  3. When running the CHMOD command the error goes, but the site then does not load the CSS files and images used in the site? Any ideas, I'm stumped!
  4. Hi Thanks So in Plesk I just need to go into 'Domains' > ourdomain.com > SSH Terminal Then when it loads just paste in the following chmod 0777 /var/www/vhosts/ourdomain.com/subdomains/beta/httpdocs/_templates_c to get rid of the error below? Smarty error: unable to write to $compile_dir '/var/www/vhosts/ourdomain.com/subdomains/beta/httpdocs/_templates_c'. Be sure $compile_dir is writable by the web server user Also could the above be done through my FTP client? Also how do I check permissions on the _error dir on the server, as this needs to be writable?
  5. Hi Using the editor in Plesk I have just made a simple text change i.e. 'Hi' to 'Hello' in the header.tpl.htm template. The site is using PHP/Smarty and I am now getting the error when viewing the page/site in the browser. Before I made a change to the header.tpl.htm file the website was workin.g fine. I even uploaded the previous version of the header.tpl.htm file but I am still getting this new error Smarty error: unable to write to $compile_dir '/var/www/vhosts/ourdomain.com/subdomains/beta/httpdocs/_templates_c'. Be sure $compile_dir is writable by the web server user How do I get around this problem? This is on our new server, so could it be a server setting? TIA
  6. Hi I would appreciate the professional opinion of members on this forum to check my new website which is currently in beta to see if there are any security vulnerabilities such as SQL Injection / XSS etc The reason for the testing is that I wanted to check if there are any security holes/issues from the code created by the previous developer If anybody is interested in helping please let me know Thanks
  7. Thanks for the reply. So the site is using Smarty? Also with regard to the index.tpl.htm file where would be the location of this file as it is not in the same directory as the index.php file? So the following line does what, assign a variable city to city? as I would have thought city would contain an actual city name? Finally what was the structure of the code like, is it well coded or are there potential security/performance issues? Thanks $smarty->assign("city",$city);
  8. Hi All I have just received the source code for our site from our previous developer who we are no longer in contact with. How do you know that the site is using Smarty? My background is in Coldfusion so I am new to PHP. The previous developer told us that the site was created using the SMARTY framework but now works as plain PHP. I would appreciate it if a PHP/Smarty expert can explain the code below on what is is actually doing. For example it mentions a index.tpl.htm what is a tpl.htm file? Thanks very much in advance -------------this is the index.php page --------- <?php include_once "local.cfg.php"; include_once INCLUDE_DIR."common.inc.php"; $userid = user_getCurrentUserID(); $f_search = g_getVar("f_search",false,"g"); $region = false; if($userid > 0) { $user = user_get($userid); $region = $user["Region"]; } if($f_search["region"] && $f_search["region"] > 0 && (($f_search["region"] == 10)||($f_search["region"] == 20)||($f_search["region"] == 30)||($f_search["region"] == 40)||($f_search["region"] == 50)||($f_search["region"] == 60)||($f_search["region"] == 70)||($f_search["region"] == 80)||($f_search["region"] == 90)||($f_search["region"] == 100)||($f_search["region"] == 110)||($f_search["region"] == 120))) { $region = $f_search["region"]; $inTwoMonths = 60 * 60 * 24 * 60 + time(); setcookie('region', $region, $inTwoMonths); } elseif($f_search["region"] == "all") { $region = false; } $smarty->assign("userregion",$region); $cuisine = restaurant_cuisine(); $ambience = restaurant_ambience_list(); $regionOption = restaurant_htmlRegionOptions($region); $city = restaurant_getCity(); $most = restaurant_mostPopular($region); $latestReviews = restaurant_review_getLatest_region($region); $latestReviewsCount = restaurant_reviewCountAll($region,true); $reviewsCount = restaurant_reviewCountAll($region,false); $latest = restaurant_latest($region,10); $featured = restaurant_featured($region,5); // if(!$latest) // { // $latest = restaurant_latest(false,10); // } $closing = auction_closingAndNewly(true,$region); $newly = auction_closingAndNewly(false,$region); $smarty->assign("page","home"); $smarty->assign("newly",$newly); $smarty->assign("closing",$closing); $smarty->assign("latest",$latest); $smarty->assign("featured",$featured); $smarty->assign("latestReviews",$latestReviews); $smarty->assign("latestReviewsCount",$latestReviewsCount); $smarty->assign("reviewsCount",$reviewsCount); $smarty->assign("most",$most); $smarty->assign("cuisine",$cuisine); $smarty->assign("ambience",$ambience); $smarty->assign("region",$regionOption); $smarty->assign("city",$city); $smarty->assign("userid",$userid); $smarty->display("index.tpl.htm"); ?> ---------------------end snippet-------------------
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.