This is the community forum. For a developer response use the Client Area.
Follow us on Facebook, Twitter and YouTube!

Commentics making the page really slow?
#8

Hi,

Can you try these two solutions:

1.

In comments/includes/functions/page.php, line 83, replace this:
PHP Code:
<?php 
if (preg_match("/<title>(.+)<\/title>/i", $file, $match)) {

With this:
PHP Code:
<?php 
if (preg_match("/<title>(.*?)<\/title>/i", $file, $match)) {

2.

In comments/includes/functions/page.php, lines 83 to 89, replace this:
PHP Code:
<?php 
if (preg_match("/<title>(.+)<\/title>/i", $file, $match)) {
if (
$page_id == "cmtx_title") { $page_id = $match[1]; }
if (
$reference == "cmtx_title") { $reference = $match[1]; }
} else {
if (
$page_id == "cmtx_title") { $page_id = "Title not found"; }
if (
$reference == "cmtx_title") { $reference = "Title not found"; }
}

With this:
PHP Code:
<?php 
$doc
= new DOMDocument();
@
$doc->loadHTML($file);
$nodes = $doc->getElementsByTagName('title');
$title = $nodes->item(0)->nodeValue;
if (
$page_id == "cmtx_title") { $page_id = $title; }
if (
$reference == "cmtx_title") { $reference = $title; }

Have you completed the interview?
Reply


Messages In This Thread
Commentics making the page really slow? - by KKoopman - 14-Feb-2012, 10:37 AM
RE: Commentics making the page really slow? - by corculator - 14-Feb-2012, 02:28 PM
RE: Commentics making the page really slow? - by corculator - 14-Feb-2012, 09:26 PM
RE: Commentics making the page really slow? - by corculator - 15-Feb-2012, 09:18 AM
RE: Commentics making the page really slow? - by corculator - 15-Feb-2012, 10:08 AM
RE: Commentics making the page really slow? - by corculator - 15-Feb-2012, 11:45 AM
RE: Commentics making the page really slow? - by corculator - 16-Feb-2012, 10:05 AM
RE: Commentics making the page really slow? - by Steven - 16-Feb-2012, 02:55 PM
RE: Commentics making the page really slow? - by corculator - 20-Feb-2012, 08:48 AM
RE: Commentics making the page really slow? - by Steven - 20-Feb-2012, 03:57 PM
RE: Commentics making the page really slow? - by Steven - 24-Feb-2012, 02:36 PM
RE: Commentics making the page really slow? - by corculator - 25-Feb-2012, 11:25 AM
RE: Commentics making the page really slow? - by corculator - 25-Feb-2012, 11:40 AM

Possibly Related Threads…
Thread / Author Replies Views Last Post
Last Post by Steven
22-Feb-2024, 06:58 PM
Last Post by Koksi
22-Nov-2012, 03:19 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)