Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php final class ConpherenceThreadSearchController extends ConpherenceController { ..

Decoded Output download

<?php

final class ConpherenceThreadSearchController
  extends ConpherenceController {

  public function shouldAllowPublic() {
    return true;
  }

  public function handleRequest(AphrontRequest $request) {
    $viewer = $request->getViewer();
    $conpherence_id = $request->getURIData('id');
    $fulltext = $request->getStr('fulltext');

    $conpherence = id(new ConpherenceThreadQuery())
      ->setViewer($viewer)
      ->withIDs(array($conpherence_id))
      ->executeOne();

    if (!$conpherence) {
      return new Aphront404Response();
    }

    $engine = new ConpherenceThreadSearchEngine();
    $engine->setViewer($viewer);
    $saved = $engine->buildSavedQueryFromBuiltin('all')
      ->setParameter('phids', array($conpherence->getPHID()))
      ->setParameter('fulltext', $fulltext);

    $pager = $engine->newPagerForSavedQuery($saved);
    $pager->setPageSize(15);

    $query = $engine->buildQueryFromSavedQuery($saved);

    $results = $engine->executeQuery($query, $pager);
    $view = $engine->renderResults($results, $saved);

    return id(new AphrontAjaxResponse())
      ->setContent($view->getContent());
  }
}
 ?>

Did this file decode correctly?

Original Code

<?php

final class ConpherenceThreadSearchController
  extends ConpherenceController {

  public function shouldAllowPublic() {
    return true;
  }

  public function handleRequest(AphrontRequest $request) {
    $viewer = $request->getViewer();
    $conpherence_id = $request->getURIData('id');
    $fulltext = $request->getStr('fulltext');

    $conpherence = id(new ConpherenceThreadQuery())
      ->setViewer($viewer)
      ->withIDs(array($conpherence_id))
      ->executeOne();

    if (!$conpherence) {
      return new Aphront404Response();
    }

    $engine = new ConpherenceThreadSearchEngine();
    $engine->setViewer($viewer);
    $saved = $engine->buildSavedQueryFromBuiltin('all')
      ->setParameter('phids', array($conpherence->getPHID()))
      ->setParameter('fulltext', $fulltext);

    $pager = $engine->newPagerForSavedQuery($saved);
    $pager->setPageSize(15);

    $query = $engine->buildQueryFromSavedQuery($saved);

    $results = $engine->executeQuery($query, $pager);
    $view = $engine->renderResults($results, $saved);

    return id(new AphrontAjaxResponse())
      ->setContent($view->getContent());
  }
}

Function Calls

None

Variables

None

Stats

MD5 58565edbe7f2c3e69351c3d8d658bb30
Eval Count 0
Decode Time 80 ms